I'm making a small honda strimmer engine into a compact generator for topping up batteries in the field. It uses a motorbike stator, flywheel and rectifier/regulator.
This small engine has no governer so I know that as the battery charges up, the load decreases, the revs will rise and as i want to leave this unattended that could be bad news.
It feels as though i could make a governor by using a servo to drive operate the throttle and a simple rpm pickup to establish speed. I could also add a timed shutdown or a shutdown when the throttle has reduced to a preset limit.
Is driving servos from zbasic easy, i couldn't find any examples after a quick look through the app notes.
Making an engine governor
Re: Making an engine governor
It is quite feasible. Many years ago I did the same for a 12KW diesel genset using a magnetic pickup mounted near the flywheel for the RPM input and a linear actuator to control the throttle. My implementation was so long ago (pre-ZBasic) that I used a Basic Stamp II having no floating point and extremely limited RAM. Because the RAM was so limited I needed an external RAM chip to store the historical information to implement the PID control loop algorithm. There is some information, including photos, at the page below.FFMan wrote:It feels as though i could make a governor by using a servo to drive operate the throttle and a simple rpm pickup to establish speed.
http://kinzers.com/don/GenSet
There is a good article on PID control on wikipedia and a lot more information is available elsewhere. Tuning the algorithm will be a trial and error proposition due to the reaction time of the various elements of your particular system (throttle positioning, throttle response, generator output curve, etc.).
- Don Kinzer
thanks Don.
Nice project of yours, different scale to mine but principal is similar. I was going to use a magnetic pickup also, perhaps even using the existing stator magnets which are 3 pieces.
I am familiar with PID as i got part way through building a cruise control which is a very similar proposition.
Are you able to point me in the direction of any servo control example code ?
Nice project of yours, different scale to mine but principal is similar. I was going to use a magnetic pickup also, perhaps even using the existing stator magnets which are 3 pieces.
I am familiar with PID as i got part way through building a cruise control which is a very similar proposition.
Are you able to point me in the direction of any servo control example code ?
I don't have any particular examples. Much depends on the stepper/servo that you choose and whether you choose to use a control chip (as I did - Hurst 220001, now discontinued) or produce the phased drive signals directly. You should be able to find good information about the drive requirements for the motor that you choose. I suspect that you can find some Arduino code for stepper control.FFMan wrote:Are you able to point me in the direction of any servo control example code ?
- Don Kinzer
ok - i rather thought servo driving was a regular zbasic thing and i would be able to drive it using some pulseout commands.
If not this looks usable http://www.ebay.co.uk/itm/282345296797? ... EBIDX%3AIT
and with the clutch disengaged gives manual control
If not this looks usable http://www.ebay.co.uk/itm/282345296797? ... EBIDX%3AIT
and with the clutch disengaged gives manual control