Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

software installation problem: 'D6' was not declared in this scope" #228

Open
droX78 opened this issue May 7, 2021 · 15 comments
Open

software installation problem: 'D6' was not declared in this scope" #228

droX78 opened this issue May 7, 2021 · 15 comments

Comments

@droX78
Copy link

droX78 commented May 7, 2021

Hello , I a am trying to set up the software for the gbs control but when I try to upload the soft ware in the board (ctrl+U) i have got this message "D6 wa&s not de"clared inthis scope".
Can you help me , i am a real noob for Arduino things...

@gingerbeardman
Copy link
Contributor

gingerbeardman commented May 7, 2021

Please check the steps carefully and try again.

If it helps, type out what you are doing in a bullet list here and see where you get stuck.

Then we can help.

@droX78
Copy link
Author

droX78 commented May 7, 2021

I have done it 3 times... Which step can be involved in " D6 is not declared in this scope" error msg?

@gingerbeardman
Copy link
Contributor

gingerbeardman commented May 7, 2021

Please make sure you have selected the correct board in Arduino software: Tools > Board menu

https://shmups.system11.org/viewtopic.php?f=6&t=52172&start=3180

@droX78
Copy link
Author

droX78 commented May 7, 2021

i used "generic 8266 module", an d when i use LOLIN(WEMOS) D1 R2 & mini", i have another error message at the same step:
exit status 1
Erreur de compilation pour la carte LOLIN(WEMOS) D1 R2 & mini

@gingerbeardman
Copy link
Contributor

gingerbeardman commented May 7, 2021

If you’re using the Arduino IDE you should set your Preferences to verbose output for compile and upload. A description of the exact error will be present.

Paste it here, or add a screenshot!

@droX78
Copy link
Author

droX78 commented Jun 6, 2021

does it help? I think just the last part in french was the las t test , or?

@ramapcsx2
Copy link
Owner

Hey,
downgrade the ESP8266 Arduino core to a version < 3.

@droX78
Copy link
Author

droX78 commented Jun 6, 2021

ok ill try, thanks!
Not sure how to do it... any advise?

@droX78
Copy link
Author

droX78 commented Jun 6, 2021

I think i used the 2.7.4 version, so it should be ok, am i correct??

@Nuck-TH
Copy link

Nuck-TH commented Jun 8, 2021

Use github gist or pastebin, for freakings sake, next time.

@ramapcsx2
Copy link
Owner

If you aren't sure which board you have, select "LOLIN(WEMOS) D1 R2 & mini".

@droX78
Copy link
Author

droX78 commented Jun 9, 2021

Sorry i knwo it is probably a toolong error message and it is bad for the forum, but I don t know what is useful....
And <I tried wit "LOLIN(WEMOS) D1 R2 & mini" it doesn work too...

@droX78
Copy link
Author

droX78 commented Jun 9, 2021

Arduino : 1.8.13 (Windows 8), Carte : "LOLIN(WEMOS) D1 R2 & mini, 80 MHz, Flash, Legacy (new can return nullptr), All SSL ciphers (most compatible), 4MB (FS:2MB OTA:~1019KB), v2 Lower Memory, Disabled, None, Only Sketch, 921600"

E:\Games\arduino\arduino-builder -dump-prefs -logger=machine -hardware E:\Games\arduino\hardware -hardware E:\Users\Guillaume\AppData\Local\Arduino15\packages -tools E:\Games\arduino\tools-builder -tools E:\Games\arduino\hardware\tools\avr -tools E:\Users\Guillaume\AppData\Local\Arduino15\packages -built-in-libraries E:\Games\arduino\libraries -libraries E:\Users\Guillaume\Documents\Arduino\libraries -fqbn=esp8266:esp8266:d1_mini:xtal=80,vt=flash,exception=legacy,ssl=all,eesz=4M2M,ip=lm2f,dbg=Disabled,lvl=None____,wipe=none,baud=921600 -vid-pid=0000_0000 -ide-version=10813 -build-path E:\Users\GUILLA1\AppData\Local\Temp\arduino_build_656773 -warnings=none -build-cache E:\Users\GUILLA1\AppData\Local\Temp\arduino_cache_810326 -prefs=build.warn_data_percentage=75 -prefs=runtime.tools.mklittlefs.path=E:\Users\Guillaume\AppData\Local\Arduino15\packages\esp8266\tools\mklittlefs\2.5.0-4-fe5bb56 -prefs=runtime.tools.mklittlefs-2.5.0-4-fe5bb56.path=E:\Users\Guillaume\AppData\Local\Arduino15\packages\esp8266\tools\mklittlefs\2.5.0-4-fe5bb56 -prefs=runtime.tools.xtensa-lx106-elf-gcc.path=E:\Users\Guillaume\AppData\Local\Arduino15\packages\esp8266\tools\xtensa-lx106-elf-gcc\2.5.0-4-b40a506 -prefs=runtime.tools.xtensa-lx106-elf-gcc-2.5.0-4-b40a506.path=E:\Users\Guillaume\AppData\Local\Arduino15\packages\esp8266\tools\xtensa-lx106-elf-gcc\2.5.0-4-b40a506 -prefs=runtime.tools.python3.path=E:\Users\Guillaume\AppData\Local\Arduino15\packages\esp8266\tools\python3\3.7.2-post1 -prefs=runtime.tools.python3-3.7.2-post1.path=E:\Users\Guillaume\AppData\Local\Arduino15\packages\esp8266\tools\python3\3.7.2-post1 -prefs=runtime.tools.mkspiffs.path=E:\Users\Guillaume\AppData\Local\Arduino15\packages\esp8266\tools\mkspiffs\2.5.0-4-b40a506 -prefs=runtime.tools.mkspiffs-2.5.0-4-b40a506.path=E:\Users\Guillaume\AppData\Local\Arduino15\packages\esp8266\tools\mkspiffs\2.5.0-4-b40a506 -verbose E:\Users\GUILLA~1\AppData\Local\Temp\arduino_modified_sketch_687641\gbs-control.ino

E:\Games\arduino\arduino-builder -compile -logger=machine -hardware E:\Games\arduino\hardware -hardware E:\Users\Guillaume\AppData\Local\Arduino15\packages -tools E:\Games\arduino\tools-builder -tools E:\Games\arduino\hardware\tools\avr -tools E:\Users\Guillaume\AppData\Local\Arduino15\packages -built-in-libraries E:\Games\arduino\libraries -libraries E:\Users\Guillaume\Documents\Arduino\libraries -fqbn=esp8266:esp8266:d1_mini:xtal=80,vt=flash,exception=legacy,ssl=all,eesz=4M2M,ip=lm2f,dbg=Disabled,lvl=None____,wipe=none,baud=921600 -vid-pid=0000_0000 -ide-version=10813 -build-path E:\Users\GUILLA1\AppData\Local\Temp\arduino_build_656773 -warnings=none -build-cache E:\Users\GUILLA1\AppData\Local\Temp\arduino_cache_810326 -prefs=build.warn_data_percentage=75 -prefs=runtime.tools.mklittlefs.path=E:\Users\Guillaume\AppData\Local\Arduino15\packages\esp8266\tools\mklittlefs\2.5.0-4-fe5bb56 -prefs=runtime.tools.mklittlefs-2.5.0-4-fe5bb56.path=E:\Users\Guillaume\AppData\Local\Arduino15\packages\esp8266\tools\mklittlefs\2.5.0-4-fe5bb56 -prefs=runtime.tools.xtensa-lx106-elf-gcc.path=E:\Users\Guillaume\AppData\Local\Arduino15\packages\esp8266\tools\xtensa-lx106-elf-gcc\2.5.0-4-b40a506 -prefs=runtime.tools.xtensa-lx106-elf-gcc-2.5.0-4-b40a506.path=E:\Users\Guillaume\AppData\Local\Arduino15\packages\esp8266\tools\xtensa-lx106-elf-gcc\2.5.0-4-b40a506 -prefs=runtime.tools.python3.path=E:\Users\Guillaume\AppData\Local\Arduino15\packages\esp8266\tools\python3\3.7.2-post1 -prefs=runtime.tools.python3-3.7.2-post1.path=E:\Users\Guillaume\AppData\Local\Arduino15\packages\esp8266\tools\python3\3.7.2-post1 -prefs=runtime.tools.mkspiffs.path=E:\Users\Guillaume\AppData\Local\Arduino15\packages\esp8266\tools\mkspiffs\2.5.0-4-b40a506 -prefs=runtime.tools.mkspiffs-2.5.0-4-b40a506.path=E:\Users\Guillaume\AppData\Local\Arduino15\packages\esp8266\tools\mkspiffs\2.5.0-4-b40a506 -verbose E:\Users\GUILLA~1\AppData\Local\Temp\arduino_modified_sketch_687641\gbs-control.ino

Using board 'd1_mini' from platform in folder: E:\Users\Guillaume\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.7.3

Using core 'esp8266' from platform in folder: E:\Users\Guillaume\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.7.3

Detecting libraries used...

"E:\Users\Guillaume\AppData\Local\Arduino15\packages\esp8266\tools\xtensa-lx106-elf-gcc\2.5.0-4-b40a506/bin/xtensa-lx106-elf-g++" -D__ets__ -DICACHE_FLASH -U__STRICT_ANSI__ "-IE:\Users\Guillaume\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.7.3/tools/sdk/include" "-IE:\Users\Guillaume\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.7.3/tools/sdk/lwip2/include" "-IE:\Users\Guillaume\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.7.3/tools/sdk/libc/xtensa-lx106-elf/include" "-IE:\Users\GUILLA1\AppData\Local\Temp\arduino_build_656773/core" -c -w -Os -g -mlongcalls -mtext-section-literals -fno-rtti -falign-functions=4 -std=gnu++11 -ffunction-sections -fdata-sections -fno-exceptions -w -x c++ -E -CC -DNONOSDK22x_190703=1 -DF_CPU=80000000L -DLWIP_OPEN_SRC -DTCP_MSS=536 -DLWIP_FEATURES=1 -DLWIP_IPV6=0 -DARDUINO=10813 -DARDUINO_ESP8266_WEMOS_D1MINI -DARDUINO_ARCH_ESP8266 "-DARDUINO_BOARD="ESP8266_WEMOS_D1MINI"" -DFLASHMODE_DIO -DESP8266 "-IE:\Users\Guillaume\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.7.3\cores\esp8266" "-IE:\Users\Guillaume\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.7.3\variants\d1_mini" "E:\Users\GUILLA1\AppData\Local\Temp\arduino_build_656773\sketch\gbs-control.ino.cpp" -o nul -DARDUINO_LIB_DISCOVERY_PHASE

Generating function prototypes...

"E:\Users\Guillaume\AppData\Local\Arduino15\packages\esp8266\tools\xtensa-lx106-elf-gcc\2.5.0-4-b40a506/bin/xtensa-lx106-elf-g++" -D__ets__ -DICACHE_FLASH -U__STRICT_ANSI__ "-IE:\Users\Guillaume\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.7.3/tools/sdk/include" "-IE:\Users\Guillaume\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.7.3/tools/sdk/lwip2/include" "-IE:\Users\Guillaume\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.7.3/tools/sdk/libc/xtensa-lx106-elf/include" "-IE:\Users\GUILLA1\AppData\Local\Temp\arduino_build_656773/core" -c -w -Os -g -mlongcalls -mtext-section-literals -fno-rtti -falign-functions=4 -std=gnu++11 -ffunction-sections -fdata-sections -fno-exceptions -w -x c++ -E -CC -DNONOSDK22x_190703=1 -DF_CPU=80000000L -DLWIP_OPEN_SRC -DTCP_MSS=536 -DLWIP_FEATURES=1 -DLWIP_IPV6=0 -DARDUINO=10813 -DARDUINO_ESP8266_WEMOS_D1MINI -DARDUINO_ARCH_ESP8266 "-DARDUINO_BOARD="ESP8266_WEMOS_D1MINI"" -DFLASHMODE_DIO -DESP8266 "-IE:\Users\Guillaume\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.7.3\cores\esp8266" "-IE:\Users\Guillaume\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.7.3\variants\d1_mini" "E:\Users\GUILLA1\AppData\Local\Temp\arduino_build_656773\sketch\gbs-control.ino.cpp" -o "E:\Users\GUILLA~1\AppData\Local\Temp\arduino_build_656773\preproc\ctags_target_for_gcc_minus_e.cpp" -DARDUINO_LIB_DISCOVERY_PHASE

"E:\Games\arduino\tools-builder\ctags\5.8-arduino11/ctags" -u --language-force=c++ -f - --c++-kinds=svpf --fields=KSTtzns --line-directives "E:\Users\GUILLA~1\AppData\Local\Temp\arduino_build_656773\preproc\ctags_target_for_gcc_minus_e.cpp"

Compilation du croquis...

"E:\Users\Guillaume\AppData\Local\Arduino15\packages\esp8266\tools\python3\3.7.2-post1/python3" "E:\Users\Guillaume\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.7.3/tools/signing.py" --mode header --publickey "E:\Users\GUILLA1\AppData\Local\Temp\arduino_modified_sketch_687641/public.key" --out "E:\Users\GUILLA1\AppData\Local\Temp\arduino_build_656773/core/Updater_Signing.h"

"E:\Users\Guillaume\AppData\Local\Arduino15\packages\esp8266\tools\xtensa-lx106-elf-gcc\2.5.0-4-b40a506/bin/xtensa-lx106-elf-g++" -D__ets__ -DICACHE_FLASH -U__STRICT_ANSI__ "-IE:\Users\Guillaume\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.7.3/tools/sdk/include" "-IE:\Users\Guillaume\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.7.3/tools/sdk/lwip2/include" "-IE:\Users\Guillaume\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.7.3/tools/sdk/libc/xtensa-lx106-elf/include" "-IE:\Users\GUILLA1\AppData\Local\Temp\arduino_build_656773/core" -c -w -Os -g -mlongcalls -mtext-section-literals -fno-rtti -falign-functions=4 -std=gnu++11 -MMD -ffunction-sections -fdata-sections -fno-exceptions -DNONOSDK22x_190703=1 -DF_CPU=80000000L -DLWIP_OPEN_SRC -DTCP_MSS=536 -DLWIP_FEATURES=1 -DLWIP_IPV6=0 -DARDUINO=10813 -DARDUINO_ESP8266_WEMOS_D1MINI -DARDUINO_ARCH_ESP8266 "-DARDUINO_BOARD="ESP8266_WEMOS_D1MINI"" -DFLASHMODE_DIO -DESP8266 "-IE:\Users\Guillaume\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.7.3\cores\esp8266" "-IE:\Users\Guillaume\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.7.3\variants\d1_mini" "E:\Users\GUILLA1\AppData\Local\Temp\arduino_build_656773\sketch\gbs-control.ino.cpp" -o "E:\Users\GUILLA~1\AppData\Local\Temp\arduino_build_656773\sketch\gbs-control.ino.cpp.o"

Compiling libraries...

Compiling core...

Using precompiled core: E:\Users\GUILLA~1\AppData\Local\Temp\arduino_cache_810326\core\core_afb80d15568dee19379481b29749d3e4.a

Linking everything together...

"E:\Users\Guillaume\AppData\Local\Arduino15\packages\esp8266\tools\xtensa-lx106-elf-gcc\2.5.0-4-b40a506/bin/xtensa-lx106-elf-gcc" -CC -E -P -DVTABLES_IN_FLASH "E:\Users\Guillaume\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.7.3/tools/sdk/ld/eagle.app.v6.common.ld.h" -o "E:\Users\GUILLA~1\AppData\Local\Temp\arduino_build_656773/local.eagle.app.v6.common.ld"

"E:\Users\Guillaume\AppData\Local\Arduino15\packages\esp8266\tools\xtensa-lx106-elf-gcc\2.5.0-4-b40a506/bin/xtensa-lx106-elf-gcc" -fno-exceptions -Wl,-Map "-Wl,E:\Users\GUILLA1\AppData\Local\Temp\arduino_build_656773/gbs-control.ino.map" -g -w -Os -nostdlib -Wl,--no-check-sections -u app_entry -u _printf_float -u _scanf_float -Wl,-static "-LE:\Users\Guillaume\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.7.3/tools/sdk/lib" "-LE:\Users\Guillaume\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.7.3/tools/sdk/lib/NONOSDK22x_190703" "-LE:\Users\Guillaume\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.7.3/tools/sdk/ld" "-LE:\Users\Guillaume\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.7.3/tools/sdk/libc/xtensa-lx106-elf/lib" -Teagle.flash.4m2m.ld -Wl,--gc-sections -Wl,-wrap,system_restart_local -Wl,-wrap,spi_flash_read -o "E:\Users\GUILLA1\AppData\Local\Temp\arduino_build_656773/gbs-control.ino.elf" -Wl,--start-group "E:\Users\GUILLA1\AppData\Local\Temp\arduino_build_656773\sketch\gbs-control.ino.cpp.o" "E:\Users\GUILLA1\AppData\Local\Temp\arduino_cache_810326\core\core_afb80d15568dee19379481b29749d3e4.a" -lhal -lphy -lpp -lnet80211 -llwip2-536-feat -lwpa -lcrypto -lmain -lwps -lbearssl -laxtls -lespnow -lsmartconfig -lairkiss -lwpa2 -lstdc++ -lm -lc -lgcc -Wl,--end-group "-LE:\Users\GUILLA~1\AppData\Local\Temp\arduino_build_656773"

e:/users/guillaume/appdata/local/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/2.5.0-4-b40a506/bin/../lib/gcc/xtensa-lx106-elf/4.8.2/../../../../xtensa-lx106-elf/bin/ld.exe: E:\Users\GUILLA~1\AppData\Local\Temp\arduino_cache_810326\core\core_afb80d15568dee19379481b29749d3e4.a(core_esp8266_main.cpp.o): in function `__loop_end':

E:\Users\Guillaume\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.7.3\cores\esp8266/core_esp8266_main.cpp:185: undefined reference to `setup'

e:/users/guillaume/appdata/local/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/2.5.0-4-b40a506/bin/../lib/gcc/xtensa-lx106-elf/4.8.2/../../../../xtensa-lx106-elf/bin/ld.exe: E:\Users\Guillaume\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.7.3\cores\esp8266/core_esp8266_main.cpp:185: undefined reference to `loop'

e:/users/guillaume/appdata/local/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/2.5.0-4-b40a506/bin/../lib/gcc/xtensa-lx106-elf/4.8.2/../../../../xtensa-lx106-elf/bin/ld.exe: E:\Users\GUILLA~1\AppData\Local\Temp\arduino_cache_810326\core\core_afb80d15568dee19379481b29749d3e4.a(core_esp8266_main.cpp.o): in function `loop_wrapper()':

E:\Users\Guillaume\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.7.3\cores\esp8266/core_esp8266_main.cpp:191: undefined reference to `setup'

e:/users/guillaume/appdata/local/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/2.5.0-4-b40a506/bin/../lib/gcc/xtensa-lx106-elf/4.8.2/../../../../xtensa-lx106-elf/bin/ld.exe: E:\Users\Guillaume\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.7.3\cores\esp8266/core_esp8266_main.cpp:192: undefined reference to `loop'

collect2.exe: error: ld returned 1 exit status

exit status 1

Erreur de compilation pour la carte LOLIN(WEMOS) D1 R2 & mini

@droX78
Copy link
Author

droX78 commented Jun 9, 2021

I tried with LOLIN(WEMOS) D1 R2 & mini and a shorter version of the report...

@dhorlick
Copy link

I think D6 (along with D1 and D2) is supposed to be a C language definition that maps a digital pin number to a pin numeric identifier that the Arduino IDE recognizes. The enabling code for some ESP8266 boards provides this, but the code for others (Adafruit Feather HUZZAH ESP8266, for example) apparently does not.

You should be able to add the missing definitions to the top of the gbs-control.ino file. For example,

#define D6 12

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants