Can't upload sketch


#1

Hi there!

I may need help :slight_smile:

First of all I am a total noob to Arduino.

I received my Arduboy today, turned it on, worked like a charm!

I then followed the quick start guide and everything went well until the "upload a sketch exemple. I saw the Arduino program worked but nothing appened on my Arduboy, the screen went black and that is it.

So I tried to upload a game whith a good cable (from phone, transfered data with it before) and ARduboy is ON. I get this report:

Arduino : 1.6.9 (Windows 10), Carte : “Arduino Leonardo”

C:\Program Files (x86)\Arduino\arduino-builder -dump-prefs -logger=machine -hardware "C:\Program Files (x86)\Arduino\hardware" -tools "C:\Program Files (x86)\Arduino\tools-builder" -tools "C:\Program Files (x86)\Arduino\hardware\tools\avr" -built-in-libraries "C:\Program Files (x86)\Arduino\libraries" -libraries "C:\Users\PC Famille\Documents\Arduino\libraries" -fqbn=arduino:avr:leonardo -vid-pid=0X2341_0X8036 -ide-version=10609 -build-path "C:\Users\PCFAMI~1\AppData\Local\Temp\build879358309df4280d577acf52baf46a16.tmp" -warnings=none -prefs=build.warn_data_percentage=75 -verbose "C:\Users\PC Famille\Downloads\glove\glove\glove\glove.ino"
C:\Program Files (x86)\Arduino\arduino-builder -compile -logger=machine -hardware "C:\Program Files (x86)\Arduino\hardware" -tools "C:\Program Files (x86)\Arduino\tools-builder" -tools "C:\Program Files (x86)\Arduino\hardware\tools\avr" -built-in-libraries "C:\Program Files (x86)\Arduino\libraries" -libraries "C:\Users\PC Famille\Documents\Arduino\libraries" -fqbn=arduino:avr:leonardo -vid-pid=0X2341_0X8036 -ide-version=10609 -build-path "C:\Users\PCFAMI~1\AppData\Local\Temp\build879358309df4280d577acf52baf46a16.tmp" -warnings=none -prefs=build.warn_data_percentage=75 -verbose "C:\Users\PC Famille\Downloads\glove\glove\glove\glove.ino"
"C:\Program Files (x86)\Arduino\hardware\tools\avr/bin/avr-g++" -c -g -Os -w -std=gnu++11 -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics  -w -x c++ -E -CC -mmcu=atmega32u4 -DF_CPU=16000000L -DARDUINO=10609 -DARDUINO_AVR_LEONARDO -DARDUINO_ARCH_AVR  -DUSB_VID=0x2341 -DUSB_PID=0x8036 '-DUSB_MANUFACTURER="Unknown"' '-DUSB_PRODUCT="Arduino Leonardo"' "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\cores\arduino" "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\variants\leonardo" "C:\Users\PCFAMI~1\AppData\Local\Temp\build879358309df4280d577acf52baf46a16.tmp\sketch\glove.ino.cpp" -o "nul"
"C:\Program Files (x86)\Arduino\hardware\tools\avr/bin/avr-g++" -c -g -Os -w -std=gnu++11 -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics  -w -x c++ -E -CC -mmcu=atmega32u4 -DF_CPU=16000000L -DARDUINO=10609 -DARDUINO_AVR_LEONARDO -DARDUINO_ARCH_AVR  -DUSB_VID=0x2341 -DUSB_PID=0x8036 '-DUSB_MANUFACTURER="Unknown"' '-DUSB_PRODUCT="Arduino Leonardo"' "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\cores\arduino" "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\variants\leonardo" "C:\Users\PCFAMI~1\AppData\Local\Temp\build879358309df4280d577acf52baf46a16.tmp\sketch\glove.ino.cpp" -o "C:\Users\PCFAMI~1\AppData\Local\Temp\build879358309df4280d577acf52baf46a16.tmp\preproc\ctags_target_for_gcc_minus_e.cpp"
C:\Users\PC Famille\Downloads\glove\glove\glove\glove.ino:1:21: fatal error: globals.h: No such file or directory

 #include "globals.h"

                     ^

compilation terminated.

exit status 1
Error compiling for board Arduino Leonardo.

I tried with 3 different games and still have the same message and no reaction on the arduboy. Any idea of where I messed up?

Thank you for the help!


(Scott) #2

It doesn’t look like you’ve followed the Adding programs (sketches) to the Arduino IDE guide.


#3

HI MLXXX,

I didn’t notice this part of the Quick start guide, sorry…

So I tried again with the help of the topic you linked and I still get this:

Arduino : 1.6.9 (Windows 10), Carte : "Arduino Leonardo"

C:\Program Files (x86)\Arduino\arduino-builder -dump-prefs -logger=machine -hardware "C:\Program Files (x86)\Arduino\hardware" -tools "C:\Program Files (x86)\Arduino\tools-builder" -tools "C:\Program Files (x86)\Arduino\hardware\tools\avr" -built-in-libraries "C:\Program Files (x86)\Arduino\libraries" -libraries "C:\Users\PC Famille\Downloads\libraries" -fqbn=arduino:avr:leonardo -vid-pid=0X2341_0X8036 -ide-version=10609 -build-path "C:\Users\PCFAMI~1\AppData\Local\Temp\build54683da53e0b10c27acd5ceb3f3027c5.tmp" -warnings=none -prefs=build.warn_data_percentage=75 -verbose "C:\Users\PC Famille\Downloads\glove\glove.ino"
C:\Program Files (x86)\Arduino\arduino-builder -compile -logger=machine -hardware "C:\Program Files (x86)\Arduino\hardware" -tools "C:\Program Files (x86)\Arduino\tools-builder" -tools "C:\Program Files (x86)\Arduino\hardware\tools\avr" -built-in-libraries "C:\Program Files (x86)\Arduino\libraries" -libraries "C:\Users\PC Famille\Downloads\libraries" -fqbn=arduino:avr:leonardo -vid-pid=0X2341_0X8036 -ide-version=10609 -build-path "C:\Users\PCFAMI~1\AppData\Local\Temp\build54683da53e0b10c27acd5ceb3f3027c5.tmp" -warnings=none -prefs=build.warn_data_percentage=75 -verbose "C:\Users\PC Famille\Downloads\glove\glove.ino"
"C:\Program Files (x86)\Arduino\hardware\tools\avr/bin/avr-g++" -c -g -Os -w -std=gnu++11 -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics  -w -x c++ -E -CC -mmcu=atmega32u4 -DF_CPU=16000000L -DARDUINO=10609 -DARDUINO_AVR_LEONARDO -DARDUINO_ARCH_AVR  -DUSB_VID=0x2341 -DUSB_PID=0x8036 '-DUSB_MANUFACTURER="Unknown"' '-DUSB_PRODUCT="Arduino Leonardo"' "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\cores\arduino" "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\variants\leonardo" "C:\Users\PCFAMI~1\AppData\Local\Temp\build54683da53e0b10c27acd5ceb3f3027c5.tmp\sketch\glove.ino.cpp" -o "nul"
"C:\Program Files (x86)\Arduino\hardware\tools\avr/bin/avr-g++" -c -g -Os -w -std=gnu++11 -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics  -w -x c++ -E -CC -mmcu=atmega32u4 -DF_CPU=16000000L -DARDUINO=10609 -DARDUINO_AVR_LEONARDO -DARDUINO_ARCH_AVR  -DUSB_VID=0x2341 -DUSB_PID=0x8036 '-DUSB_MANUFACTURER="Unknown"' '-DUSB_PRODUCT="Arduino Leonardo"' "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\cores\arduino" "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\variants\leonardo" "C:\Users\PCFAMI~1\AppData\Local\Temp\build54683da53e0b10c27acd5ceb3f3027c5.tmp\sketch\glove.ino.cpp" -o "C:\Users\PCFAMI~1\AppData\Local\Temp\build54683da53e0b10c27acd5ceb3f3027c5.tmp\preproc\ctags_target_for_gcc_minus_e.cpp"
In file included from C:\Users\PC Famille\Downloads\glove\glove.ino:1:0:

C:\Users\PCFAMI~1\AppData\Local\Temp\build54683da53e0b10c27acd5ceb3f3027c5.tmp\sketch\globals.h:4:21: fatal error: Arduboy.h: No such file or directory

 #include "Arduboy.h"

                     ^

compilation terminated.

exit status 1
Error compiling for board Arduino Leonardo.

Any idea?


(Scott) #4

The error you’re getting is most likely the result of not having the Arduboy library installed.

I suggest you look at Step 2 of the Quick Start Guide again and make sure you are properly installing the Arduboy library into the Arduino IDE. Then, follow Guide Step 3 and make sure you can upload one for the Arduboy library example sketches, such as HelloWorld, to your Arduboy and have it run properly.

Once you have one of the examples working. You can go back to trying Glove.


#5

Thank you for the help, it is much appreciated.

I thought I I stalled the library as I followed the guide already but will do it again. Also, is it normal that I have a black screen on the Audubon St all time (when on, when off, when plugged, when unplugged)?


(Scott) #6

It’s not normal if you successfully upload a sketch that’s supposed to display something. Since you’ve said that the game that was installed in the Arduboy at the factory worked when you first got it, I’m guessing that something went wrong when you tried to install a different game.

Let’s first try to get to the point where you can successfully verify/compile a game even without uploading it to the Arduboy. You can do this by using the verify button at the top left of the IDE. If you can do this without any errors, then you can try connecting your Arduboy and uploading the same game.


(Tom Stewart) #7

All black screen is/was a pretty common side effect of (successfully) uploading a game written for the dev board onto a production Arduboy…


#8

Thank you, I will use the verify button with the Arduboy unplugged and see how it goes!


#9

So I tried to verify without uploading and I get an other error message:

Arduino : 1.6.9 (Windows 10), Carte : "Arduino Leonardo"

C:\Program Files (x86)\Arduino\arduino-builder -dump-prefs -logger=machine -hardware "C:\Program Files (x86)\Arduino\hardware" -tools "C:\Program Files (x86)\Arduino\tools-builder" -tools "C:\Program Files (x86)\Arduino\hardware\tools\avr" -built-in-libraries "C:\Program Files (x86)\Arduino\libraries" -libraries "C:\Users\PC Famille\Desktop\Sketchbook\libraries" -fqbn=arduino:avr:leonardo -ide-version=10609 -build-path "C:\Users\PCFAMI~1\AppData\Local\Temp\build34abc1c6d618cc29df01c1b94e5b813c.tmp" -warnings=none -prefs=build.warn_data_percentage=75 -verbose "C:\Users\PC Famille\Desktop\Sketchbook\glove\glove.ino"
C:\Program Files (x86)\Arduino\arduino-builder -compile -logger=machine -hardware "C:\Program Files (x86)\Arduino\hardware" -tools "C:\Program Files (x86)\Arduino\tools-builder" -tools "C:\Program Files (x86)\Arduino\hardware\tools\avr" -built-in-libraries "C:\Program Files (x86)\Arduino\libraries" -libraries "C:\Users\PC Famille\Desktop\Sketchbook\libraries" -fqbn=arduino:avr:leonardo -ide-version=10609 -build-path "C:\Users\PCFAMI~1\AppData\Local\Temp\build34abc1c6d618cc29df01c1b94e5b813c.tmp" -warnings=none -prefs=build.warn_data_percentage=75 -verbose "C:\Users\PC Famille\Desktop\Sketchbook\glove\glove.ino"
"C:\Program Files (x86)\Arduino\hardware\tools\avr/bin/avr-g++" -c -g -Os -w -std=gnu++11 -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics  -w -x c++ -E -CC -mmcu=atmega32u4 -DF_CPU=16000000L -DARDUINO=10609 -DARDUINO_AVR_LEONARDO -DARDUINO_ARCH_AVR  -DUSB_VID=0x2341 -DUSB_PID=0x8036 '-DUSB_MANUFACTURER="Unknown"' '-DUSB_PRODUCT="Arduino Leonardo"' "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\cores\arduino" "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\variants\leonardo" "C:\Users\PCFAMI~1\AppData\Local\Temp\build34abc1c6d618cc29df01c1b94e5b813c.tmp\sketch\glove.ino.cpp" -o "nul"
"C:\Program Files (x86)\Arduino\hardware\tools\avr/bin/avr-g++" -c -g -Os -w -std=gnu++11 -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics  -w -x c++ -E -CC -mmcu=atmega32u4 -DF_CPU=16000000L -DARDUINO=10609 -DARDUINO_AVR_LEONARDO -DARDUINO_ARCH_AVR  -DUSB_VID=0x2341 -DUSB_PID=0x8036 '-DUSB_MANUFACTURER="Unknown"' '-DUSB_PRODUCT="Arduino Leonardo"' "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\cores\arduino" "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\variants\leonardo" "C:\Users\PCFAMI~1\AppData\Local\Temp\build34abc1c6d618cc29df01c1b94e5b813c.tmp\sketch\glove.ino.cpp" -o "C:\Users\PCFAMI~1\AppData\Local\Temp\build34abc1c6d618cc29df01c1b94e5b813c.tmp\preproc\ctags_target_for_gcc_minus_e.cpp"
In file included from C:\Users\PC Famille\Desktop\Sketchbook\glove\glove.ino:1:0:

C:\Users\PCFAMI~1\AppData\Local\Temp\build34abc1c6d618cc29df01c1b94e5b813c.tmp\sketch\globals.h:4:21: fatal error: Arduboy.h: No such file or directory

 #include "Arduboy.h"

                     ^

compilation terminated.

exit status 1
Error compiling for board Arduino Leonardo.

There is obviously something I did wrong but I cannot find what. I have been following the two tutorials and I am still stuck :frowning:


(Scott) #10

Have you installed the Arduboy library?
http://community.arduboy.com/t/cant-upload-sketch/1318/4


#11

So I went through the Quick Start Guide again, installed the library again and I realized that there is an issue with the port. It doesn’t matter if the adruboy is plugged or unplugged, I cannot select any port in Tools. The “port” option is in light gray and not clickable.

I am sorry to be a pain, your help is much appreciated…


(Scott) #12

Make sure your Arduboy is turned on when you try to connect it to your computer. It may also be a problem with the USB cable that you’re using. If possible, try a different cable.


(Ross) #13

This is where I usually suggest you start with www.codebender.cc, and use the Arduboy Games account.

https://codebender.cc/user/ArduboyGames

This should work every time, and will let you start playing while you get the Arduino IDE in order.


#14

Very strange, I tried codebender, I get to the point where I can chose the board and port and there is no port detected even though the Arduiboy is plugged and switched on… I am 100% sure of my port and cable as I use them for my telephone :frowning:


(Scott) #15

If that is truly the case, then the USB port on your Arduboy may be bad. But note that other people have had cables that worked with their phone but not with the Arduboy.


(Tomi) #16

On Linux it’s easy to see if the computer has even tried to connect the USB device (dmesg listing), but I don’t know how to do that on Windows.


#17

Oh. Then I should start here I guess.


(Ross) #18

This actually isn’t necessarily true. A cable can be used to send data to a phone just fine, like a file transfer, but still not work with an Arduboy. Cables get kinked and damaged, or may be made of inferior materials. These types of connector issues can cause a disparity in signals, and a loss of sync when when uploading information to an Arduino product, like the Leonardo (Arduboy).

I really do recommend getting a brank spankin new cable, a decentish one and giving it a go. You can find quite a few issues like this, resolved with new cables in the #arduboy:issues category. It might be enough of a thing, where it would be worth bundling a cable with the units.

Here is some more information, that is related to cable quality, and difference in performance. Not related to data-sync, but it demonstrates a common problem in cables.


(Phil Graham) #19

I’m getting the error message error status 1.

Error compiling board Arduboy.

What I’m I doing wrong?

When it says library is that where the ino file should be or does it mean library board

That’s the only thing I can’t do upload a sketch.

Tia!


(Scott) #20

@phil8715 Tell us what the output line containing fatal error: says.