| View previous topic :: View next topic |
| Author |
Message |
guy
Joined: 21 Oct 2005 Posts: 297
|
|
Posted: Mon Jun 15, 2015 11:47 am |
|
|
the problem still appears every few days and in different locations...  |
|
 |
PCM programmer
Joined: 06 Sep 2003 Posts: 21708
|
|
Posted: Mon Jun 15, 2015 1:54 pm |
|
|
| Quote: |
Thanks for the huge support everyone. I will go with my hunches and let
you know if I find something substantial.
|
How about doing the things I suggested ? |
|
 |
guy
Joined: 21 Oct 2005 Posts: 297
|
|
Posted: Mon Jun 15, 2015 11:38 pm |
|
|
| Quote: | | How about doing the things I suggested ? |
I haven't tried recreating the problem in the lab. I don't have the necessary hardware to set it up. Also the list of possible hardware failures is not something I can address directly. Also unlikely that it will affect only one function out of the whole software. I just found out that the problem appears in multiple locations so it's not just one faulty chip.
Race conditions with a character coming in during the interrupt is highly unlikely since the chip runs on 32MHz, the comm. is at 9600 baud and there are no heavy interrupt routines. Everything goes into queues and buffers (including the UART we are discussing). Since I isolated the issue to be that the ISR doesn't get called it's not a queue-handling issue either.
I added more debug code to log several flags such as the obvious U4RXIE, U4RXIF, UART4EN. This is probably the last chance of finding a bug in my code. Otherwise it's either the compiler or the chip, and both I can only solve with a workaround.
I also contacted Microchip to see if there is a known hardware issue there not yet published. |
|
 |
PCM programmer
Joined: 06 Sep 2003 Posts: 21708
|
|
Posted: Tue Jun 16, 2015 12:27 am |
|
|
| Quote: | I haven't tried recreating the problem in the lab. I don't have the
necessary hardware to set it up. |
The 24FJ64GA308 receives four serial streams. Why can't you emulate
these streams with additional PICs, or with software running on a PC ?
(Add a card to the PC with multiple serial ports on it). I would probably
just use multiple PICs. |
|
 |
guy
Joined: 21 Oct 2005 Posts: 297
|
|
Posted: Tue Jun 16, 2015 3:38 am |
|
|
First of all this type of emulation will only emulate part of the whole setup without other activities (I/Os other activities) so if this is a case of mutual interference of some sort it will not be detected. Secondly, once I recreate the problem (after a few days of runtime) the next action would be to stop the debugger and start investigating so for this I need a dedicated computer and debugger which I don't have. Most chances the PIC-kit3 will also get reset after some time from an occasional spike...
The approach of recreating the environment is a great one but not quite suitable in this case. I'd rather run some debug/logging code in a remote system.
Thanks! |
|
 |
|