SAMD20 SERCOM USART missing receive characters?

Discussions around product based on ARM Cortex M0+ core.

Moderator: nferre

robbie
Posts: 13
Joined: Fri Dec 02, 2011 12:40 am

SAMD20 SERCOM USART missing receive characters?

Tue Aug 16, 2016 11:24 am

We have developed a USART driver for the SERCOM ports of the SAMD20J18 that supports interrupt based serial communications at 115200 baud. We noticed that every now and then a received message is missing a character. Using a logic analyzer we proved the characters is transmitted by the connected party and is on the serial line. Also we verified its character frame timing, which seems OK, just like all other characters surrounding it. So it looks like the USART hardware of the SAMD20 just misses it, as no RXC interrupt is generated for it. Our driver checks for any receive errors (framing/parity/overrun), but there aren't any.
Anybody else having similar troubles?
pozz
Posts: 68
Joined: Fri Jun 13, 2014 2:55 pm

Re: SAMD20 SERCOM USART missing receive characters?

Fri Aug 19, 2016 12:12 am

robbie wrote:We have developed a USART driver for the SERCOM ports of the SAMD20J18 that supports interrupt based serial communications at 115200 baud. We noticed that every now and then a received message is missing a character. Using a logic analyzer we proved the characters is transmitted by the connected party and is on the serial line. Also we verified its character frame timing, which seems OK, just like all other characters surrounding it. So it looks like the USART hardware of the SAMD20 just misses it, as no RXC interrupt is generated for it. Our driver checks for any receive errors (framing/parity/overrun), but there aren't any.
Anybody else having similar troubles?
I used SERCOM in USART mode and interrupts (RXC for receiving characters), but I hadn't your problems.

What is your serial connection to the other device? Is it a point-to-point full-duplex link? Is there any half-duplex transceiver with a driver enable signal?

What is the character in the message that isn't received (the first, the last, in the middle, random)?

Are you sure you don't occur in a buffer overflow condition? 115200bps is only 87 microseconds per character. If your software disables globally the interrupts for a period longer than 87+87 microseconds, you could have a buffer overflow error. Another situation when this could occur is when other interrupts (at the same or higher priority that SERCOM USART RXC) occurs and the ISR takes more than 87+87 microseconds to finish its job.

What is the clock frequency of the CPU?

Return to “SAM D20 Cortex-M0+ MCU”

Who is online

Users browsing this forum: No registered users and 1 guest