platformio.ini:
[env:uno]
platform = atmelavr
board = uno
framework = arduino
debug_tool = avr-stub
debug_port = COM3
build_unflags = -Os
build_flags = -O0 -g3 -ggdb
; GDB stub implementation
lib_deps =
jdolinay/avr-debugger @ ~1.1
platformio.ini:
[env:uno]
platform = atmelavr
board = uno
framework = arduino
debug_tool = avr-stub
debug_port = COM3
build_unflags = -Os
build_flags = -O0 -g3 -ggdb
; GDB stub implementation
lib_deps =
jdolinay/avr-debugger @ ~1.1
Remove these lines and set build_type = debug
in the platformio.ini
. Then retry.
If that does still not work, go into the “debug console” and do a
p lastAnalogRead
does it give information on the variable?
The removing of the flags and unflags and replacing them with build_type didn’t work.
Here is the output of lastAnalogRead
$1 = 0
{"token":27,"outOfBandRecord":[],"resultRecords":{"resultClass":"done","results":[]}}
Reproducable, and reported to Global variables are not shown for AVR + avr-stub · Issue #2334 · platformio/platformio-vscode-ide · GitHub and will be discussed there (CC @ivankravets).
Thank you! You have hearth in the issue from me