I have been trying to control the led with the MOSFET transistor using the Arduino (pleases see attached photos). I connected the circuit (I have disconnected the arduino in the picture, a wire was connected from Arduino to the gate pin).
When I turned on the 5V voltage supply (I want to use this main adaptor as power source as I am going to scale up this project with more LEDs and 12V supply), the led is on unexpectedly. To my knowledge, I thought the drain and source pin will only connect when there is a voltage applied at the gate pin (far left). How come the led already lighted up before I apply any voltage to the gate pin?
I have tested 2 MOSFET and they behaves the same. I am using the IRF520 MOSFET.
That MOSFET should be a 'Logic' type! IRL520 notice the L or a better MOSFET
Thanks for helping me to post the photos up.
I added the 10k resistor from the gate to ground as you stated but the led light is still up..I used a volt meter to check the connection. According to the voltmeter, the drain and source is not shorted as it indicates that there is a resistance of around 400 ohms (I used the beeping test in the voltmeter). Is it because the adaptor is overpowered and force current to jump to the source when it is turned on?