Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

Analogue servo project

Status
Not open for further replies.

dr pepper

Well-Known Member
Most Helpful Member
I just built a prototype analogue servo, it uses a vehicle wiper motor, a pot for feedback, an l298 for power control and serial data in for positional commands on a pic16f88.
The software implements P and I, reasonably crude but it seems to be very effective and quite powerfull for something that cost next to nothing.
I searched the site and didnt find a great deal on servo's, except for controlling rc servo's via software, I was just wondering if anyone else has done this and what kind of results they got, I'm thinking maybe switch to a quadrature encoder for feedback, noise is an issue.
 
I just built a prototype analogue servo, it uses a vehicle wiper motor, a pot for feedback, an l298 for power control and serial data in for positional commands on a pic16f88.
The software implements P and I, reasonably crude but it seems to be very effective and quite powerfull for something that cost next to nothing.
I searched the site and didnt find a great deal on servo's, except for controlling rc servo's via software, I was just wondering if anyone else has done this and what kind of results they got, I'm thinking maybe switch to a quadrature encoder for feedback, noise is an issue.

A quadrature encoder doesn't provide positional information, like a pot does - which is why pots are used in servos.

There was a wiper motor servo example on the net many years ago, don't know if it's still there?, it simply used the custom IC out of a normal servo, with power transistors to feed the wiper motor.

Noise shouldn't be an issue, make sure you use a low value pot, and screened cable to it.
 
I have just finished my searchlight project..

It has two motors connected via two bridge drives ( MOSFET ) My P and I is also quite crude but seems to work exceptionally well too...

Why would you need a better control?.... In any case take a trip to the arduino playground... There you will find a full PID with sample codes

https://playground.arduino.cc/Code/PIDLibrary
 
I never got into arduino.
The motor sometimes sits and sings when the a to d count from the feedback pot changes by one, doesnt seem right professional and would waste power on a battery powered project, I even have seperate supplies for logic and motor.
Yes a quadrature wouldnt be absolute, I'm thinking of a hard stop and a overcurrent detect circuit to reference the software at power up, then keep track of position in software, maybe eeprom too.
For now I programmed a bit of a bandgap, the software tries to get exact on target but when ithas been still for more than 2 secs it releases the target to be within + or - 1 count of the target, that stabilises it somewhat.
 
Would a stepper do what you want and be easier, giving you simple control of speed and position?

John

Edit: Sorry. I posted to the wrong thread.

John
 
Last edited:
Yes it would, however I didnt mention to keep the thread shorter that I'd like the oppotunity to be able to use cheap geared motors from the likes of windscreen wipers for projects, as they are quite powerfull and often free.

Just been looking at roman blacks site, and put together a assembler version of his precision motor speed control, works exceptionally well, big old wiper motor turning at 1 rpm.

Now when I eventually get round to doing my solar panel rotator instead of doing stuff for others I have a choice of dc motor servo, or continuously rotating tracking motor, the latter would be accurate.
 
Well it seems like there going to be no picwork for a while, my pickit2 was playing up not sure why, and I just connected 30v to my kitsrus programmer.
Turns out the insulation on the pass transistor in my power supply is non existant, the case of the supply is at 30v dc bus, I connected - from the power supply to the pic circuit, then when I went to connect the + it touched the case, flash bang, dead pic in the application, dead pic in the programmer as well as the ft232.
prototyping is a dangerous thing.
 
Photo0188.jpg
Found this at a junk sale, its a dc geared motor driving a sliding pointer through nylon strings as per old radio tuner scales, also on the pointer is a linear pot for feedback.
I attached said servo project to and it works, except in the centre of the scale the pointer tends to be unstable, maybe its tight at that point.
I think this was a thermal controler for heating ether, no idea what for.
 
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top