An error occurred when uploading sketch to seeeduino lorawan board via arduino ide

Hi.



Currently, I encountered the issue regarding uploading sketches to seeeduino lorawan via arduino ide. The error message i get :

‘Arduino: 1.8.7 (Windows 10), Board: “Seeeduino LoRaWAN”



C:\Program Files (x86)\Arduino\arduino-builder -dump-prefs -logger=machine -hardware C:\Program Files (x86)\Arduino\hardware -hardware C:\Users\KtOng\AppData\Local\Arduino15\packages -tools C:\Program Files (x86)\Arduino\tools-builder -tools C:\Program Files (x86)\Arduino\hardware\tools\avr -tools C:\Users\KtOng\AppData\Local\Arduino15\packages -built-in-libraries C:\Program Files (x86)\Arduino\libraries -libraries C:\Users\KtOng\Documents\Arduino\libraries -fqbn=Seeeduino:samd:rolawan -vid-pid=0X2886_0X800C -ide-version=10807 -build-path C:\Users\KtOng\AppData\Local\Temp\arduino_build_716992 -warnings=none -build-cache C:\Users\KtOng\AppData\Local\Temp\arduino_cache_640229 -prefs=build.warn_data_percentage=75 -prefs=runtime.tools.openocd.path=C:\Users\KtOng\AppData\Local\Arduino15\packages\Seeeduino\tools\openocd\0.9.0-arduino -prefs=runtime.tools.openocd-0.9.0-arduino.path=C:\Users\KtOng\AppData\Local\Arduino15\packages\Seeeduino\tools\openocd\0.9.0-arduino -prefs=runtime.tools.arm-none-eabi-gcc.path=C:\Users\KtOng\AppData\Local\Arduino15\packages\Seeeduino\tools\arm-none-eabi-gcc\4.8.3-2014q1 -prefs=runtime.tools.arm-none-eabi-gcc-4.8.3-2014q1.path=C:\Users\KtOng\AppData\Local\Arduino15\packages\Seeeduino\tools\arm-none-eabi-gcc\4.8.3-2014q1 -prefs=runtime.tools.CMSIS.path=C:\Users\KtOng\AppData\Local\Arduino15\packages\Seeeduino\tools\CMSIS\4.0.0-atmel -prefs=runtime.tools.CMSIS-4.0.0-atmel.path=C:\Users\KtOng\AppData\Local\Arduino15\packages\Seeeduino\tools\CMSIS\4.0.0-atmel -prefs=runtime.tools.bossac.path=C:\Users\KtOng\AppData\Local\Arduino15\packages\Seeeduino\tools\bossac\1.6.1-arduino -prefs=runtime.tools.bossac-1.6.1-arduino.path=C:\Users\KtOng\AppData\Local\Arduino15\packages\Seeeduino\tools\bossac\1.6.1-arduino -verbose C:\Program Files (x86)\Arduino\examples\01.Basics\Blink\Blink.ino

C:\Program Files (x86)\Arduino\arduino-builder -compile -logger=machine -hardware C:\Program Files (x86)\Arduino\hardware -hardware C:\Users\KtOng\AppData\Local\Arduino15\packages -tools C:\Program Files (x86)\Arduino\tools-builder -tools C:\Program Files (x86)\Arduino\hardware\tools\avr -tools C:\Users\KtOng\AppData\Local\Arduino15\packages -built-in-libraries C:\Program Files (x86)\Arduino\libraries -libraries C:\Users\KtOng\Documents\Arduino\libraries -fqbn=Seeeduino:samd:rolawan -vid-pid=0X2886_0X800C -ide-version=10807 -build-path C:\Users\KtOng\AppData\Local\Temp\arduino_build_716992 -warnings=none -build-cache C:\Users\KtOng\AppData\Local\Temp\arduino_cache_640229 -prefs=build.warn_data_percentage=75 -prefs=runtime.tools.openocd.path=C:\Users\KtOng\AppData\Local\Arduino15\packages\Seeeduino\tools\openocd\0.9.0-arduino -prefs=runtime.tools.openocd-0.9.0-arduino.path=C:\Users\KtOng\AppData\Local\Arduino15\packages\Seeeduino\tools\openocd\0.9.0-arduino -prefs=runtime.tools.arm-none-eabi-gcc.path=C:\Users\KtOng\AppData\Local\Arduino15\packages\Seeeduino\tools\arm-none-eabi-gcc\4.8.3-2014q1 -prefs=runtime.tools.arm-none-eabi-gcc-4.8.3-2014q1.path=C:\Users\KtOng\AppData\Local\Arduino15\packages\Seeeduino\tools\arm-none-eabi-gcc\4.8.3-2014q1 -prefs=runtime.tools.CMSIS.path=C:\Users\KtOng\AppData\Local\Arduino15\packages\Seeeduino\tools\CMSIS\4.0.0-atmel -prefs=runtime.tools.CMSIS-4.0.0-atmel.path=C:\Users\KtOng\AppData\Local\Arduino15\packages\Seeeduino\tools\CMSIS\4.0.0-atmel -prefs=runtime.tools.bossac.path=C:\Users\KtOng\AppData\Local\Arduino15\packages\Seeeduino\tools\bossac\1.6.1-arduino -prefs=runtime.tools.bossac-1.6.1-arduino.path=C:\Users\KtOng\AppData\Local\Arduino15\packages\Seeeduino\tools\bossac\1.6.1-arduino -verbose C:\Program Files (x86)\Arduino\examples\01.Basics\Blink\Blink.ino

Using board ‘rolawan’ from platform in folder: C:\Users\KtOng\AppData\Local\Arduino15\packages\Seeeduino\hardware\samd\1.3.0

Using core ‘arduino’ from platform in folder: C:\Users\KtOng\AppData\Local\Arduino15\packages\Seeeduino\hardware\samd\1.3.0

WARNING: Category ‘’ in library FlashStorage is not valid. Setting to ‘Uncategorized’

Detecting libraries used…

“C:\Users\KtOng\AppData\Local\Arduino15\packages\Seeeduino\tools\arm-none-eabi-gcc\4.8.3-2014q1/bin/arm-none-eabi-g++” -mcpu=cortex-m0plus -mthumb -c -g -Os -w -std=gnu++11 -ffunction-sections -fdata-sections -fno-threadsafe-statics -nostdlib --param max-inline-insns-single=500 -fno-rtti -fno-exceptions -w -x c++ -E -CC -DF_CPU=48000000L -DARDUINO=10807 -DARDUINO_SAMD_ZERO -DARDUINO_ARCH_SAMD -D__SAMD21G18A__ -DUSB_VID=0x2886 -DUSB_PID=0x800C -DUSBCON “-DUSB_MANUFACTURER=“Seeed Studio”” “-DUSB_PRODUCT=“Seeeduino LoRaWAN”” “-IC:\Users\KtOng\AppData\Local\Arduino15\packages\Seeeduino\tools\CMSIS\4.0.0-atmel/CMSIS/Include/” “-IC:\Users\KtOng\AppData\Local\Arduino15\packages\Seeeduino\tools\CMSIS\4.0.0-atmel/Device/ATMEL/” “-IC:\Users\KtOng\AppData\Local\Arduino15\packages\Seeeduino\hardware\samd\1.3.0\cores\arduino” “-IC:\Users\KtOng\AppData\Local\Arduino15\packages\Seeeduino\hardware\samd\1.3.0\variants\arduino_zero” “C:\Users\KtOng\AppData\Local\Temp\arduino_build_716992\sketch\Blink.ino.cpp” -o nul

Generating function prototypes…

“C:\Users\KtOng\AppData\Local\Arduino15\packages\Seeeduino\tools\arm-none-eabi-gcc\4.8.3-2014q1/bin/arm-none-eabi-g++” -mcpu=cortex-m0plus -mthumb -c -g -Os -w -std=gnu++11 -ffunction-sections -fdata-sections -fno-threadsafe-statics -nostdlib --param max-inline-insns-single=500 -fno-rtti -fno-exceptions -w -x c++ -E -CC -DF_CPU=48000000L -DARDUINO=10807 -DARDUINO_SAMD_ZERO -DARDUINO_ARCH_SAMD -D__SAMD21G18A__ -DUSB_VID=0x2886 -DUSB_PID=0x800C -DUSBCON “-DUSB_MANUFACTURER=“Seeed Studio”” “-DUSB_PRODUCT=“Seeeduino LoRaWAN”” “-IC:\Users\KtOng\AppData\Local\Arduino15\packages\Seeeduino\tools\CMSIS\4.0.0-atmel/CMSIS/Include/” “-IC:\Users\KtOng\AppData\Local\Arduino15\packages\Seeeduino\tools\CMSIS\4.0.0-atmel/Device/ATMEL/” “-IC:\Users\KtOng\AppData\Local\Arduino15\packages\Seeeduino\hardware\samd\1.3.0\cores\arduino” “-IC:\Users\KtOng\AppData\Local\Arduino15\packages\Seeeduino\hardware\samd\1.3.0\variants\arduino_zero” “C:\Users\KtOng\AppData\Local\Temp\arduino_build_716992\sketch\Blink.ino.cpp” -o “C:\Users\KtOng\AppData\Local\Temp\arduino_build_716992\preproc\ctags_target_for_gcc_minus_e.cpp”

“C:\Program Files (x86)\Arduino\tools-builder\ctags\5.8-arduino11/ctags” -u --language-force=c++ -f - --c+±kinds=svpf --fields=KSTtzns --line-directives “C:\Users\KtOng\AppData\Local\Temp\arduino_build_716992\preproc\ctags_target_for_gcc_minus_e.cpp”

Compiling sketch…

“C:\Users\KtOng\AppData\Local\Arduino15\packages\Seeeduino\tools\arm-none-eabi-gcc\4.8.3-2014q1/bin/arm-none-eabi-g++” -mcpu=cortex-m0plus -mthumb -c -g -Os -w -std=gnu++11 -ffunction-sections -fdata-sections -fno-threadsafe-statics -nostdlib --param max-inline-insns-single=500 -fno-rtti -fno-exceptions -MMD -DF_CPU=48000000L -DARDUINO=10807 -DARDUINO_SAMD_ZERO -DARDUINO_ARCH_SAMD -D__SAMD21G18A__ -DUSB_VID=0x2886 -DUSB_PID=0x800C -DUSBCON “-DUSB_MANUFACTURER=“Seeed Studio”” “-DUSB_PRODUCT=“Seeeduino LoRaWAN”” “-IC:\Users\KtOng\AppData\Local\Arduino15\packages\Seeeduino\tools\CMSIS\4.0.0-atmel/CMSIS/Include/” “-IC:\Users\KtOng\AppData\Local\Arduino15\packages\Seeeduino\tools\CMSIS\4.0.0-atmel/Device/ATMEL/” “-IC:\Users\KtOng\AppData\Local\Arduino15\packages\Seeeduino\hardware\samd\1.3.0\cores\arduino” “-IC:\Users\KtOng\AppData\Local\Arduino15\packages\Seeeduino\hardware\samd\1.3.0\variants\arduino_zero” “C:\Users\KtOng\AppData\Local\Temp\arduino_build_716992\sketch\Blink.ino.cpp” -o “C:\Users\KtOng\AppData\Local\Temp\arduino_build_716992\sketch\Blink.ino.cpp.o”

Compiling libraries…

Compiling core…

Using previously compiled file: C:\Users\KtOng\AppData\Local\Temp\arduino_build_716992\core\variant.cpp.o

Using precompiled core: C:\Users\KtOng\AppData\Local\Temp\arduino_cache_640229\core\core_Seeeduino_samd_rolawan_0c9487c13c974766c7d68f6c4786c01f.a

Linking everything together…

“C:\Users\KtOng\AppData\Local\Arduino15\packages\Seeeduino\tools\arm-none-eabi-gcc\4.8.3-2014q1/bin/arm-none-eabi-gcc” “-LC:\Users\KtOng\AppData\Local\Temp\arduino_build_716992” -Os -Wl,–gc-sections -save-temps “-TC:\Users\KtOng\AppData\Local\Arduino15\packages\Seeeduino\hardware\samd\1.3.0\variants\arduino_zero/linker_scripts/gcc/flash_with_bootloader.ld” “-Wl,-Map,C:\Users\KtOng\AppData\Local\Temp\arduino_build_716992/Blink.ino.map” --specs=nano.specs --specs=nosys.specs -mcpu=cortex-m0plus -mthumb -Wl,–cref -Wl,–check-sections -Wl,–gc-sections -Wl,–unresolved-symbols=report-all -Wl,–warn-common -Wl,–warn-section-align -o “C:\Users\KtOng\AppData\Local\Temp\arduino_build_716992/Blink.ino.elf” “C:\Users\KtOng\AppData\Local\Temp\arduino_build_716992\sketch\Blink.ino.cpp.o” “C:\Users\KtOng\AppData\Local\Temp\arduino_build_716992\core\variant.cpp.o” -Wl,–start-group -lm “C:\Users\KtOng\AppData\Local\Temp\arduino_build_716992/…\arduino_cache_640229\core\core_Seeeduino_samd_rolawan_0c9487c13c974766c7d68f6c4786c01f.a” -Wl,–end-group

“C:\Users\KtOng\AppData\Local\Arduino15\packages\Seeeduino\tools\arm-none-eabi-gcc\4.8.3-2014q1/bin/arm-none-eabi-objcopy” -O binary “C:\Users\KtOng\AppData\Local\Temp\arduino_build_716992/Blink.ino.elf” “C:\Users\KtOng\AppData\Local\Temp\arduino_build_716992/Blink.ino.bin”

“C:\Users\KtOng\AppData\Local\Arduino15\packages\Seeeduino\tools\arm-none-eabi-gcc\4.8.3-2014q1/bin/arm-none-eabi-size” -A “C:\Users\KtOng\AppData\Local\Temp\arduino_build_716992/Blink.ino.elf”

Sketch uses 8460 bytes (3%) of program storage space. Maximum is 262144 bytes.

Forcing reset using 1200bps open/close on port COM4

PORTS {COM3, COM4, } / {COM3, COM4, } => {}

PORTS {COM3, COM4, } / {COM3, COM4, } => {}

PORTS {COM3, COM4, } / {COM3, COM4, } => {}

PORTS {COM3, COM4, } / {COM3, COM4, } => {}

PORTS {COM3, COM4, } / {COM3, COM4, } => {}

PORTS {COM3, COM4, } / {COM3, COM4, } => {}

PORTS {COM3, COM4, } / {COM3, COM4, } => {}

PORTS {COM3, COM4, } / {COM3, COM4, } => {}

PORTS {COM3, COM4, } / {COM3, COM4, } => {}

PORTS {COM3, COM4, } / {COM3, COM4, } => {}

PORTS {COM3, COM4, } / {COM3, COM4, } => {}

PORTS {COM3, COM4, } / {COM3, COM4, } => {}

PORTS {COM3, COM4, } / {COM3, COM4, } => {}

PORTS {COM3, COM4, } / {COM3, COM4, } => {}

PORTS {COM3, COM4, } / {COM3, COM4, } => {}

PORTS {COM3, COM4, } / {COM3, COM4, } => {}

PORTS {COM3, COM4, } / {COM3, COM4, } => {}

PORTS {COM3, COM4, } / {COM3, COM4, } => {}

PORTS {COM3, COM4, } / {COM3, COM4, } => {}

PORTS {COM3, COM4, } / {COM3, COM4, } => {}

Uploading using selected port: COM4

C:\Users\KtOng\AppData\Local\Arduino15\packages\Seeeduino\tools\bossac\1.6.1-arduino/bossac.exe -i -d --port=COM4 -U true -i -e -w -v C:\Users\KtOng\AppData\Local\Temp\arduino_build_716992/Blink.ino.bin -R

No device found on COM4

An error occurred while uploading the sketch’



Before I encountered this issue, the process of uploading is smooth with some simple examples from this tutorial (http://wiki.seeedstudio.com/Seeeduino_LoRAWAN/). I try to upload again this sketch:

‘void setup()

{

Serial1.begin(9600);

SerialUSB.begin(115200);

}



void loop()

{

while(Serial1.available())

{

SerialUSB.write(Serial1.read());

}

while(SerialUSB.available())

{

Serial1.write(SerialUSB.read());

}

}’

that saved in a new sketch (as previously saved same sketch in another sketch). When i try to upload the new sketch, the process take longer time compared to previous uploads and the above error message shown in the console. I tried to reinstall- install arduino ide, plugged-unplugged the usb connect to seeduino lorawan board even restart my laptop (OS: Window 10, 64bits) .



Hope can have some idea to solve the problem.

Hi there,



Please double press the reset button and see if it solves the issue, thanks.

Thanks for your reply, it actually work when I press the reset button to reset the board. :slight_smile::):slight_smile:

Hi,



This error is a very basic arduino error. Whenever this error occurs you just need to disconnect your usb cable and connect it again. it will solve the issue. Giving you tested solution.