asyd
August 25, 2015, 10:52pm
1
Hello,
I’m trying to understand how to debug the firmware, to get messages like the one we can find here: https://github.com/spark/firmware/blob/v0.4.4/system/src/system_cloud.cpp#L576
So, I tried to clone the spark/firmware github repositry, create a branch from v0.4.4 tag, and upload the firmware using:
cd modules/
make clean all program-dfu PLATFORM=photon DEBUG_BUILD=y PARTICLE_DEVELOP=1
All three binaries was uploaded successfully to the device, but I still don’t have any error message when using
particle serial monitor
I tried to connect with minicom too, but w/o success.
asyd
August 26, 2015, 8:35am
3
Hello @kennethlimcp ,
thanks for your reply but it’s the documentation I followed (i forgot to mention it). But where to place the:
SerialDebugOutput debugOutput; // default is 9600 and log everything
code? and don’t tell me it’s in the user application because it’s the firmware I want to debug, not my app
Thanks
mdma
August 26, 2015, 10:23am
4
Yes, it goes in your application in global scope just as it says in the docs.
asyd
August 26, 2015, 12:41pm
5
Sure I already tried that, but I don’t have any messages from the firmware. I want to debug a handshake issue with own server, so I need to use serial_dump from communication/src
Output messages should be displayed on the USB serial (ttyACM), right?
mdma
August 26, 2015, 12:44pm
6
Yep. You’re not going to get the serial_dump messages from the comms lib. It would be best to change them to debug statements.