# Servo-Motor with 555 timer

#### PsySc0rpi0n

Joined Mar 4, 2014
1,706
Ok, I need to control a servo-motor with this 555 timer. This is for a school assignment, as usual!

I'm using the 2 diodes version of the astable mode 555 schematic!

So, we were told to consider that the servo-motor turns left for output pulses with tON = 1ms, centered for output pulses of tON= 1.5ms and it turns right for pulses with tON = 2ms and a frequency of 50Hz! We have a 100nF capacitor to work with!

So, as I'm using the 2 diodes version, to be able to get Duty Cycles under 50%, the formulas I'm using for tON and tOFF are:

tON = ln(2)xRaxC
tOFF = ln2xRbxC

So, for 50Hz we have 20ms period.

To get 1ms of tON:

1ms = ln(2)xRax100nF
Ra = 14.4kΩ

To get the tOFF time:
20ms - tON = ln (2)xRbx100nF

Rb = 274kΩ

I'm using a potentiometer for Ra and I'm setting it to 14.4kΩ. Rb is fixed at 274kΩ but I don't know why, I'm not even getting the 50Hz frequency I was expecting. Also tON is larger than expected as also the tOFF.

#### Attachments

• 85 KB Views: 11
• 1.9 KB Views: 2

#### StayatHomeElectronics

Joined Sep 25, 2008
1,073
When you are setting Ra with the potentiometer, to 14.4 kOhm, do you need to connect the remaining portion, the 85.6 kOhm, to ground? If you do not need that remaining portion of the potentiometer, you can leave the end, the third pin, unconnected. Leaving the end unconnected, or floating, will create an open circuit, i.e. no current, through the 85.6 kOhm portion and it will not interact with the circuit.

Leaving the third pin connected to ground will draw some of the current you expect to charge and discharge the capacitor and direct it to ground.

#### PsySc0rpi0n

Joined Mar 4, 2014
1,706
But I think LTSpice will complain about having a floating node! Let me try!

Edited;
I'm still getting 23ms period and 1.2ms of tON. I don't know if those 3ms and 0.2ms from period and tON are from LTSpice modulation or if it is still something wrong! Will the servo-motor still work correctly with those values?

#### StayatHomeElectronics

Joined Sep 25, 2008
1,073
If LTSpice complains, I do not think it should, then connect the third connection of the potentiometer to the middle wiper instead of leaving it floating. That way the 85.6 kOhm portion is connected to same voltage on both sides and, again, no current will flow through it.

#### PsySc0rpi0n

Joined Mar 4, 2014
1,706
It didn't complained but the results were not the expected ones yet!

#### StayatHomeElectronics

Joined Sep 25, 2008
1,073
Here is my guess. The equations do not compensate for voltage drops across the diodes and will therefore give you some error in the final times.

The voltage drops across the diodes will be about 0.7 volts when conducting current. This reduces expected current charging and discharging capacitor. That reduction in current will result in longer times. 10 - 15 % seems reasonable.

#### ericgibbs

Joined Jan 29, 2010
18,055
hi Psy,
Hint: Having two diodes is causing you those problems, try with just one diode across the Rb resistor. [remove D2]

E

#### PsySc0rpi0n

Joined Mar 4, 2014
1,706
hi Psy,
Hint: Having two diodes is causing you those problems, try with just one diode across the Rb resistor. [remove D2]

E

Thanks EricGibbs.

By now I have this part of the assignment ready. I have explained that the difference between calcs and LTSpice simulation is due to the usage of 2 diodes that implies a 2 times 0.7V additional voltage drop which is affecting the capacitor charge timings!

#### ericgibbs

Joined Jan 29, 2010
18,055
hi Psy,
I will post my LTS asc file tomorrow, just for reference.
E

#### ericgibbs

Joined Jan 29, 2010
18,055
Morning Psy,
Here are the LTS sim asc file and plots.
With this very basic 555 timer circuit you will get a slight frequency variation in the frame frequency of 50hZ when the ON period is adjusted, this will not cause any problems in a practical servo application.

E

#### Attachments

• 2.1 KB Views: 3
• 45.3 KB Views: 9
Last edited: