Skip to main content

MOSFET Driver Board

Final version?  I hope so.  I have gone back and redesigned my solenoid driver board several times.  In previous versions I attempted to offload some of the logic from the microcontroller.  For example, I used a Schmitt-Trigger [74HC14] with an RC network to provide a single pulse to the solenoid.  Also, I added in a PWM signal to set the average voltage 'seen' by the solenoid.  This worked but was very limiting to have the pulse length hardwired in and it was difficult to adjust without more expensive precision potentiometers.

I chose to simplify my circuit to make it a general MOSFET driver for flexibility.  Since I have more than enough space inside my pinball cabinet, it was not a problem to have the extra boards.  The boards were designed to have 4-channels since by default I would get a minimum of 10 boards for the same price from Seedstudio.  Also, the cheapest board option was restricted to 10cm x 10cm otherwise the price balloons quickly.

Driving 48V from a separate power supply made me nervous about safety and about potentially damaging lower voltage components in the pinball machine.  So I used an optocoupler to isolate the high voltage side (right) from the low logic level voltage side (left).  The high side mosfets all have a common ground because there is a return via D1 to the voltage supply to deal with transients.  There is a separate LR12LG-G Linear Regulator (not shown) that provides the gate voltage.  It was chosen because it was the cheapest 100V rated regulator.

Isolated MOSFET Driver Circuit
What are all these components for?

  • Q1 is a P40NF10 logic level mosfet and sinks the Q1 input to ground.  This is what will handle the current from the solenoids.
  • OK1A is one of two optocoupler circuits in the D223 SOIC-8 package.  This is the physically isolating element between the high voltage side on the right and the low voltage side on the left.
  • R101 is a current limiting resistor so we do not put too much current through the optocouple diode.  It is set to limit the 5V input to 10 mA which seems to be the minimum current for maximum performance.  It could work with a lot less but I am not concerned with power consumption as the pinball machine will be a hog anyways.
  • R102 is a pull down resistor to be used if the buffered input Q1_G cannot be pulled to ground.  It's not a bad idea to keep it in anyways.
  • R103 is to surpress transients and the inrush current into the mosfet.  Many circuits don't include it but it gives me piece of mind.  Why 4.7 Ohm?  The mosfet gate is essentially a capacitor and a large resistor will slow the response time.  It would work fine with a 100 Ohm resistor as I am not switching anything at high frequencies.
  • R104 discharges the Q1's gate.  R103 and R104 form the gate discharge path.  R103 / R104 can set the minimum turn on / off times.
  • D1 is a flyback or freewheeling diode that suppresses transients.  When the solenoid is turned off, the magnetic field collapses which induces a current in the solenoid.  This causes a voltage spike which can lower the lift of your mosfets.


MOSFET Driver Board PCB Layout
The PCB layout now has some nice curves!  The small things drive you nuts.  I could never figure out a best practice for placing mounting holes.  So I ended up following Dangerous Prototypes case design.  I used a 3.2 mm diameter hole to fit a M3 screw that was spaced 4 mm from the horizontal and vertical edges.  Then added in a 4 mm radius fillet. 

Comments

  1. Hi Mike, thanks for sharing your design for the pinball solenoid driver. I've also made a solenoid driver coil for my pinball machine using opto-isolators. My only concern is that I've read that Opto isololaters have a half-life of about five years and that they deterioriate after that. Consequently I'm presently redesigning to use BJTs to drive the gates of my FETS. The other issue that I found is that my flipper driver FETs (IRL540Ns) failed quite regularly because the flipper coils (Sterns) seemed to draw more current than the other coils. After considerable research I went over to a parallel MOSFET design for each flipper and that seems to have sorted out the problem as I no longer have the failure. Thanks again for sharing, I'll be reading on with interest! - Mike

    ReplyDelete
  2. I really enjoyed reading about your MOSFET driver board project! The use of OrCAD PCB Designer seems to have paid off as the final product looks very professional. It's also great to see that you included a detailed description of your design process and the challenges you faced along the way. Thanks for sharing your experience with us!



    ReplyDelete

Post a Comment

Popular posts from this blog

Pinball Cabinet Beginnings

I was getting to the point where I really needed to build on something. I have numerous pinball parts but have nothing to attach them to. I managed to find some pinball plans for a Williams Widebody pinball machine. All the measurements are in mm sadly even though all pinball cabinets are in inches. I converted and change it all to the nearest quarter inch. Well sort of. The guy who measured this was intending on using 45 deg cuts in the corners. My skill saw is too cheap for that so I changed the measurements for butted joints. The interior is set for a 23.5" wide playfield. The length of the cabinet is 51.5" in total. I used 3/4 inch plywood so the bottom would be 50" long for example. You can pretty much dimension the rest from there.  I did get a little chipping of the plywood but I went out and bought a blade with more teeth for finer cuts. It's a 60 tooth saw blade and my skill saw doesn't really have enough power for it so I have

Pinball Solenoid Control

Pinball solenoids come with designations like 23-800.  The first number, 23 in this case, represents the American Wire Gauge (AWG) used.  The second number, and the more important number, is the number of windings which is related to its power rating.  A solenoid with less windings, say 400, is more power and is used for such applications as actuating the flippers.  These solenoids get very hot very quickly, which increases the resistance of the solenoid thereby decreasing the current and therefore the power.  To avoid overheating, these high powered solenoids will have two coils.  One for the main actuation of the solenoid, and another to maintain the position.  The second solenoid will have a smaller wire gauge and more windings.  In example, my flipper 'coils' are 15-411, 15 AWG and 411 windings.  They are quite strong and found in some of the latter Williams pinball machines such as the popular Adams Family machine.   You can find a lot of good additional information