Shop OBEX P1 Docs P2 Docs Learn Events
How can I make this circuit more robust? — Parallax Forums

How can I make this circuit more robust?

DavidGregDavidGreg Posts: 38
edited 2009-11-20 18:48 in Propeller 1
I've built a daughter board for Gadget Gangster's Propeller Platform. It is designed to control 4 solenoids via IRF3708 and high current servos (which I'm not using right now) directly from a battery input voltage. I'd also like to trigger a CDI spark exciter which is designed for RC engine applications. I've attached the basic schematic below.

I've had quite a few problems with what I think are random resets. Everything seems to work perfectly if either the solenoids or the ignition is operated independently with the board. However, I've had what appear to be random propeller resets, depending upon how I power everything. Ultimately, I'd like to power the propeller platform, the ignition, and the solenoids all from the same battery. In the current configuration, this seems to be the most unreliable configuration. I'm currently powering the propeller platform with a wall-wart and the solenoids and ignition with the same battery - this seems to be fairly reliable at the moment.

My question is - how can I make this circuit more reliable - any general tips or suggestions to fix things that might be causing resets? I realize its a vague question but I've been unsuccessful in finding a reliably reproducible error.
3060 x 2310 - 264K

Comments

  • Mike GreenMike Green Posts: 23,101
    edited 2009-11-01 14:34
    You're probably getting noise from both the solenoid switching and the CDI system back into the power supply. Also, you need a reverse connected diode across the solenoid. The MOSFET's substrate diode may function that way, but you may still need a discrete diode (like a 1N4001).

    Have two separate grounds, one for the power circuitry like the solenoid and CDI and one for the Propeller. Connect both ground points to the power source ground.

    Have two separate +3.3V supply points, one for the power circuitry and one for the Propeller. Place bypass capacitors across each supply point to its ground point. Use 0.1uF on both. Also use maybe 10uF 6V tantalum on the Prop. Use 100uF 6V or more on the power circuitry. Connect both +3.3V supply points to the power source. Consider using a power supply choke between the power circuitry and the power supply (maybe a couple of uH).
  • Beau SchwabeBeau Schwabe Posts: 6,568
    edited 2009-11-01 14:47
    DavidGreg,

    Place a reverse biased diode across your solenoid, and place a 1K resistor from the RESn pin on the Propeller to VDD.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Beau Schwabe

    IC Layout Engineer
    Parallax, Inc.
  • DavidGregDavidGreg Posts: 38
    edited 2009-11-20 01:55
    This is going to drive me batty!!!

    I think I can rule out that the solenoids cause the problem: Resets never occur when the solenoids are used by themselves, and they do sometimes occur when the CDI is triggered without the solenoids connected.

    Here is the schematic to the gadget gangster board I'm using gadgetgangster.com/scripts/displayasset.php?id=220 I've added the recommended 1k pull up to 3.3V for the Resn pin. It has capacitors directly connected to both voltage regulators (although I'm not really using the 5V rail). The prop board gets power and ground through a single header connection for both and both run directly to the battery.

    I've switched to using a MOSFET to pull the CDI trigger to ground, with a pullup to Vbat. However, based upon my reverse engineering of the CDI ignition, the pull up shouldn't really be required. The only wire that runs to the prop boards is the trigger wire.

    Here's the thing thats driving me crazy: it works SOMETIMES..... it will spark a few thousand times (at 40 Hz) with no resets. Turn everything off, come back 10 minutes later.... sparks 50 times, reset, spark 40 times, reset. Walk away for 20 minutes, come back, sparks once, reset. Come back the next day, sparks for 5 minutes straight with no resets.

    I've tried diodes in various random places. I've tried adding the capacitor you can see in the picture across the prop board power terminal.

    Help.

    Please.

    Post Edited (DavidGreg) : 11/20/2009 2:00:37 AM GMT
    2144 x 1424 - 324K
    1650 x 1275 - 109K
  • Mike GreenMike Green Posts: 23,101
    edited 2009-11-20 03:43
    Any time you have fast high voltage spikes running around and anytime you have solenoids or transformers or relays, you will have noise spikes. These can be propagated through ground loops, through inductive pickup, through capacitive transfer, etc. You need to add bypass capacitors, snubber diodes, shielding, avoid ground loops or anything even resembling them, etc. I won't say that there is no such thing as too much bypassing, but you probably need more than what you have. Shield the CDI. Shield the wires to and from it. Follow the other suggestions I made two+ weeks ago. Don't be stingy with bypass capacitors and filter inductors.
  • Dr_AculaDr_Acula Posts: 5,484
    edited 2009-11-20 04:57
    My gut feeling is that it would be almost guaranteed to reset. I'm not an expert on this though I have experimented with all the things Mike suggests. In spite of this, I still have picaxe chips that reset when a flouro light is turned on in the same room - in spite of all the shielding and protection. On the other hand, I have had micros controlling an electric fence directly and I've got a micro in my car controlling the fan.

    One of the first things I pulled to bits to learn about electronics was a radio controlled car, and the first thing I noticed is seperate power supplies for the electronics and for the motors. I also noticed capacitors soldered onto the motors. Much later, I bought a CRO and saw the pulses and how they can go all over the place.

    So perhaps start with seperate supplies. Pick a common 'ground' point (probably the earth of the high current battery pack) and run ground wires out from this in a star network to each solenoid, and to the negative of the 'electronics' battery pack. Bypass caps. Definitely need those snubber diodes. Hopefully that will work and we won't be having to go to metal boxes with ferrites on every wire that goes into the box.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    www.smarthome.viviti.com/build
  • DavidGregDavidGreg Posts: 38
    edited 2009-11-20 18:48
    I've done some debugging with separate pier supplies, but for the end use, I really want one supply.


    This morning I added a diode in series with the pullup on the moshet trigger, mimicing the trigger input on the CDI module.


    That seems to have helped quite a bit, it's now run for a while on spark o ly as well as with the solenoids with out resets. I'm still cautious, as I have thought I'd fixed it before.

    Thanks for the help, I just wish there were a better way to debug the problem.
Sign In or Register to comment.