I've created a simple controller with a nodemcu to connect a RGB strip that I had to the internet.
The thing that happens is that when I go to plug in the nodemcu to my iMac(to power the nodemcu), I see small sparks on the metal casing of the iMac appear until I fully plug in the USB. I don't know if this is a problem because I've had this working a while and it still works just fine and causes no problems, I'm just curious.
I created a simple fritzing diagram below:
Is this right? I have IRF540N N-Channel Mosfets and 470ohm resistors. The 12v power supply is there to power the RGB strip.
One thing to add is that the mosfets get quite hot when under use does anyone know how to fix this?