Jump to content

Trouble controlling firing switch with MOSFET


Recommended Posts

Hi,

So I'd like to control the firing switch via a microcontroller, but I'm having some trouble. I understand that unlike the up and down switch headers, the firing header is at battery voltage and is active high. My question is how do I switch that ~12v with a 3.3v signal from the microcontroller? Will I need two separate transistors, one PNP mosfet for shorting the switch and another for controlling that mosfet? Should I step-up the 3.3v?

Any help would be greatly appreciated.

Link to comment
Share on other sites

Bapgood said:

First question is what is the reason you want to control the fire switch with a mosfet?



I'm interested in adding functionality to the board via an external microcontroller. I plan on adding additional sensors for control/interface.
Link to comment
Share on other sites

lexalove said:

May I ask why you are using a mosfet for such a small current circuit?
Seems all you need is a standard transistor circuit with a pull-down resistor? You're trying to replicate a single pole N/O switch, right?




I wasn't sure what kind of current to expect from the switch? I had trouble burning out a 2N3906 I tested it with, so I didn't expect the current to be very low. I'll measure it tonight to know for sure
Link to comment
Share on other sites

Still having trouble reliably triggering the fire action. I'm using a 2N3906 PNP transistor driven by a ~3.3v signal. I either burn out the transistor or I'm unable to close the switch so it just continuously fires. I've tried pulling a 2N3904 NPN, different arrangements of pull-down or pull-up resistors and I'm still lost.

A couple things I've learned though:
There is a 1k resistance between ground and the Fire - header.
My multimeter is telling me 0.5ma is running across the headers, but that's way too low, so I'm not sure what the actual value is.

Any help or clarification on John's solution from this thread would be amazing.

Link to comment
Share on other sites

fostac said:

Still having trouble reliably triggering the fire action. I'm using a 2N3906 PNP transistor driven by a ~3.3v signal. I either burn out the transistor or I'm unable to close the switch so it just continuously fires. I've tried pulling a 2N3904 NPN, different arrangements of pull-down or pull-up resistors and I'm still lost.

A couple things I've learned though:
There is a 1k resistance between ground and the Fire - header.
My multimeter is telling me 0.5ma is running across the headers, but that's way too low, so I'm not sure what the actual value is.

Any help or clarification on John's solution from this thread would be amazing.

If I understand how the fire button works correctly, you can use an NPN transistor (2N3904 is fine). With base at or below emitter potential (less than voltage drop of base-emitter junction), unbiased, no current flow. Base forward biased (3.3V is plenty), current flow. Fire terminals would be +12 side to collector as shown and the other side replaces where ground is shown to the emitter resistor. CPU output pin to base resistor (your CPU output pin is simulated by the 0 and 3.3V sources in the screen grabs). Hopefully the simulation makes sense to you. Forward bias current through base of transistor (base emitter junction) and it conducts. Zero bias current, it doesn't conduct. Classic emitter follower. You may have to experiment with what the DNA wants to see at the other side of the fire button. Another approach would be classic open collector / common emitter configuration. See the third simulation screen grab. Some CPUs have at least a few open collector outputs. If yours does, you don't even need a transistor, just a current limiting resistor.

image.jpg

image.jpg

image.jpg

Link to comment
Share on other sites

Mad Scientist said:

[QUOTE=fostac]Still having trouble reliably triggering the fire action. I'm using a 2N3906 PNP transistor driven by a ~3.3v signal. I either burn out the transistor or I'm unable to close the switch so it just continuously fires. I've tried pulling a 2N3904 NPN, different arrangements of pull-down or pull-up resistors and I'm still lost.

A couple things I've learned though:
There is a 1k resistance between ground and the Fire - header.
My multimeter is telling me 0.5ma is running across the headers, but that's way too low, so I'm not sure what the actual value is.

Any help or clarification on John's solution from this thread would be amazing.

If I understand how the fire button works correctly, you can use an NPN transistor (2N3904 is fine). With base at or below emitter potential (less than voltage drop of base-emitter junction), unbiased, no current flow. Base forward biased (3.3V is plenty), current flow. Fire terminals would be +12 side to collector as shown and the other side replaces where ground is shown to the emitter resistor. CPU output pin to base resistor (your CPU output pin is simulated by the 0 and 3.3V sources in the screen grabs). Hopefully the simulation makes sense to you. Forward bias current through base of transistor (base emitter junction) and it conducts. Zero bias current, it doesn't conduct. Classic emitter follower. You may have to experiment with what the DNA wants to see at the other side of the fire button. Another approach would be classic open collector / common emitter configuration. See the third simulation screen grab. Some CPUs have at least a few open collector outputs. If yours does, you don't even need a transistor, just a current limiting resistor. [/QUOTE]

This worked perfectly! I got caught up over thinking it after reading that other thread where he settled on using a relay.

Thanks again Mad Scientist :D
Link to comment
Share on other sites

fostac said:

[QUOTE=Mad Scientist][QUOTE=fostac]Still having trouble reliably triggering the fire action. I'm using a 2N3906 PNP transistor driven by a ~3.3v signal. I either burn out the transistor or I'm unable to close the switch so it just continuously fires. I've tried pulling a 2N3904 NPN, different arrangements of pull-down or pull-up resistors and I'm still lost.

A couple things I've learned though:
There is a 1k resistance between ground and the Fire - header.
My multimeter is telling me 0.5ma is running across the headers, but that's way too low, so I'm not sure what the actual value is.

Any help or clarification on John's solution from this thread would be amazing.

If I understand how the fire button works correctly, you can use an NPN transistor (2N3904 is fine). With base at or below emitter potential (less than voltage drop of base-emitter junction), unbiased, no current flow. Base forward biased (3.3V is plenty), current flow. Fire terminals would be +12 side to collector as shown and the other side replaces where ground is shown to the emitter resistor. CPU output pin to base resistor (your CPU output pin is simulated by the 0 and 3.3V sources in the screen grabs). Hopefully the simulation makes sense to you. Forward bias current through base of transistor (base emitter junction) and it conducts. Zero bias current, it doesn't conduct. Classic emitter follower. You may have to experiment with what the DNA wants to see at the other side of the fire button. Another approach would be classic open collector / common emitter configuration. See the third simulation screen grab. Some CPUs have at least a few open collector outputs. If yours does, you don't even need a transistor, just a current limiting resistor. [/QUOTE]

This worked perfectly! I got caught up over thinking it after reading that other thread where he settled on using a relay.

Thanks again Mad Scientist :D[/QUOTE] Awesome, great news! Can you post the schematic of what you settled on? I'm curious as to whether the emitter follower configuration allows enough current to flow to fire the DNA 200. Or did you go with common emitter? Something else entirely?
Link to comment
Share on other sites

Mad Scientist said:

[QUOTE=fostac][QUOTE=Mad Scientist][QUOTE=fostac]Still having trouble reliably triggering the fire action. I'm using a 2N3906 PNP transistor driven by a ~3.3v signal. I either burn out the transistor or I'm unable to close the switch so it just continuously fires. I've tried pulling a 2N3904 NPN, different arrangements of pull-down or pull-up resistors and I'm still lost.

A couple things I've learned though:
There is a 1k resistance between ground and the Fire - header.
My multimeter is telling me 0.5ma is running across the headers, but that's way too low, so I'm not sure what the actual value is.

Any help or clarification on John's solution from this thread would be amazing.

If I understand how the fire button works correctly, you can use an NPN transistor (2N3904 is fine). With base at or below emitter potential (less than voltage drop of base-emitter junction), unbiased, no current flow. Base forward biased (3.3V is plenty), current flow. Fire terminals would be +12 side to collector as shown and the other side replaces where ground is shown to the emitter resistor. CPU output pin to base resistor (your CPU output pin is simulated by the 0 and 3.3V sources in the screen grabs). Hopefully the simulation makes sense to you. Forward bias current through base of transistor (base emitter junction) and it conducts. Zero bias current, it doesn't conduct. Classic emitter follower. You may have to experiment with what the DNA wants to see at the other side of the fire button. Another approach would be classic open collector / common emitter configuration. See the third simulation screen grab. Some CPUs have at least a few open collector outputs. If yours does, you don't even need a transistor, just a current limiting resistor. [/QUOTE]

This worked perfectly! I got caught up over thinking it after reading that other thread where he settled on using a relay.

Thanks again Mad Scientist :D[/QUOTE] Awesome, great news! Can you post the schematic of what you settled on? I'm curious as to whether the emitter follower configuration allows enough current to flow to fire the DNA 200. Or did you go with common emitter? Something else entirely?[/QUOTE]

I ended up with a common collector configuration that seems to work well. I can trigger a single fire by pulling HIGH for > 10ms.

Untitled.png 
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...