I'm using the bare metal library Circle (https://github.com/rsta2/circle) for my project and i'm facing a weird problem.
I have UART0 setup in FIQ mode to receive some serial data, with the provided class CSerialDevice which works fine in a minimal example (https://github.com/rsta2/circle/blob/ma ... serial.cpp)
However in my application, the UART stops working after a random amount of time.
I checked the ARM_IC_FIQ_CONTROL register (address 0x3F00B20C on RPI3B) and it's normally 0xB9, telling it's enabled (0x80) and mapped to the UART peripheral (0x39).
When the UART stops working, this register suddently reads 0. The last interrupt doesn't trigger any error code.
I read the BCM2835 datasheet (https://www.raspberrypi.org/app/uploads ... herals.pdf) about UART and the document about its PL011 UART implementation and i can't find any reason for the FIQ control register to be cleared automatically by something.
It seems I can simply re-write 0xB9 to the register to make the UART work again (how inconvenient and hacky!)
I was first suspecting a memory leak/corruption in my code that could overwrite that memory address. But chances that it writes to this address specifically without affecting the rest of the operation are quite small - so i'm triple checking my code but I'd also like to get your impressions on that. What would you check/investigate for this issue?