Hi,
I'm trying to run a motor on software controlled speeds. I've figured out, I can easily achieve this by using a MOSFET and a PWM signal.
The motor is quite small. I've figured out that without load on 5V it needs about 120 mA when spun up. My idea is to provide either 9 or 12 V to it and control the speed through the PWM signal. I want to get the power from the USB port. I assume it should supply enough power for the motor with it's small load even on 12 V.
I bought a boost converter to get my 12 volts. It's connected to VIN and GND of an Arduino Nano (compatible). I think that's the right approach to avoid putting stress on the voltage regulator. A future idea might be to connect a battery so my device is portable.
The MOSFET is an IFR520 (the usual MOS Module). Let's assume I'm providing a PWM signal of 128/256 pulses so the motor runs at 6V effectively. The voltage at the terminals looks fine when nothing is connected. My multimeter shows 12 Volts. But when I wire up the motor the voltage drops to about 0.3V which is far less than the motor needs to even get moving.
Again without load I can observe that the MOSFETs V+ and my USB's GND give me the same voltage so I suspect that there's something I don't understand about the boost module and the MOSFET's gate. When I connect a few batteries on the as source for the MOSFET, it works fine. That's why I think that I have a misunderstanding how the MOSFET works when it's switching the potential of its own circuit (the boost module isn't isolated). Is it even possible? Another general question about the IFR520: How does it even work, when I didn't close the loop of the circuit when I was using the battery? As far as I can see the GND of the MOS module is only used to close the circuit so the integrated LED can work.
Here's a drawing of my setup:
With future sight I've considered to immediately boost the voltage of the battery output to 12V and connect that to VIN of the Arduino so the voltage regulator converts it back to 5 volts and I can just say my device runs at 12V (so I could also just use any 9-12 V DC power supply).
Please help me finding my mistake.