Verbose output with double backslash

i have problem with Arduino IDE verbose output that has double backslash.

FQBN: arduino:avr:uno
Using board 'uno' from platform in folder: C:\Users\ICAL\AppData\Local\Arduino15\packages\arduino\hardware\avr\1.8.6
Using core 'arduino' from platform in folder: C:\Users\ICAL\AppData\Local\Arduino15\packages\arduino\hardware\avr\1.8.6

Detecting libraries used...
C:\Users\ICAL\AppData\Local\Arduino15\packages\arduino\tools\avr-gcc\7.3.0-atmel3.6.1-arduino7/bin/avr-g++ -c -g -Os -w -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -Wno-error=narrowing -flto -w -x c++ -E -CC -mmcu=atmega328p -DF_CPU=16000000L -DARDUINO=10607 -DARDUINO_AVR_UNO -DARDUINO_ARCH_AVR -IC:\Users\ICAL\AppData\Local\Arduino15\packages\arduino\hardware\avr\1.8.6\cores\arduino -IC:\Users\ICAL\AppData\Local\Arduino15\packages\arduino\hardware\avr\1.8.6\variants\standard C:\Users\ICAL\AppData\Local\Temp\arduino\sketches\D91A8854AE2FF13D99E2E683C60E370B\sketch\readEncoderPin.ino.cpp -o nul
Generating function prototypes...
C:\Users\ICAL\AppData\Local\Arduino15\packages\arduino\tools\avr-gcc\7.3.0-atmel3.6.1-arduino7/bin/avr-g++ -c -g -Os -w -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -Wno-error=narrowing -flto -w -x c++ -E -CC -mmcu=atmega328p -DF_CPU=16000000L -DARDUINO=10607 -DARDUINO_AVR_UNO -DARDUINO_ARCH_AVR -IC:\Users\ICAL\AppData\Local\Arduino15\packages\arduino\hardware\avr\1.8.6\cores\arduino -IC:\Users\ICAL\AppData\Local\Arduino15\packages\arduino\hardware\avr\1.8.6\variants\standard C:\Users\ICAL\AppData\Local\Temp\arduino\sketches\D91A8854AE2FF13D99E2E683C60E370B\sketch\readEncoderPin.ino.cpp -o C:\Users\ICAL\AppData\Local\Temp\3072576406\sketch_merged.cpp
C:\Users\ICAL\AppData\Local\Arduino15\packages\builtin\tools\ctags\5.8-arduino11/ctags -u --language-force=c++ -f - --c++-kinds=svpf --fields=KSTtzns --line-directives C:\Users\ICAL\AppData\Local\Temp\3072576406\sketch_merged.cpp
Compiling sketch...
"C:\\Users\\ICAL\\AppData\\Local\\Arduino15\\packages\\arduino\\tools\\avr-gcc\\7.3.0-atmel3.6.1-arduino7/bin/avr-g++" -c -g -Os -Wall -Wextra -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -Wno-error=narrowing -MMD -flto -mmcu=atmega328p -DF_CPU=16000000L -DARDUINO=10607 -DARDUINO_AVR_UNO -DARDUINO_ARCH_AVR "-IC:\\Users\\ICAL\\AppData\\Local\\Arduino15\\packages\\arduino\\hardware\\avr\\1.8.6\\cores\\arduino" "-IC:\\Users\\ICAL\\AppData\\Local\\Arduino15\\packages\\arduino\\hardware\\avr\\1.8.6\\variants\\standard" "C:\\Users\\ICAL\\AppData\\Local\\Temp\\arduino\\sketches\\D91A8854AE2FF13D99E2E683C60E370B\\sketch\\readEncoderPin.ino.cpp" -o "C:\\Users\\ICAL\\AppData\\Local\\Temp\\arduino\\sketches\\D91A8854AE2FF13D99E2E683C60E370B\\sketch\\readEncoderPin.ino.cpp.o"
Compiling libraries...
Compiling core...
Using precompiled core: C:\Users\ICAL\AppData\Local\Temp\arduino\cores\arduino_avr_uno_d49537fa2ab0d4dba0372b6b946ff11a\core.a
Linking everything together...
"C:\\Users\\ICAL\\AppData\\Local\\Arduino15\\packages\\arduino\\tools\\avr-gcc\\7.3.0-atmel3.6.1-arduino7/bin/avr-gcc" -Wall -Wextra -Os -g -flto -fuse-linker-plugin -Wl,--gc-sections -mmcu=atmega328p -o "C:\\Users\\ICAL\\AppData\\Local\\Temp\\arduino\\sketches\\D91A8854AE2FF13D99E2E683C60E370B/readEncoderPin.ino.elf" "C:\\Users\\ICAL\\AppData\\Local\\Temp\\arduino\\sketches\\D91A8854AE2FF13D99E2E683C60E370B\\sketch\\readEncoderPin.ino.cpp.o" "C:\\Users\\ICAL\\AppData\\Local\\Temp\\arduino\\sketches\\D91A8854AE2FF13D99E2E683C60E370B/..\\..\\cores\\arduino_avr_uno_d49537fa2ab0d4dba0372b6b946ff11a\\core.a" "-LC:\\Users\\ICAL\\AppData\\Local\\Temp\\arduino\\sketches\\D91A8854AE2FF13D99E2E683C60E370B" -lm
"C:\\Users\\ICAL\\AppData\\Local\\Arduino15\\packages\\arduino\\tools\\avr-gcc\\7.3.0-atmel3.6.1-arduino7/bin/avr-objcopy" -O ihex -j .eeprom --set-section-flags=.eeprom=alloc,load --no-change-warnings --change-section-lma .eeprom=0 "C:\\Users\\ICAL\\AppData\\Local\\Temp\\arduino\\sketches\\D91A8854AE2FF13D99E2E683C60E370B/readEncoderPin.ino.elf" "C:\\Users\\ICAL\\AppData\\Local\\Temp\\arduino\\sketches\\D91A8854AE2FF13D99E2E683C60E370B/readEncoderPin.ino.eep"
"C:\\Users\\ICAL\\AppData\\Local\\Arduino15\\packages\\arduino\\tools\\avr-gcc\\7.3.0-atmel3.6.1-arduino7/bin/avr-objcopy" -O ihex -R .eeprom "C:\\Users\\ICAL\\AppData\\Local\\Temp\\arduino\\sketches\\D91A8854AE2FF13D99E2E683C60E370B/readEncoderPin.ino.elf" "C:\\Users\\ICAL\\AppData\\Local\\Temp\\arduino\\sketches\\D91A8854AE2FF13D99E2E683C60E370B/readEncoderPin.ino.hex"

"C:\\Users\\ICAL\\AppData\\Local\\Arduino15\\packages\\arduino\\tools\\avr-gcc\\7.3.0-atmel3.6.1-arduino7/bin/avr-size" -A "C:\\Users\\ICAL\\AppData\\Local\\Temp\\arduino\\sketches\\D91A8854AE2FF13D99E2E683C60E370B/readEncoderPin.ino.elf"
Sketch uses 2322 bytes (7%) of program storage space. Maximum is 32256 bytes.
Global variables use 200 bytes (9%) of dynamic memory, leaving 1848 bytes for local variables. Maximum is 2048 bytes.

it's kinda annoying everytime when i wanna go to the ".hex" directory, i have to edit the copied .hex address. can someone help me how to fix this. sorry about my english

Please do not post pictures of text or code.

For posting instructions, read and follow the advice in the "How to get the best out of this forum" post.

1 Like

What are you then doing with the double-backslashed/escaped-backslash pathnames that gives you an error? cmd.exe parses them just fine.

If you need the hex file, you can use sketch/export compiled binary in the IDE. This will place the hex file in a directory (called build) in your sketch directory.

@DaveX, have you tried to put it in the address bar of file explorer?

1 Like

I'm normally on Mac & Linux, which both use sane forward slashes in path names.

Does Windows have some command like 'echo' that would parse the escape characters?

 % echo 'C:\\Users\\ICAL\\AppData\\Local\\Temp\\arduino\\sketches\\D91A8854AE2FF13D99E2E683C60E370B/readEncoderPin.ino.h'
C:\Users\ICAL\AppData\Local\Temp\arduino\sketches\D91A8854AE2FF13D99E2E683C60E370B/readEncoderPin.ino.h

If you're using the Command Prompt (cmd), then the double backslashes are treated as a single one, except for the very beginning, in which case they are treated as a UNC path. So

C:\> cd C:\\Users\\ICAL
C:\> cd "C:\\Users\\ICAL"
C:\> cd \Users\\ICAL

all work, but

C:\> cd \\Users\\ICAL

does not. However, if you're pasting into the address bar of Windows Explorer, then yeah it's a PITA. (I guess you could use cmd to go there, and that will clean up the path when it shows the current directory.)

Since backslash is used for paths (oops) it is not treated like an escape character. echo "foo\\bar" (with or without the quotes) prints foo\\bar

1 Like

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.