EcoModder.com

EcoModder.com (https://ecomodder.com/forum/)
-   OpenGauge / MPGuino FE computer (https://ecomodder.com/forum/opengauge-mpguino-fe-computer.html)
-   -   Switched power source (https://ecomodder.com/forum/showthread.php/switched-power-source-10430.html)

Sebastian 10-01-2009 03:25 PM

Switched power source
 
First please excuse my english. I will try my best :thumbup:

I'm going to mount a MPGuino to my motorcycle over the winter. But I won't leave it on it permanently if not necessary. I read it needs a non switched power source, so what will happen if I unplug it between the rides, lost data? (I also know I should wait 20s for reconect, no problem with that)

If somebody is interested: I have to rewrite the code so it outputs "european metric" units (L/100km). I hope I'm able to do that based on the 0.75 metric version (my programming skills are limited). Hints are welcome and of corse I will publish the result here if it works!

Edit: Should I expect any problems due to high rpm on a motorcycle? Redline is around 11.000rpm, and it injects on every top death center (like 2 stroke engine) cause it hase no camshaft sensor. So MPGuido may meter up to 22.000rpm..

jonoxer 10-01-2009 06:34 PM

I can't speak for the effect of unexpected loss of power on the original MPGuino but it's a big problem for my version (OBDuino running on a Mega) because I have it writing to a USB memory stick so I took specific steps to alleviate the problem. Maybe the same technique could be applied to other versions.

I'm feeding raw power to a really big capacitor with the positive side feeding through a diode to an LM2940CT-5 (the automotive-rated version of the 7805) which feeds the Arduino. Across the capacitor I have a voltage divider with the lower half protected by a 5.6V zener diode set up so that in normal operation the divider is between about 3.8V and 4.5V. That's then fed to an interrupt on the Arduino, and the code has an ISR to perform an "emergency shutdown" if the interrupt is triggered. That includes setting a flag to force closure of any files open on the USB memory stick so they're not corrupt or lost.

The capacitor stores enough energy to keep the Arduino and all its peripherals running for a few milliseconds after power loss, which is barely enough. It's also powering a 20x4 display and backlight, a GPS module, and the USB memory subsystem though. My plan is to have the ISR cut power instantly to the GPS and the display to try to buy a few more milliseconds for the cleanup to finish.

Cheers :-)

Jonathan Oxer
Practical Arduino: www.practicalarduino.com
Geek My Ride: www.geekmyride.org

drbobwoolery 10-08-2009 09:07 AM

Tracking an undesired reset problem in my preassembled unit, I put another diode beside the polarity reversal protection diode in the +12 line, and connected a RS "heavy duty" (don't bother showing me the cheap ones, if this is the high grade) 9V connector and alkaline battery. This way, the battery supplies the unit whenever the +12V feed goes below 9 volts. This eliminates the flaky main power in troubleshooting. FWIW


All times are GMT -4. The time now is 11:41 AM.

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
Content Relevant URLs by vBSEO 3.5.2
All content copyright EcoModder.com