Hello once again. I have yet another question regarding my project.
I am planning on powering my robot using two NPC motors, which I will drive using a custom H-Bridge that will use automotive relays controlled by N-Channel Mosfets (IRF530NPBF) http://search.digikey.com/scripts/DkSearch/dksus.dll?Detail&name=IRF530NPBF-ND. I am using automotive relays because the stall current for the motor reaches 80A, which makes most of the commercial H-Bridges useless. So with that said, I have some questions/concerns that I would like addressed if possible.
Secondly, can I get away with trying to power the Mosfet gate with a lower voltage than the specified?
Lastly and most importantly, what connections do I need to make in order to have a wire running from the vex controller to the gate of my mosfet. The gate only has 1 pin, but doesn’t it take a negative and positive wire to carry a voltage? I am not an expert in electronics so I would appreciate as much help in this area as I can get.
There are a lot of questions there, though it sounds like you are on the right track all the way around. Instead of automotive relays, I might suggest this. It is a relay module wired to operate as an H-bridge at up to 30V/100A. The primary advantage it has over using several individual relays is that you won’t be able to cause a dead short by accidentally closing both CW and CCW contacts at the same time.
Whether you use this relay, or individual automotive relays, you do need coil drivers. You are correct that you need two wires from the controller to the MOSFETs. The MOSFET’s Gate would be wired to the white wire and the black wire would serve as a common ground with the motor battery (-) and the MOSFET’s Source terminal.
I’m not sure if the Vex Microcontroller could directly drive these MOSFETs or not. They have a gate threshold of 2 to 4 V, which is in the neighborhood of what the Vex puts out, but I think you’d have to try it to see. The TIP110 circuit you linked could be used to drive the relays.
Whatever your final circuit turns out to be, put some thought into making sure you can’t cause a dead short through your H-bridge. If you don’t have protective breakers or fuses in place, a short would cause (at best) some major damage, and possibly a fire or exploding batteries!
Do not trust your software to avoid activating both CW and CCW paths at the same time. You don’t want a software bug or controller glitch to cause a short. If you have SPDT relays, you can wire them such that a short is not possible. If you only have SPST relays, then you could add some external logic parts between the VEX and your coil drivers to prevent CW and CCW drivers going active at the same time.
Wow, the Reversing Solenoid is a life saver! I don’t know how I missed that in all my research. And just to make sure, the solenoid has two voltage ratings: the coil rating of 12V and the contact rating of up to 30V. Since my motors will be running at 24V, I will need a seperate 12V battery just to power the coil right? Also, reading the wiring diagram on the website, I’m having a little bit of a problem trying to figure out where I would connect the mosfets. So I will definitely use the solenoid instead of the 4 relays, even though I have already ordered them.
But that is seriously a major life saver, THANK YOU!
And now I just need to read up about coil drivers.
Correct. Coil is 12VDC, and contacts are up to 30VDC.
Generally, yes. However, if your 24V motor battery is actually two 12V batteries wired in series, then you could take the “center tap” as a 12V source to run the coils.
Alternatively, you could see if the 7.2V Vex battery has enough voltage to trigger the relay coils, but I kind of doubt it. In the end, you’ll probably need a dedicated 12V battery to run the relay.
When I’ve had to do something like this in the past, I ran the Vex microcontroller from the 12V battery via an LM7808 voltage regulator, which provided a steady 8V/1A to the Vex.
Right; they just go where the two switches go (on the blue and green leads). In their wiring diagram, the two switches are on the + side of the coils and the coils share a common negative. Hopefully, the relay is not sensitive to polarity (most are not) and so you can let the center contact (black) go to +12V and the blue & green contacts can then each be driven by a MOSFET or TIP111 which complete the circuit to ground.
Glad to be of help. These are fairly rare beasts in my experience, but I’ve always thought they were cool.
Oh, sorry to use a misleading term. I just meant a transistor or MOSFET as we had already talked about. Something to provide low-voltage DC to the coil in the relay. If I have a bit of time later today, I’ll try to draw up a schematic of what I think would work.
oh sorry about dealing my previous post, I didn’t realize that you had already replied and I wanted to change it.
So, from the diagram of the solenoid, the 12V battery would be connected to the purple wire right? Since it seems that the big red and black ones are the ones that actually go to the motor. I don’t want to accidentally use 24 volts on the coil and waste the solenoid.
and once again thanks for the help. You really might have saved the entire project, because I know I would have messed up something using 8 relays.
Exactly right. The heavy red wire will go to the +24V supply. The thinner purple wire would go to the +12V coil battery. Also, since you will be using a separate battery for the motors and the relay coil, I’d recommend NOT connecting all the negatives together as the diagram shows. The -24V battery connection should ONLY go to the heavy black wire and the (-) stud on the relay. The -12V coil connection should ONLY go to the thinner black wire (middle quick-connect on the relay).
A picture is worth 1K words, so I’ll try to post a drawing later today.
I’m glad I could help - I’ve set a few circuits on fire in my time, so I know how easy it is to get a wire crossed here and there. Anything that reduces the chance of errors is a win.
Oh, and for those of you following along, this is the diagram that chessoriginal and I have been referring to:
And for those of you that want a relay like this but don’t need a 100A capacity, IFI sells the Spike Relay, which is a 20A H-bridge relay combined with coil drivers. You can wire this to a pair of Digital Output ports to control Forward/Stopped/Reverse.
A few notes:
*]It uses TIP110 transistors rather than MOSFETs, since I have more experience with those. You may be able to substitute a MOSFET directly by substituting G/D/S for B/C/E.
*]I’ve kept the 24V circuit completely isolated from the Vex controller, which is why the battery negatives are NOT wired together
*]Please make sure to include some type of overload protection as indicated on the diagram. Without that, a short on the 24V circuit could be quite nasty.
*]Wire colors mostly match the wire colors in the diagram from Surplus Center.
*]Obviously, all the exposed conductors need to be insulated.
*]I’ve not personally wired this up to test it, so YMMV…
If you already have the MOSFETs you might as well give them a try. I think they will work if you wire them as the diagram shows. As it happens, they have the same pin arrangement as the TIP110, so you shouldn’t even need to re-arrange any wires. The TIP110 has B/C/E, and the IRF530 has G/D/S.
Correct. A circuit breaker of PTC will have the advantage of never needing to be replaced, whereas a fuse will almost certainly be popped occasionally. If you do use a fuse, pick a slow-blow fuse about 50% above the normal maximum operating current for the motors (driving at full speed up a slight slope).
It would also be a good idea to add a safety disconnect so that you can be sure the 24V motors won’t accidentally power up when you don’t expect them to. This can be a switch, or it can just be an easy way to disconnect a battery terminal. If you use a fuse, then you can just remove the fuse while working on it.
Best of luck, and please do keep us updated.
Posting pictures is always appreciated!
I use a Mac-only application called OmniGraffle Pro. I’ve used it so much for other stuff over the years that I can whip this type of drawing out pretty quickly.