I got this to work, to where the fuel pump would respond to whatever pwm output I would set, but there are a couple problems;
The mosfet is smoking and can't handle the load from this pump, I think even if I add a heatsink. The fuel pump is a Walbro 450 lph and draws 20 amps under high load, and 15 amps just at 43 psi fuel pressure, so it's a beast. Do I need to add a component? Maybe use a high power SSR?
The pump is working at half duty or less when my PWM is maxed out. The Nano is not outputting enough voltage from pin 3 (max is close to 3v @ 255 or 100% duty cycle) to make the fuel pump actually reach it's 100 duty cycle. I tried using the raised timer2 frequency trick, but that didn't change anything.
I was powering the Nano just off of my Laptop USB, so the voltage is a little low that powers the Nano, and I've made an Ethanol Content Analyzer using a Nano before and found that voltage output goes up if you use a higher source voltage to power the Arduino. For the ECA I used an 8v voltage regulator that was powered by a +12v switched source from the car's O2 sensor wiring.
The Nano is not outputting enough voltage from pin 3 (max is close to 3v @ 255 or 100% duty cycle)
Something's wrong... Something could be wired wrong, or you don't have 5V on the Arduino.
Do you get 5V out with nothing but your multimeter connected?
using a Nano before and found that voltage output goes up if you use a higher source voltage to power the Arduino. For the ECA I used an 8v voltage regulator that was powered by a +12v switched source...
If everything's wired right and the Arduino's on-board regulator is working, etc, it shouldn't make any difference because the ATmega chip should be running off 5V.
It's rather frustrating when selecting a MOSFET that they don't ever give you the "real" switch-on voltage. It never shows up in the tabled specifications. You have to infer it from the charts.
That page at Fry's shows the "threshold voltage" can vary between 2.0V and 4.5V. That is the voltage at which it is just barely beginning to switch on. That means that it is on but it has a high resistance. It will be wasting a lot of power and heating up badly at that voltage.
Giving it 5V is not going to help much. It will still get hot. The rated current is only possible when Vgs is 10V or more.
I still have an 8v voltage regulator soldered to the particular Nano that I'm using. Maybe I should pull that off...
I will report back on whether I'm getting 5v or not straight from a pin.
No, not needed. 8volt on V-in will deliver 5volt to the Nano, and won't interfere with USB (supply or data).
Only USB power will drop the 5volt rail (and the PWM levels) to ~4.6volt, because a Nano has a schottky diode in series with the USB supply.
What is the stall current (resistance) of that pump.
Several mosfets can be parallelled if current is a problem.
Could make switching (PWM) slower though, so avoid if you can.
Wise to use a low value resistor (150-220ohm) between Arduino pin and gate(s).
and a 10k resistor from Arduino pin to Arduino ground. https://www.gammon.com.au/motors
Well, you have to be careful that you have all the same heatsinking and drive voltage as the manufacturer used to prove the "20A continuous" but yes, two MOSFETS would provide a good safety margin.
I would pick a bigger MOSFET, myself.
I would use a bigger one, too, but there aren't really any/many logic level MOSFETs that can run much more current.