Mosfet gate voltage

Yea, I'm reading it with the DMM when it is fully on (255). I also have tried code without the PWM by just using digital write.

@Tesla, two questions:

  1. Is there any mechanical load on the motor, or is it just spinning free?
  2. Is the 7805 getting hot?

Something to try, test the drive capability of the MCU. Remove the motor and MOSFET, try to drive a purely resistive load from the ATmega. Connect a 220-ohm resistor from an output pin to ground. Drive the pin high, measure the pin voltage. Now connect the resistor from the pin to +5V and drive it low, again measure the pin voltage.

The motor is just spinning free, and the 7805 is not getting hot. In fact I can't find any part of the circuit getting hot. I tried connecting the 220-ohm resistor and read 4.74V when driven high from output to ground. It measures 0.47V when driven low from output to +5V.

Here are some photos of my circuit.