Current General Plan:
Utilize Teensy x.x
Utilize FreqCount or another function as my engine turns 1800 RPM and I believe counting the teeth on the ring gear with a proximity switch will be best for determining the engine's actual RPM.
At 1800 RPM and 150(ish) teeth on the ring gear, I will see a frequency of 270 Khz. I would also display RPM utilizing LCD after scaling pulses into RPM.
So setpoint will be 1800 RPM - basically start the engine and have it run at 1800 RPM.
Input will be a frequency in the range of 250 to 300 Khz if I count teeth. It would be 1800 if I count crankshaft rotations off of the main pulley.
Output will be a servo (or stepper) that moves the connecting arm to the carburetor - stroke is about 1" from slow to wide open.
Engine is driving a generator, so load will be varying as "things" randomly turn off and on, requiring more/less power.
PID will compensate for increasing and decreasing loads by "pressing the gas or letting up on the gas" (servo) at the right time and the right amount.
PID will need to be fast to prevent low/high voltage conditions for appliances and other "things" connected to the generator.
This is a marine generator and it currently uses a "mechanical governor" that is belt driven from the crankshaft. As it spins, it "slings" weights away from center and this causes an arm to move, which is connected to the single barrel carburetor. It is kind of like a big lawn mower engine - 4 cylinders. So, there is no emission control, no ECU, etc. The photo below shows the mechanical governor. The spring dampens the the mechanical movement, there are adjustment screws and limit screws, etc. But all the governor is doing is moving that arm connected to the carb. I thought the pictured servo could do that, with PID. Does this info help? My mechanical governor is going out and they want $850 for a new one. I think the Teensy/servo/sensor can be had for $75... so it's worth a go? Or not!
Is this pretty straightforward? Got any ideas to get me going?
Utilize Teensy x.x
Utilize FreqCount or another function as my engine turns 1800 RPM and I believe counting the teeth on the ring gear with a proximity switch will be best for determining the engine's actual RPM.
At 1800 RPM and 150(ish) teeth on the ring gear, I will see a frequency of 270 Khz. I would also display RPM utilizing LCD after scaling pulses into RPM.
So setpoint will be 1800 RPM - basically start the engine and have it run at 1800 RPM.
Input will be a frequency in the range of 250 to 300 Khz if I count teeth. It would be 1800 if I count crankshaft rotations off of the main pulley.
Output will be a servo (or stepper) that moves the connecting arm to the carburetor - stroke is about 1" from slow to wide open.
Engine is driving a generator, so load will be varying as "things" randomly turn off and on, requiring more/less power.
PID will compensate for increasing and decreasing loads by "pressing the gas or letting up on the gas" (servo) at the right time and the right amount.
PID will need to be fast to prevent low/high voltage conditions for appliances and other "things" connected to the generator.
This is a marine generator and it currently uses a "mechanical governor" that is belt driven from the crankshaft. As it spins, it "slings" weights away from center and this causes an arm to move, which is connected to the single barrel carburetor. It is kind of like a big lawn mower engine - 4 cylinders. So, there is no emission control, no ECU, etc. The photo below shows the mechanical governor. The spring dampens the the mechanical movement, there are adjustment screws and limit screws, etc. But all the governor is doing is moving that arm connected to the carb. I thought the pictured servo could do that, with PID. Does this info help? My mechanical governor is going out and they want $850 for a new one. I think the Teensy/servo/sensor can be had for $75... so it's worth a go? Or not!
Is this pretty straightforward? Got any ideas to get me going?