Quote Originally Posted by sccoupe View Post
Ok, thats worked. Disecting it found that it was the MCLRE that made the difference. I'll read up on that as it is the only part of your explanation that I didnt understand.
Look at the chips Data Sheet for which pin is used with MCLRE. That pin must have a pullup resistor if MCLRE is enabled in the config statement.
<br> Rather than changing the config statement in the .inc file each time I would insert a semicolon just before the first letter in the statement and insert the statement at the beginning of my code, every time.