555 IC as servo driver

This is the NE555 circuit I used:-

Well, if this idea wont work then i will put arduino nano or micro and will forget about 555 forever :-))

Mike why you were driving servo via fet instead of mosfet? Isnt it more efficient in this shcematic to use mosfet? Something like 2n7000?

Mike why you were driving servo via fet instead of mosfet?

I wasn’t, i was using a transistor. I use an NPN transistor to invert the signal and a PNP to switch between the two pulse widths.

Isnt it more efficient in this shcematic to use mosfet?

No.
You are not providing the the servo with any power, you are just creating a control signal. No need at all for a FET of any description.

Grumpy_Mike:
This is the NE555 circuit I used:-

i'm assuming the whole bottom line connects to GND ?

yes

BabyGeezer:
i'm assuming the whole bottom line connects to GND ?

yes

ReverseEMF +1 for great link.

I built exact same circuit without any modifications of capacitors or resistors, luckily even have 47K pot.

But I`m not getting duty cycle below 2ms.

50hz its holding perfectly tested with freqmeasure library.

duty cycle I`m taking via pulseIn() on HIGH


this is image for schematic from same website.

and attached is printscreen how its holding 50hz.

why I cant get short duty cycles ? resistors that I used are 20% tolerant but each measured with multimeter before putting on the board to be sure they all have right values.

calculations for duty cycle from that website.

The formula used is as follow:

t= 1.1RaC

Ra is the total of R4 and R3. So, the minimum pulse time when R4 is set to 0, is:

t= 1.1 x 8200 x 0.0000001

t= 0.902 ms

Note that this minimum pulse width time is longer than the trigger pulse to ensure that the pulse width generator doesn't constantly generate0.65ms pulses one after the other, but at a steady +- 50Hz interval.

WhenR4 is set to maximum, the time is

t= 1.1 x 18200x 0.0000001

t= 2.002 ms

So what duty cycles do you get for different settings of that pot? And different values of the timing cap and resistor?

Are you using ceramic or film type caps for the timing?

Im using 2x555ics not 556. All caps are ceramic 103,104 and 224k

Problem is with second 555ic circuitry cos first one is generating 50hz picture attached.

10k pot one side 1900-2000us returned from pulsein(), fully turned to opposite side veryhigh values didnt even noted them.

Didnt change values for capacitor and resistor because of calculations by that guy are right it “must” produce 1ms duty cycle when fully off.

To get a stable output frequency, use film capacitors (not polarised). Ceramic capacitors are not good for timing, very unstable, the numbers in your screen shot (which you should simply have posted as text) show it's drifting. Polyester film type is normally good enough.

It it doesn't react.to the pot I suspect your wiring is wrong there. Take it out, measure the resistance with your multimeter, see if it behaves the way you expect.

Initially installed polyester capacitor forgot to mention both 220nf caps are popyester 630v.

Frequency in screenshot is stable i i took a shot right when i adjusted to 50.8hz after that screen was scrolling with 50.8hz .

It does react to the pot but minimum value is not less than 1.9-2ms . If pot turned the opposite side i am getting very high duty cycles.

Will replace pot with fixed resistor see what will happen.

I suspect breadboard connection and resistance of wires. I had issue with wires on esp8266 circuit and solved only soldering them.

Breadboards can cause problems indeed with connections. In your case I'd suspect the pot itself, though.

Just change R3 to a lower value, say 1K.

That would do the job - but doesn't explain the very high duty cycles. That shows an unexpectedly high resistance in the pot, and why I suspect something is wrong with that pot.

Wvmarle you are right its pot/board connection. I have to press it down to get low values when released its giving very high resistance. Pot is working when outside the board.
Second as i mebtioned i installed 2x220nf on each 555. But schematic asks for second 555 only 100nf. Cant explain how i come up with 220 on board instead of 100 :-).

Will change the pot to resistor anyway i need 3 positions 1ms 1.5 and 2ms.

2x220 nF in series is equivalent to 110 nF... sometimes have to go with what you happen to have on hand :slight_smile:

values for R4 if someone will be interested in building this circuit:

measured right from pot and rechecked with resistors after that.

1ms 4K9
1.5ms 10K1
2.0ms 13k

tolerances of my resistors are 20% so I assume you can round values if using silver or gold stripe(band) resistors.

value for R2 16K2.
Thanks everybody for participating in this discussion.

tolerances of my resistors are 20% so I assume you can round values if using silver or gold stripe(band) resistors.

I have not seen silver and gold bands on resistors for about 40 years. The widest tolerance you can get these days is 5% ( old gold band ) with 1% resistors being a fraction of a cent more expensive.

Anyway because there is a pot in the circuit it doesn't matter. Only with R1 might it matter a bit, but not much.

surepic:
Well, if this idea wont work then i will put arduino nano or micro and will forget about 555 forever :-))

Mike why you were driving servo via fet instead of mosfet? Isnt it more efficient in this shcematic to use mosfet? Something like 2n7000?

I'll take a stab: first I'll assume you mean bi-polar when you wrote fet. If so, then:
Based on the 4k7 pull-up, that servo doesn't require much current to drive it, thus bipolar vs MOSFET is trivial, since power loss is trivial.
BTW: a 2N7000 is not a good choice for 5V switching. More like 2N7002, or even VN2222LLG

Now i need to switch whole circuit from 3.3v 20ma gpio. Current consumption for the circuit with motor is approximately 550ma-560ma 5v.

Any suggestions what transistor/mosfet to use?

surepic:
Now i need to switch whole circuit from 3.3v 20ma gpio. Current consumption for the circuit with motor is approximately 550ma-560ma 5v.

Any suggestions what transistor/mosfet to use?

When you say 550mA-560mA, are you talking average current, peak current, or ???
And, when you say "motor", are you still talking about a Servo, or is it an actual morot? And if so, what kind of motor? Typical brushes included DC motor, or something more exotic?
And will there be any PWM involved? Or, is it just a strait ON for awhile, OFF for awhile?
And, I guess the ultimate, qualifying question is: when you say "whole circuit", do you mean that same circuit, but controlled from a 3.3V port, rather than a 5.0V port. And, will the rest of the "whole circuit" be powered at 5V? In which case, is this a question of voltage translation?

Why am I confused? Because there are two opposing hints:

  • "whole circuit" might imply, "original circuit"
  • yet, "what transistor/mosfet to use" implies a disregard for the "circuitry" that comes before the transistor/mosfet.

In other words, are we disregarding that apparent settled upon circuitry, or is this a question about how to drive the settled upon circuitry? Or, is this a whole new question?