Arduventure - 12th TEAM a.r.g. game

It produces a larger binary for my game than 1.8.5 does :expressionless: wish I could get in on that optimization.

Well on Arduventure it saves 900 bytes*
comparison
*Size will be different with Standard Leonardo and arduboy libraries. I’m compiling using my master version of my HomeMade Package but with the standard Arduino core leaving just the Arduboy2 library and ATMlib optimisations (I also wasted a few bytes again by adding a battery a meter test)

It’s referenced in both a C++ function and assembler. The C++ code will be optimised away if not used (I haven’t investigated if this is actually the case) and the asm code does reference the symbol but doesn’t list it among its input or output operand list so the compiler probably feels entitled to consider it unused.

TheCompiler works in mysterious ways.

2 Likes

Very impressive. You put a lot into the Arduboy! I am motivated to start a game now but want to use your optimizations so I can add as much as I need. I this a bad place to ask for tips? Is there a wiki or something you guys can share with newbies to learn from all your work (I am new to c++ and don’t fully understand the coding layout!)

I’d suggest making your own thread, but certainly, you can ask for tips! However, it may be better to try makingthe game, first, then try to optimize things to fit in more, especially for beginners.

2 Likes

Tip number 1:
get comfortable with the language and start writing a game before worrying about optimisation.

Optimisation is no good if you don’t have anything to optimise,
or you don’t understand the aspects of the language that allow it to work.


@crait’s right though, best start another thread if you want to ask for tips.

10-4. Will do. Going to make a text based game first… So optimization shouldn’t be an issue now. Maybe next game will need some graphics!

2 Likes

I can’t seem to find out why I cannot install this darn game.
I installed the newest arduboy2.0 as far as I know.
Can anyone please help? I’m not that familiar with C++

Arduino: 1.8.5 (Mac OS X), Board: "Arduino/Genuino Uno"

/Users/20brdauben/Documents/Installed stuff/Arduino.app/Contents/Java/arduino-builder -dump-prefs -logger=machine -hardware /Users/20brdauben/Documents/Installed stuff/Arduino.app/Contents/Java/hardware -hardware /Users/20brdauben/Library/Arduino15/packages -tools /Users/20brdauben/Documents/Installed stuff/Arduino.app/Contents/Java/tools-builder -tools /Users/20brdauben/Documents/Installed stuff/Arduino.app/Contents/Java/hardware/tools/avr -tools /Users/20brdauben/Library/Arduino15/packages -built-in-libraries /Users/20brdauben/Documents/Installed stuff/Arduino.app/Contents/Java/libraries -libraries /Users/20brdauben/Documents/Arduino/libraries -fqbn=arduino:avr:uno -vid-pid=0X2341_0X8036 -ide-version=10805 -build-path /var/folders/2v/22ttxlr109n8z0hvm2k1dw8m0000gp/T/arduino_build_883893 -warnings=none -build-cache /var/folders/2v/22ttxlr109n8z0hvm2k1dw8m0000gp/T/arduino_cache_387650 -prefs=build.warn_data_percentage=75 -prefs=runtime.tools.arduinoOTA.path=/Users/20brdauben/Library/Arduino15/packages/arduino/tools/arduinoOTA/1.2.1 -prefs=runtime.tools.avrdude.path=/Users/20brdauben/Library/Arduino15/packages/arduino/tools/avrdude/6.3.0-arduino14 -prefs=runtime.tools.avr-gcc.path=/Users/20brdauben/Library/Arduino15/packages/arduino/tools/avr-gcc/5.4.0-atmel3.6.1-arduino2 -verbose /Users/20brdauben/Documents/Arduino/ID-46-Arduventure-1.0.1/ARDU_AB/ARDU_AB.ino
/Users/20brdauben/Documents/Installed stuff/Arduino.app/Contents/Java/arduino-builder -compile -logger=machine -hardware /Users/20brdauben/Documents/Installed stuff/Arduino.app/Contents/Java/hardware -hardware /Users/20brdauben/Library/Arduino15/packages -tools /Users/20brdauben/Documents/Installed stuff/Arduino.app/Contents/Java/tools-builder -tools /Users/20brdauben/Documents/Installed stuff/Arduino.app/Contents/Java/hardware/tools/avr -tools /Users/20brdauben/Library/Arduino15/packages -built-in-libraries /Users/20brdauben/Documents/Installed stuff/Arduino.app/Contents/Java/libraries -libraries /Users/20brdauben/Documents/Arduino/libraries -fqbn=arduino:avr:uno -vid-pid=0X2341_0X8036 -ide-version=10805 -build-path /var/folders/2v/22ttxlr109n8z0hvm2k1dw8m0000gp/T/arduino_build_883893 -warnings=none -build-cache /var/folders/2v/22ttxlr109n8z0hvm2k1dw8m0000gp/T/arduino_cache_387650 -prefs=build.warn_data_percentage=75 -prefs=runtime.tools.arduinoOTA.path=/Users/20brdauben/Library/Arduino15/packages/arduino/tools/arduinoOTA/1.2.1 -prefs=runtime.tools.avrdude.path=/Users/20brdauben/Library/Arduino15/packages/arduino/tools/avrdude/6.3.0-arduino14 -prefs=runtime.tools.avr-gcc.path=/Users/20brdauben/Library/Arduino15/packages/arduino/tools/avr-gcc/5.4.0-atmel3.6.1-arduino2 -verbose /Users/20brdauben/Documents/Arduino/ID-46-Arduventure-1.0.1/ARDU_AB/ARDU_AB.ino
Using board 'uno' from platform in folder: /Users/20brdauben/Library/Arduino15/packages/arduino/hardware/avr/1.6.23
Using core 'arduino' from platform in folder: /Users/20brdauben/Library/Arduino15/packages/arduino/hardware/avr/1.6.23
Detecting libraries used...
"/Users/20brdauben/Library/Arduino15/packages/arduino/tools/avr-gcc/5.4.0-atmel3.6.1-arduino2/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=10805 -DARDUINO_AVR_UNO -DARDUINO_ARCH_AVR   "-I/Users/20brdauben/Library/Arduino15/packages/arduino/hardware/avr/1.6.23/cores/arduino" "-I/Users/20brdauben/Library/Arduino15/packages/arduino/hardware/avr/1.6.23/variants/standard" "/var/folders/2v/22ttxlr109n8z0hvm2k1dw8m0000gp/T/arduino_build_883893/sketch/ARDU_AB.ino.cpp" -o "/dev/null"
"/Users/20brdauben/Library/Arduino15/packages/arduino/tools/avr-gcc/5.4.0-atmel3.6.1-arduino2/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=10805 -DARDUINO_AVR_UNO -DARDUINO_ARCH_AVR   "-I/Users/20brdauben/Library/Arduino15/packages/arduino/hardware/avr/1.6.23/cores/arduino" "-I/Users/20brdauben/Library/Arduino15/packages/arduino/hardware/avr/1.6.23/variants/standard" "-I/Users/20brdauben/Documents/Arduino/libraries/Arduboy2/src" "/var/folders/2v/22ttxlr109n8z0hvm2k1dw8m0000gp/T/arduino_build_883893/sketch/ARDU_AB.ino.cpp" -o "/dev/null"
"/Users/20brdauben/Library/Arduino15/packages/arduino/tools/avr-gcc/5.4.0-atmel3.6.1-arduino2/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=10805 -DARDUINO_AVR_UNO -DARDUINO_ARCH_AVR   "-I/Users/20brdauben/Library/Arduino15/packages/arduino/hardware/avr/1.6.23/cores/arduino" "-I/Users/20brdauben/Library/Arduino15/packages/arduino/hardware/avr/1.6.23/variants/standard" "-I/Users/20brdauben/Documents/Arduino/libraries/Arduboy2/src" "-I/Users/20brdauben/Library/Arduino15/packages/arduino/hardware/avr/1.6.23/libraries/EEPROM/src" "/var/folders/2v/22ttxlr109n8z0hvm2k1dw8m0000gp/T/arduino_build_883893/sketch/ARDU_AB.ino.cpp" -o "/dev/null"
"/Users/20brdauben/Library/Arduino15/packages/arduino/tools/avr-gcc/5.4.0-atmel3.6.1-arduino2/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=10805 -DARDUINO_AVR_UNO -DARDUINO_ARCH_AVR   "-I/Users/20brdauben/Library/Arduino15/packages/arduino/hardware/avr/1.6.23/cores/arduino" "-I/Users/20brdauben/Library/Arduino15/packages/arduino/hardware/avr/1.6.23/variants/standard" "-I/Users/20brdauben/Documents/Arduino/libraries/Arduboy2/src" "-I/Users/20brdauben/Library/Arduino15/packages/arduino/hardware/avr/1.6.23/libraries/EEPROM/src" "-I/Users/20brdauben/Documents/Arduino/libraries/ATMlib/src" "/var/folders/2v/22ttxlr109n8z0hvm2k1dw8m0000gp/T/arduino_build_883893/sketch/ARDU_AB.ino.cpp" -o "/dev/null"
"/Users/20brdauben/Library/Arduino15/packages/arduino/tools/avr-gcc/5.4.0-atmel3.6.1-arduino2/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=10805 -DARDUINO_AVR_UNO -DARDUINO_ARCH_AVR   "-I/Users/20brdauben/Library/Arduino15/packages/arduino/hardware/avr/1.6.23/cores/arduino" "-I/Users/20brdauben/Library/Arduino15/packages/arduino/hardware/avr/1.6.23/variants/standard" "-I/Users/20brdauben/Documents/Arduino/libraries/Arduboy2/src" "-I/Users/20brdauben/Library/Arduino15/packages/arduino/hardware/avr/1.6.23/libraries/EEPROM/src" "-I/Users/20brdauben/Documents/Arduino/libraries/ATMlib/src" "/Users/20brdauben/Documents/Arduino/libraries/Arduboy2/src/Arduboy2.cpp" -o "/dev/null"
"/Users/20brdauben/Library/Arduino15/packages/arduino/tools/avr-gcc/5.4.0-atmel3.6.1-arduino2/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=10805 -DARDUINO_AVR_UNO -DARDUINO_ARCH_AVR   "-I/Users/20brdauben/Library/Arduino15/packages/arduino/hardware/avr/1.6.23/cores/arduino" "-I/Users/20brdauben/Library/Arduino15/packages/arduino/hardware/avr/1.6.23/variants/standard" "-I/Users/20brdauben/Documents/Arduino/libraries/Arduboy2/src" "-I/Users/20brdauben/Library/Arduino15/packages/arduino/hardware/avr/1.6.23/libraries/EEPROM/src" "-I/Users/20brdauben/Documents/Arduino/libraries/ATMlib/src" "/Users/20brdauben/Documents/Arduino/libraries/Arduboy2/src/Arduboy2Audio.cpp" -o "/dev/null"
"/Users/20brdauben/Library/Arduino15/packages/arduino/tools/avr-gcc/5.4.0-atmel3.6.1-arduino2/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=10805 -DARDUINO_AVR_UNO -DARDUINO_ARCH_AVR   "-I/Users/20brdauben/Library/Arduino15/packages/arduino/hardware/avr/1.6.23/cores/arduino" "-I/Users/20brdauben/Library/Arduino15/packages/arduino/hardware/avr/1.6.23/variants/standard" "-I/Users/20brdauben/Documents/Arduino/libraries/Arduboy2/src" "-I/Users/20brdauben/Library/Arduino15/packages/arduino/hardware/avr/1.6.23/libraries/EEPROM/src" "-I/Users/20brdauben/Documents/Arduino/libraries/ATMlib/src" "/Users/20brdauben/Documents/Arduino/libraries/Arduboy2/src/Arduboy2Beep.cpp" -o "/dev/null"
"/Users/20brdauben/Library/Arduino15/packages/arduino/tools/avr-gcc/5.4.0-atmel3.6.1-arduino2/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=10805 -DARDUINO_AVR_UNO -DARDUINO_ARCH_AVR   "-I/Users/20brdauben/Library/Arduino15/packages/arduino/hardware/avr/1.6.23/cores/arduino" "-I/Users/20brdauben/Library/Arduino15/packages/arduino/hardware/avr/1.6.23/variants/standard" "-I/Users/20brdauben/Documents/Arduino/libraries/Arduboy2/src" "-I/Users/20brdauben/Library/Arduino15/packages/arduino/hardware/avr/1.6.23/libraries/EEPROM/src" "-I/Users/20brdauben/Documents/Arduino/libraries/ATMlib/src" "/Users/20brdauben/Documents/Arduino/libraries/Arduboy2/src/Arduboy2Core.cpp" -o "/dev/null"
"/Users/20brdauben/Library/Arduino15/packages/arduino/tools/avr-gcc/5.4.0-atmel3.6.1-arduino2/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=10805 -DARDUINO_AVR_UNO -DARDUINO_ARCH_AVR   "-I/Users/20brdauben/Library/Arduino15/packages/arduino/hardware/avr/1.6.23/cores/arduino" "-I/Users/20brdauben/Library/Arduino15/packages/arduino/hardware/avr/1.6.23/variants/standard" "-I/Users/20brdauben/Documents/Arduino/libraries/Arduboy2/src" "-I/Users/20brdauben/Library/Arduino15/packages/arduino/hardware/avr/1.6.23/libraries/EEPROM/src" "-I/Users/20brdauben/Documents/Arduino/libraries/ATMlib/src" "/Users/20brdauben/Documents/Arduino/libraries/Arduboy2/src/Sprites.cpp" -o "/dev/null"
"/Users/20brdauben/Library/Arduino15/packages/arduino/tools/avr-gcc/5.4.0-atmel3.6.1-arduino2/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=10805 -DARDUINO_AVR_UNO -DARDUINO_ARCH_AVR   "-I/Users/20brdauben/Library/Arduino15/packages/arduino/hardware/avr/1.6.23/cores/arduino" "-I/Users/20brdauben/Library/Arduino15/packages/arduino/hardware/avr/1.6.23/variants/standard" "-I/Users/20brdauben/Documents/Arduino/libraries/Arduboy2/src" "-I/Users/20brdauben/Library/Arduino15/packages/arduino/hardware/avr/1.6.23/libraries/EEPROM/src" "-I/Users/20brdauben/Documents/Arduino/libraries/ATMlib/src" "/Users/20brdauben/Documents/Arduino/libraries/Arduboy2/src/SpritesB.cpp" -o "/dev/null"
Using cached library dependencies for file: /Users/20brdauben/Documents/Arduino/libraries/Arduboy2/src/ab_logo.c
Using cached library dependencies for file: /Users/20brdauben/Documents/Arduino/libraries/Arduboy2/src/glcdfont.c
"/Users/20brdauben/Library/Arduino15/packages/arduino/tools/avr-gcc/5.4.0-atmel3.6.1-arduino2/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=10805 -DARDUINO_AVR_UNO -DARDUINO_ARCH_AVR   "-I/Users/20brdauben/Library/Arduino15/packages/arduino/hardware/avr/1.6.23/cores/arduino" "-I/Users/20brdauben/Library/Arduino15/packages/arduino/hardware/avr/1.6.23/variants/standard" "-I/Users/20brdauben/Documents/Arduino/libraries/Arduboy2/src" "-I/Users/20brdauben/Library/Arduino15/packages/arduino/hardware/avr/1.6.23/libraries/EEPROM/src" "-I/Users/20brdauben/Documents/Arduino/libraries/ATMlib/src" "/Users/20brdauben/Documents/Arduino/libraries/ATMlib/src/ATMlib.cpp" -o "/dev/null"
Generating function prototypes...
"/Users/20brdauben/Library/Arduino15/packages/arduino/tools/avr-gcc/5.4.0-atmel3.6.1-arduino2/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=10805 -DARDUINO_AVR_UNO -DARDUINO_ARCH_AVR   "-I/Users/20brdauben/Library/Arduino15/packages/arduino/hardware/avr/1.6.23/cores/arduino" "-I/Users/20brdauben/Library/Arduino15/packages/arduino/hardware/avr/1.6.23/variants/standard" "-I/Users/20brdauben/Documents/Arduino/libraries/Arduboy2/src" "-I/Users/20brdauben/Library/Arduino15/packages/arduino/hardware/avr/1.6.23/libraries/EEPROM/src" "-I/Users/20brdauben/Documents/Arduino/libraries/ATMlib/src" "/var/folders/2v/22ttxlr109n8z0hvm2k1dw8m0000gp/T/arduino_build_883893/sketch/ARDU_AB.ino.cpp" -o "/var/folders/2v/22ttxlr109n8z0hvm2k1dw8m0000gp/T/arduino_build_883893/preproc/ctags_target_for_gcc_minus_e.cpp"
"/Users/20brdauben/Documents/Installed stuff/Arduino.app/Contents/Java/tools-builder/ctags/5.8-arduino11/ctags" -u --language-force=c++ -f - --c++-kinds=svpf --fields=KSTtzns --line-directives "/var/folders/2v/22ttxlr109n8z0hvm2k1dw8m0000gp/T/arduino_build_883893/preproc/ctags_target_for_gcc_minus_e.cpp"
Compiling sketch...
"/Users/20brdauben/Library/Arduino15/packages/arduino/tools/avr-gcc/5.4.0-atmel3.6.1-arduino2/bin/avr-g++" -c -g -Os -w -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -Wno-error=narrowing -MMD -flto -mmcu=atmega328p -DF_CPU=16000000L -DARDUINO=10805 -DARDUINO_AVR_UNO -DARDUINO_ARCH_AVR   "-I/Users/20brdauben/Library/Arduino15/packages/arduino/hardware/avr/1.6.23/cores/arduino" "-I/Users/20brdauben/Library/Arduino15/packages/arduino/hardware/avr/1.6.23/variants/standard" "-I/Users/20brdauben/Documents/Arduino/libraries/Arduboy2/src" "-I/Users/20brdauben/Library/Arduino15/packages/arduino/hardware/avr/1.6.23/libraries/EEPROM/src" "-I/Users/20brdauben/Documents/Arduino/libraries/ATMlib/src" "/var/folders/2v/22ttxlr109n8z0hvm2k1dw8m0000gp/T/arduino_build_883893/sketch/ARDU_AB.ino.cpp" -o "/var/folders/2v/22ttxlr109n8z0hvm2k1dw8m0000gp/T/arduino_build_883893/sketch/ARDU_AB.ino.cpp.o"
Compiling libraries...
Compiling library "Arduboy2"
Using previously compiled file: /var/folders/2v/22ttxlr109n8z0hvm2k1dw8m0000gp/T/arduino_build_883893/libraries/Arduboy2/ab_logo.c.o
Using previously compiled file: /var/folders/2v/22ttxlr109n8z0hvm2k1dw8m0000gp/T/arduino_build_883893/libraries/Arduboy2/glcdfont.c.o
"/Users/20brdauben/Library/Arduino15/packages/arduino/tools/avr-gcc/5.4.0-atmel3.6.1-arduino2/bin/avr-g++" -c -g -Os -w -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -Wno-error=narrowing -MMD -flto -mmcu=atmega328p -DF_CPU=16000000L -DARDUINO=10805 -DARDUINO_AVR_UNO -DARDUINO_ARCH_AVR   "-I/Users/20brdauben/Library/Arduino15/packages/arduino/hardware/avr/1.6.23/cores/arduino" "-I/Users/20brdauben/Library/Arduino15/packages/arduino/hardware/avr/1.6.23/variants/standard" "-I/Users/20brdauben/Documents/Arduino/libraries/Arduboy2/src" "-I/Users/20brdauben/Library/Arduino15/packages/arduino/hardware/avr/1.6.23/libraries/EEPROM/src" "-I/Users/20brdauben/Documents/Arduino/libraries/ATMlib/src" "/Users/20brdauben/Documents/Arduino/libraries/Arduboy2/src/Arduboy2.cpp" -o "/var/folders/2v/22ttxlr109n8z0hvm2k1dw8m0000gp/T/arduino_build_883893/libraries/Arduboy2/Arduboy2.cpp.o"
/Users/20brdauben/Documents/Arduino/libraries/Arduboy2/src/Arduboy2.cpp: In member function 'bool Arduboy2Base::nextFrameDEV()':
/Users/20brdauben/Documents/Arduino/libraries/Arduboy2/src/Arduboy2.cpp:284:7: error: 'TXLED1' was not declared in this scope
       TXLED1;
       ^
/Users/20brdauben/Documents/Arduino/libraries/Arduboy2/src/Arduboy2.cpp:286:7: error: 'TXLED0' was not declared in this scope
       TXLED0;
       ^
Using library Arduboy2 at version 5.2.0 in folder: /Users/20brdauben/Documents/Arduino/libraries/Arduboy2 
Using library EEPROM at version 2.0 in folder: /Users/20brdauben/Library/Arduino15/packages/arduino/hardware/avr/1.6.23/libraries/EEPROM 
Using library ATMlib at version 1.2.6 in folder: /Users/20brdauben/Documents/Arduino/libraries/ATMlib 
exit status 1
Error compiling for board Arduino/Genuino Uno.

You have the board ‘Arduino/Genuino Uno’ selected. You need to select Leonardo or Arduboy.

4 Likes

Thanks <3

Now I feel like an idiot.

1 Like

Its not because you have made an error that made you an idiot… I hope, as else i’m too as i make alot errors and for me it more like that that i progress.

You mean “making mistakes does not make you an idiot”.
(Or “making mistakes doesn’t mean you are an idiot”.)

Indeed, making mistakes is completely expected.

The best way to get good at diagnosing error messages is to make the mistakes that cause the error messages.

I always checked the port but i completely forgot to check the board.

I tried to upload this game and I keep on getting an error that says “Error compiling for board Arduino Leonardo”. It also says that the sketch is too big, and memory is at 100%, so maybe that’s causing it.

Thanks!

Are you using v1.8.6 or v1.8.7 of the Arduino IDE?
If so, that could be releated.

I’m using v1.8.5 of the Arduino IDE.

Strange, I just tried compiling the master branch on v1.8.5 and I got:

Sketch uses 27922 bytes (97%) of program storage space. Maximum is 28672 bytes.
Global variables use 1624 bytes (63%) of dynamic memory, leaving 936 bytes for local variables. Maximum is 2560 bytes.

Are you sure you’ve got the board right?
Try redownloading the latest master branch.

Here’s what it looks like on my computer:

26%20AM

It still isn’t working, unfortunately

Make sure you use the latest Arduboy2 library. You can do this as following :

go to Sketch > include library > Manage library then in the text box in the top type Arduboy2 select version 5.2.0 and click update.

You may also want to repeat that for the ATMlib library

Edit:
corrected version number

1 Like

Like @Mr.Blinky said, make sure your libraries are up to date.
Also, did you redownload the source from the master branch?

If your libraries and the code are up to date then the only other thing I can think of is to reinstall the IDE.