Still Having problems with Uarts

Moderator: Benj

Post Reply
jethronull
Posts: 30
Joined: Tue Dec 04, 2012 4:03 am
Has thanked: 1 time

Still Having problems with Uarts

Post by jethronull »

Hi Guys,

Looking back over posts for problems with Uarts seems like I posted half of them. I did finally get things stable and workable, but I have changed the schematic a little, just changed pins definitions and increased to larger processor in the same family. Now I have serial issues again. The processor reboots on about 50% of incoming serial data. I can disable the decoding code and it still crashes so I am sure it is the ReceiveRS232Char() itself. The serial interrupts still throws up warnings of potential stack corruption due to the delay_us thing thing but I have confirmed that this is not the culprit because I still crashes when put ReceiveRS232Char() in the main loop diable the interrupt routine. Out of curiosity (or desperation) tried using ReceiveRS232String(), same thing, and even tried switching to software Uart to see if it was something to do with the PIC - nope, still crashes.

Really hoping you can see the problem or think of a workaround. Thanks chaps.

Jon
Attachments
Controller Test 3-7.fcf
(155.15 KiB) Downloaded 433 times
Jon/JethroNull

brandonb
Posts: 438
Joined: Mon Aug 29, 2011 12:26 am
Location: arizona
Has thanked: 175 times
Been thanked: 173 times

Re: Still Having problems with Uarts

Post by brandonb »

hopefully this is not the problem but i was looking to get this chip and noticed that in the erratica datasheet it says
The EUSART asynchronous operation
may miss the Start bit edge.
LSb of transmitted data can be corrup
http://ww1.microchip.com/downloads/en/D ... 80514E.pdf

jethronull
Posts: 30
Joined: Tue Dec 04, 2012 4:03 am
Has thanked: 1 time

Re: Still Having problems with Uarts

Post by jethronull »

Mea Culpa ! I found the problem, not software at all. The power supply section had the wrong chip which wasn't delivering the required current which allowed the rails to be pulled down when the RF module received a message (which went to the PIC). Sorry guys, should have tested the hardware first.

Brandon, thanks for the heads-up. That's a pretty disturbing admission by Microchip. I'll have to watch out for that.

Jon
Jon/JethroNull

Post Reply