Hello,
I had encountered framing errors when running automated tests that utilize UART CLI in my main code base. Currently what the test does is it sends a CLI command through the serial port and waits for the device to run the command and respond to the command. After the test gets the response, it sends another command. The issue that I am seeing is after a while of having commands constantly go through the device, it eventually reaches a point where it gets a framing error.
I had tested to see if the example code for the nRF52480 also encounters this issue and I had found that it does.
Here are the steps I took to produce the issue:
1. I flashed the cli example in the SDK under examples/peripheral/cli
2. I had the automated test (made with a python script) send the command "print all hello my name is nrf52"
3. I then had the test read the serial and check if the output was "hello my name is nrf52". If the output is not this, then the test had failed for that cycle
4. I had the test run for about 250 cycles and at least 1 of those cycles would have a framing error (usually a lot more than just 1 fail though)
I was wondering if there was any known method that would prevent this framing issue from occurring? The only effective one that I have found so far is by putting a 100ms delay before the device responds to the test. I am hoping there might be a solution that does not rely on a delay though.