Legohead259 / OlympianESC-Firmware

Firmware for a novel Micro-ROS based electronic speed controller (ESC)
MIT License
0 stars 0 forks source link

[Research Idea]: Look into implementing debugging processes #5

Closed Legohead259 closed 9 months ago

Legohead259 commented 9 months ago

Debugging the code right now is tricky as the primary Serial port is used by the MicroROS agent for the DDS communication. It may be possible to switch the platform over to a UDP transport and use the primary serial bus as expected, but that may introduce unneccessary complication.

First and foremost it may be possible to use the built in ROS2 logger. The ROS2 agent mentions that it has logging levels. It should be investigated.

As a backup, another UART-to-USB converter should be added in parallel and another Serial port be dedicated for debugging. This will complicate the hardware connections to the computer, but will make it easier to debug. If this option is chosen, migrate the logger from Thetis?

Legohead259 commented 9 months ago

Debugging can be accomplished using Serail1. Hook up a USB-UART converter (CH340, FT232, etc) to RX and TX pins on the ESP32 and use it to output diagnostic messages. Implementing a logger like in Thetis is out of scope for the moment