Hi Bob, The LVP is disabled in the configuration and the RB3 pin is being used as digital I/O. You made me curious because there could be an involuntary change in the firmware. I read the firmware of the PIC that crashed and compared what I read when i= t works and they are the same. It should be something that I don=B4t initialize RAM... Thank you for remembering this! Marcus -----Mensagem original----- De: piclist-bounces@mit.edu [mailto:piclist-bounces@mit.edu] Em nome de Bob Blick Enviada em: quinta-feira, 22 de novembro de 2018 02:41 Para: Microcontroller discussion list - Public. Assunto: Re: [PIC) 16F887 - strange behavior=20 Does the '887 have LVP, and is that pin floating? ________________________________________ From: piclist-bounces@mit.edu on behalf of pp5ms Sent: Wednesday, November 21, 2018 3:14 PM To: piclist@mit.edu Subject: (PIC) 16F887 - strange behavior Hi everyone, I am developing in assembly in PIC16F887 an automation equipment for amateu= r radio stations. I've already done a lot of the firmware, currently occupyin= g near 3K. I have as practice, go doing and write on the hardware to do tests and afte= r everything okay go ahead writing new routines. Sometimes these tests are done 5 or 6 times a day as the firmware evolves. I had to explain how I'm working so I can tell what's going on. During these tests and new firmware versions, the hardware virtually stays on all the time, or when I turn off and on to test the system startup, it i= s a few minutes without power. Five days have passed that something happened that I only noticed later. Everything works perfectly, however if I turn off the power and leave it of= f overnight, when I turn on it is not boot. Even if I re-write the program in the PIC it does not work anymore. However (and this is where I do not understand what happens) if I write a firmware from 5 days ago, it works. From that point on, I can re-write the latest version and it's still okay. Only if I turn power off for a long time does not work anymore when I turn on again. With the 5-day program, I can leave the power off that always comes back working at power on. I think about some problem with the hardware, but I have several prototypes (10 actually) and they all exhibit exactly the same problem. The impression I have is that it has some initialization that stays in RAM and it takes a long time to erase on power off and when this happens, comes the problem. My question is: Has anyone ever had any kind of similar problem? I'm really stuck and I think about going back to the program 5 days ago and going re-writing the program I've done again, this time doing tests closer to each new change. Maybe even the routines will be a little different end up getting a bit different and it may be that the problem does not happen anymore. But I would not be very relieved to resover in this way without knowing what actually happens. Thanks for any feedback. Marcus - PP5MS - -- http://www.piclist.com/techref/piclist PIC/SX FAQ & list archive View/chang= e your membership options at http://mailman.mit.edu/mailman/listinfo/piclist --=20 http://www.piclist.com/techref/piclist PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist .