I'm using a sparkfun arduino pro micro (programs as a leoardo board) and a home made mosfet 'shield'
The mosfets connect to high-ish power 5mm led's, that are to be fitted into a model airplane im making, and they will be the navigation and anti collision lights, as well as switchable landing lights,
The sketch simply turns a few led's on when the board is powred up (nav lights)
as well as flashing some led's at 200mA to mimic strobes (led's run at 70mA constant on, and they are pulsed at 50ms intervals twice every 2 seconds... so should survive)
It also fades a red led up and down with a bright flash, to mimic a revolving anti colision light found on the belly of planes,
And finally it monitors the servo pulses from the reciever, and turns 3 led's on or off depending on the pulse count (relating to a switch on the transmitter being on or off)
The problem i have is that with the transmitter turned off, and hence no pulses going in the input pin, it seems to overload the arduino and make it run slow... so the 50mS pulses of the strobes become more like 1 second pulses.
I tried putting a 10k resistor from the input pin to ground (same as is done with all the mosfets.. thankyou groundFungus for telling me how to use mosfets instead of transistors and the need for the pull down resistor... i used '2N7002KT1G' surface mount mosfets, and 0805 size SMT resistors... my first ever build using SMT components)
But it makes no difference to the arduino if i use a pull down or pull up resistor,
also it doesnt always do it, sometimes the sketch runs at the normal speed with nothing connected to pin 3, other times it runs slow the second the reciever is turned off.
i am wondering if i need some code that listens for the pulses, but when it gets none it stops the board running slow?