Sometimes on reboot, relay switches position for a few seconds

Sometimes on reboot, relay switches position for a few seconds

Is there a way to prevent this?

I am using Arduino Yum and the relay is connected directly to output pin, 5v and gnd.

Maybe with some circuitry?

regards,

Sean.

You would need to tell us how it is wired at the moment.

I would not have the relay directly to the output of the µc. The relay will draw to much current. I would feed the base of a transistor with the output of the µc and using a seperate PS +collector - emitter connect the relay to the collector side and use a flyback diode on the relay. Make sure you properly bias the transistor to get the effect/responce you want.

*** See Attachment ***

Loading down the µc is never a good thing and can cause funny behaviors and catastrophic failures.

thanks for the replies, I am using pin 3 of the digital out... no good?

thanks for the drawing, any chance of a link to a breadboard layout, I am still new on my electronics :) ?

found great link: http://www.codeproject.com/Articles/724881/Arduino-How-to-wire-a-relay

thx for all your help guys