Open froha opened 2 weeks ago
Thank you for reporting this issue. We’ll let you know if we need more information to investigate it. Additionally, if you're working with GDB/LLDB, please note that the code is open source at https://github.com/microsoft/MIEngine/wiki/Contributing-Code . Your contributions are always welcome and appreciated.
Don't trust the debugger! And it is dangerous for debugging microcontrollers, when the wrong output is switching.
Debugsession was with cppdebug and mingw-w64.
Environment
Bug Summary and Steps to Reproduce
Bug Summary: I'm not sure if this is the correct extension for the bug. It is from an old c-project.
Hovering over a define with an expression, will lead the gdb to execute the expression.
define LED_ON led = 100
define LED_OFF led = 0
uint8_t led = 0;
LED_ON; dely(100); LED_OFF;
The extension tries to get the value of the define. But the gdb executes the expression of the define and sets the this value to the memory of the halted microcontroller.
197-var-create --thread 4 --frame 0 hover_41cfaa7f209f0751459adf07e2163093f0baf6914b74b82363bf47de05986d92 @ "LED_ON" -> =memory-changed,thread-group="i1",addr="0x20010f92",len="0x1"
So i can switch on or off the LED only with hovering over the define. It is the same with a normal variable.
Debugger Configurations
Debugger Logs
Other Extensions
marus25.cortex-debug
Additional Information
No response