add serial port input to defmt-print#940
Conversation
|
This looks great - thank you for the PR. Can I ask, what's your use-case for getting defmt data over a serial port? |
|
Of course! I'm working on a low power system in which I am moving the chip in/out of various low power modes. This causes some issues with defmt over RTT when the RAM is powered down and seemingly random data is read back. And, more importantly, the chip's SWD silicon consumes a significant amount of power on its own and can't be turned on/off easily during execution. My use case is to redirect all defmt output to a debug UART on the chip, and use a custom defmt handler to manually enable/disable the clock to the peripheral before/after each write. This way, the UART is only consuming current when it is actively logging data and I can see the true current consumption of the system at all other times. |
|
LGTM. Thoughts @Urhengulas ? |
No description provided.