When does your code switch the relays on? I find that some pic programmers (I am presently using a PicKit 3) reset the pic multiple times before they actually begin programming. If you code turns any of the relays on during the first second or so of code execution, then this may well happen several times during each program session. The solution then would have to be to change your code so that it waits longer to turn relays on. Sean On Sat, Feb 11, 2012 at 10:12 AM, Mark Hanchey wro= te: > I have a pic project that uses relays on several pins, none of the pins > are programming pins. The problem I having is that anytime I program the > chip, 18F46K80 , the relays switch on and off rapidly, this causes a lot > of power spiking in the outputs connected and also doesn't do the relay > life span any good either. Anyone faced this problem before ? I thought > maybe raising the resistor value on the transistors driving the relays > might work but wanted to get some input first. > > Are there pins on the pic that are less susceptible to having their > inputs change while being programmed ? Currently it sounds like the > relay is switching about 5 or 6 times during programming. > > Thanks > Mark > > -- > http://www.piclist.com PIC/SX FAQ & list archive > View/change your membership options at > http://mailman.mit.edu/mailman/listinfo/piclist --=20 http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist .