0

Problems compiling Space Invader Gemma Source code
Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.

Problems compiling Space Invader Gemma Source code

by clefty on Sun Mar 12, 2017 3:51 pm

Hi All,

I'm getting a raft of errors when I try and compile the space invader code. It appears it's trying to call things that are undeclared - but to be honest I can't make head nor tail of it. I think I've got all the libraries installed.
Note communication with the GEMMA is fine and I've successfully uploaded Blink. At this stage I'm just trying to compile the code. anim.h is present and appears correct as well.
Running Ardunio 1.8.1 on OSX El Capitan.

Error file attached. Any assistance would be greatly appreciated.

Thanks

C
Attachments
errors.txt
error file
(30 KiB) Downloaded 18 times

clefty
 
Posts: 2
Joined: Sun Mar 12, 2017 3:36 pm

Re: Problems compiling Space Invader Gemma Source code

by franklin97355 on Sun Mar 12, 2017 9:40 pm

It helps if you paste the code directly so others can see it here.
Code: Select all | TOGGLE FULL SIZE
Arduino: 1.8.1 (Mac OS X), Board: "Arduino Gemma"

/Applications/Arduino.app/Contents/Java/arduino-builder -dump-prefs -logger=machine -hardware /Applications/Arduino.app/Contents/Java/hardware -tools /Applications/Arduino.app/Contents/Java/tools-builder -tools /Applications/Arduino.app/Contents/Java/hardware/tools/avr -built-in-libraries /Applications/Arduino.app/Contents/Java/libraries -libraries /Users/clefty/Documents/Arduino/libraries -fqbn=arduino:avr:gemma -ide-version=10801 -build-path /var/folders/yn/psdh47tn2ll12qwtmf8bk4g80000gn/T/arduino_build_425140 -warnings=none -prefs=build.warn_data_percentage=75 -prefs=runtime.tools.arduinoOTA.path=/Applications/Arduino.app/Contents/Java/hardware/tools/avr -prefs=runtime.tools.avr-gcc.path=/Applications/Arduino.app/Contents/Java/hardware/tools/avr -prefs=runtime.tools.avrdude.path=/Applications/Arduino.app/Contents/Java/hardware/tools/avr -verbose /Users/clefty/Documents/Arduino/space_invader/space_invader.ino
/Applications/Arduino.app/Contents/Java/arduino-builder -compile -logger=machine -hardware /Applications/Arduino.app/Contents/Java/hardware -tools /Applications/Arduino.app/Contents/Java/tools-builder -tools /Applications/Arduino.app/Contents/Java/hardware/tools/avr -built-in-libraries /Applications/Arduino.app/Contents/Java/libraries -libraries /Users/clefty/Documents/Arduino/libraries -fqbn=arduino:avr:gemma -ide-version=10801 -build-path /var/folders/yn/psdh47tn2ll12qwtmf8bk4g80000gn/T/arduino_build_425140 -warnings=none -prefs=build.warn_data_percentage=75 -prefs=runtime.tools.arduinoOTA.path=/Applications/Arduino.app/Contents/Java/hardware/tools/avr -prefs=runtime.tools.avr-gcc.path=/Applications/Arduino.app/Contents/Java/hardware/tools/avr -prefs=runtime.tools.avrdude.path=/Applications/Arduino.app/Contents/Java/hardware/tools/avr -verbose /Users/clefty/Documents/Arduino/space_invader/space_invader.ino
Using board 'gemma' from platform in folder: /Applications/Arduino.app/Contents/Java/hardware/arduino/avr
Using core 'arduino' from platform in folder: /Applications/Arduino.app/Contents/Java/hardware/arduino/avr
Detecting libraries used...
"/Applications/Arduino.app/Contents/Java/hardware/tools/avr/bin/avr-g++" -c -g -Os -w -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics  -flto -w -x c++ -E -CC -mmcu=attiny85 -DF_CPU=8000000L -DARDUINO=10801 -DARDUINO_AVR_GEMMA -DARDUINO_ARCH_AVR   "-I/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/cores/arduino" "-I/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/variants/gemma" "/var/folders/yn/psdh47tn2ll12qwtmf8bk4g80000gn/T/arduino_build_425140/sketch/space_invader.ino.cpp" -o "/dev/null"
"/Applications/Arduino.app/Contents/Java/hardware/tools/avr/bin/avr-g++" -c -g -Os -w -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics  -flto -w -x c++ -E -CC -mmcu=attiny85 -DF_CPU=8000000L -DARDUINO=10801 -DARDUINO_AVR_GEMMA -DARDUINO_ARCH_AVR   "-I/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/cores/arduino" "-I/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/variants/gemma" "-I/Users/clefty/Documents/Arduino/libraries/TinyWireM" "/var/folders/yn/psdh47tn2ll12qwtmf8bk4g80000gn/T/arduino_build_425140/sketch/space_invader.ino.cpp" -o "/dev/null"
"/Applications/Arduino.app/Contents/Java/hardware/tools/avr/bin/avr-g++" -c -g -Os -w -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics  -flto -w -x c++ -E -CC -mmcu=attiny85 -DF_CPU=8000000L -DARDUINO=10801 -DARDUINO_AVR_GEMMA -DARDUINO_ARCH_AVR   "-I/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/cores/arduino" "-I/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/variants/gemma" "-I/Users/clefty/Documents/Arduino/libraries/TinyWireM" "-I/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src" "/var/folders/yn/psdh47tn2ll12qwtmf8bk4g80000gn/T/arduino_build_425140/sketch/space_invader.ino.cpp" -o "/dev/null"
"/Applications/Arduino.app/Contents/Java/hardware/tools/avr/bin/avr-g++" -c -g -Os -w -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics  -flto -w -x c++ -E -CC -mmcu=attiny85 -DF_CPU=8000000L -DARDUINO=10801 -DARDUINO_AVR_GEMMA -DARDUINO_ARCH_AVR   "-I/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/cores/arduino" "-I/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/variants/gemma" "-I/Users/clefty/Documents/Arduino/libraries/TinyWireM" "-I/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src" "/Users/clefty/Documents/Arduino/libraries/TinyWireM/TinyWireM.cpp" -o "/dev/null"
"/Applications/Arduino.app/Contents/Java/hardware/tools/avr/bin/avr-g++" -c -g -Os -w -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics  -flto -w -x c++ -E -CC -mmcu=attiny85 -DF_CPU=8000000L -DARDUINO=10801 -DARDUINO_AVR_GEMMA -DARDUINO_ARCH_AVR   "-I/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/cores/arduino" "-I/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/variants/gemma" "-I/Users/clefty/Documents/Arduino/libraries/TinyWireM" "-I/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src" "/Users/clefty/Documents/Arduino/libraries/TinyWireM/USI_TWI_Master.cpp" -o "/dev/null"
"/Applications/Arduino.app/Contents/Java/hardware/tools/avr/bin/avr-g++" -c -g -Os -w -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics  -flto -w -x c++ -E -CC -mmcu=attiny85 -DF_CPU=8000000L -DARDUINO=10801 -DARDUINO_AVR_GEMMA -DARDUINO_ARCH_AVR   "-I/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/cores/arduino" "-I/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/variants/gemma" "-I/Users/clefty/Documents/Arduino/libraries/TinyWireM" "-I/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src" "/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/Wire.cpp" -o "/dev/null"
"/Applications/Arduino.app/Contents/Java/hardware/tools/avr/bin/avr-g++" -c -g -Os -w -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics  -flto -w -x c++ -E -CC -mmcu=attiny85 -DF_CPU=8000000L -DARDUINO=10801 -DARDUINO_AVR_GEMMA -DARDUINO_ARCH_AVR   "-I/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/cores/arduino" "-I/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/variants/gemma" "-I/Users/clefty/Documents/Arduino/libraries/TinyWireM" "-I/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src" "/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c" -o "/dev/null"
Generating function prototypes...
"/Applications/Arduino.app/Contents/Java/hardware/tools/avr/bin/avr-g++" -c -g -Os -w -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics  -flto -w -x c++ -E -CC -mmcu=attiny85 -DF_CPU=8000000L -DARDUINO=10801 -DARDUINO_AVR_GEMMA -DARDUINO_ARCH_AVR   "-I/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/cores/arduino" "-I/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/variants/gemma" "-I/Users/clefty/Documents/Arduino/libraries/TinyWireM" "-I/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src" "/var/folders/yn/psdh47tn2ll12qwtmf8bk4g80000gn/T/arduino_build_425140/sketch/space_invader.ino.cpp" -o "/var/folders/yn/psdh47tn2ll12qwtmf8bk4g80000gn/T/arduino_build_425140/preproc/ctags_target_for_gcc_minus_e.cpp"
"/Applications/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/yn/psdh47tn2ll12qwtmf8bk4g80000gn/T/arduino_build_425140/preproc/ctags_target_for_gcc_minus_e.cpp"
Compiling sketch...
"/Applications/Arduino.app/Contents/Java/hardware/tools/avr/bin/avr-g++" -c -g -Os -w -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -MMD -flto -mmcu=attiny85 -DF_CPU=8000000L -DARDUINO=10801 -DARDUINO_AVR_GEMMA -DARDUINO_ARCH_AVR   "-I/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/cores/arduino" "-I/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/variants/gemma" "-I/Users/clefty/Documents/Arduino/libraries/TinyWireM" "-I/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src" "/var/folders/yn/psdh47tn2ll12qwtmf8bk4g80000gn/T/arduino_build_425140/sketch/space_invader.ino.cpp" -o "/var/folders/yn/psdh47tn2ll12qwtmf8bk4g80000gn/T/arduino_build_425140/sketch/space_invader.ino.cpp.o"
Compiling libraries...
Compiling library "TinyWireM"
"/Applications/Arduino.app/Contents/Java/hardware/tools/avr/bin/avr-g++" -c -g -Os -w -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -MMD -flto -mmcu=attiny85 -DF_CPU=8000000L -DARDUINO=10801 -DARDUINO_AVR_GEMMA -DARDUINO_ARCH_AVR   "-I/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/cores/arduino" "-I/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/variants/gemma" "-I/Users/clefty/Documents/Arduino/libraries/TinyWireM" "-I/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src" "/Users/clefty/Documents/Arduino/libraries/TinyWireM/TinyWireM.cpp" -o "/var/folders/yn/psdh47tn2ll12qwtmf8bk4g80000gn/T/arduino_build_425140/libraries/TinyWireM/TinyWireM.cpp.o"
"/Applications/Arduino.app/Contents/Java/hardware/tools/avr/bin/avr-g++" -c -g -Os -w -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -MMD -flto -mmcu=attiny85 -DF_CPU=8000000L -DARDUINO=10801 -DARDUINO_AVR_GEMMA -DARDUINO_ARCH_AVR   "-I/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/cores/arduino" "-I/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/variants/gemma" "-I/Users/clefty/Documents/Arduino/libraries/TinyWireM" "-I/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src" "/Users/clefty/Documents/Arduino/libraries/TinyWireM/USI_TWI_Master.cpp" -o "/var/folders/yn/psdh47tn2ll12qwtmf8bk4g80000gn/T/arduino_build_425140/libraries/TinyWireM/USI_TWI_Master.cpp.o"
Compiling library "Wire"
"/Applications/Arduino.app/Contents/Java/hardware/tools/avr/bin/avr-g++" -c -g -Os -w -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -MMD -flto -mmcu=attiny85 -DF_CPU=8000000L -DARDUINO=10801 -DARDUINO_AVR_GEMMA -DARDUINO_ARCH_AVR   "-I/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/cores/arduino" "-I/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/variants/gemma" "-I/Users/clefty/Documents/Arduino/libraries/TinyWireM" "-I/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src" "/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/Wire.cpp" -o "/var/folders/yn/psdh47tn2ll12qwtmf8bk4g80000gn/T/arduino_build_425140/libraries/Wire/Wire.cpp.o"
"/Applications/Arduino.app/Contents/Java/hardware/tools/avr/bin/avr-gcc" -c -g -Os -w -std=gnu11 -ffunction-sections -fdata-sections -MMD -flto -fno-fat-lto-objects -mmcu=attiny85 -DF_CPU=8000000L -DARDUINO=10801 -DARDUINO_AVR_GEMMA -DARDUINO_ARCH_AVR   "-I/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/cores/arduino" "-I/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/variants/gemma" "-I/Users/clefty/Documents/Arduino/libraries/TinyWireM" "-I/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src" "/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c" -o "/var/folders/yn/psdh47tn2ll12qwtmf8bk4g80000gn/T/arduino_build_425140/libraries/Wire/utility/twi.c.o"
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c: In function 'twi_init':
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:76:16: error: 'SDA' undeclared (first use in this function)
   digitalWrite(SDA, 1);
                ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:76:16: note: each undeclared identifier is reported only once for each function it appears in
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:77:16: error: 'SCL' undeclared (first use in this function)
   digitalWrite(SCL, 1);
                ^
In file included from /Applications/Arduino.app/Contents/Java/hardware/tools/avr/avr/include/avr/io.h:99:0,
                 from /Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:25:
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:80:7: error: 'TWSR' undeclared (first use in this function)
   cbi(TWSR, TWPS0);
       ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:80:3: note: in expansion of macro 'cbi'
   cbi(TWSR, TWPS0);
   ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:80:13: error: 'TWPS0' undeclared (first use in this function)
   cbi(TWSR, TWPS0);
             ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:80:3: note: in expansion of macro 'cbi'
   cbi(TWSR, TWPS0);
   ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:81:13: error: 'TWPS1' undeclared (first use in this function)
   cbi(TWSR, TWPS1);
             ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:81:3: note: in expansion of macro 'cbi'
   cbi(TWSR, TWPS1);
   ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:82:3: error: 'TWBR' undeclared (first use in this function)
   TWBR = ((F_CPU / TWI_FREQ) - 16) / 2;
   ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:90:3: error: 'TWCR' undeclared (first use in this function)
   TWCR = _BV(TWEN) | _BV(TWIE) | _BV(TWEA);
   ^
In file included from /Applications/Arduino.app/Contents/Java/hardware/tools/avr/avr/include/avr/io.h:99:0,
                 from /Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:25:
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:90:14: error: 'TWEN' undeclared (first use in this function)
   TWCR = _BV(TWEN) | _BV(TWIE) | _BV(TWEA);
              ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:90:26: error: 'TWIE' undeclared (first use in this function)
   TWCR = _BV(TWEN) | _BV(TWIE) | _BV(TWEA);
                          ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:90:38: error: 'TWEA' undeclared (first use in this function)
   TWCR = _BV(TWEN) | _BV(TWIE) | _BV(TWEA);
                                      ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c: In function 'twi_disable':
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:102:3: error: 'TWCR' undeclared (first use in this function)
   TWCR &= ~(_BV(TWEN) | _BV(TWIE) | _BV(TWEA));
   ^
In file included from /Applications/Arduino.app/Contents/Java/hardware/tools/avr/avr/include/avr/io.h:99:0,
                 from /Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:25:
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:102:17: error: 'TWEN' undeclared (first use in this function)
   TWCR &= ~(_BV(TWEN) | _BV(TWIE) | _BV(TWEA));
                 ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:102:29: error: 'TWIE' undeclared (first use in this function)
   TWCR &= ~(_BV(TWEN) | _BV(TWIE) | _BV(TWEA));
                             ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:102:41: error: 'TWEA' undeclared (first use in this function)
   TWCR &= ~(_BV(TWEN) | _BV(TWIE) | _BV(TWEA));
                                         ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:105:16: error: 'SDA' undeclared (first use in this function)
   digitalWrite(SDA, 0);
                ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:106:16: error: 'SCL' undeclared (first use in this function)
   digitalWrite(SCL, 0);
                ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c: In function 'twi_setAddress':
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:118:3: error: 'TWAR' undeclared (first use in this function)
   TWAR = address << 1;
   ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c: In function 'twi_setFrequency':
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:129:3: error: 'TWBR' undeclared (first use in this function)
   TWBR = ((F_CPU / frequency) - 16) / 2;
   ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c: In function 'twi_readFrom':
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:187:7: error: 'TWDR' undeclared (first use in this function)
       TWDR = twi_slarw;
       ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:188:13: error: 'TWCR' undeclared (first use in this function)
     } while(TWCR & _BV(TWWC));
             ^
In file included from /Applications/Arduino.app/Contents/Java/hardware/tools/avr/avr/include/avr/io.h:99:0,
                 from /Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:25:
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:188:24: error: 'TWWC' undeclared (first use in this function)
     } while(TWCR & _BV(TWWC));
                        ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:189:16: error: 'TWINT' undeclared (first use in this function)
     TWCR = _BV(TWINT) | _BV(TWEA) | _BV(TWEN) | _BV(TWIE); // enable INTs, but not START
                ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:189:29: error: 'TWEA' undeclared (first use in this function)
     TWCR = _BV(TWINT) | _BV(TWEA) | _BV(TWEN) | _BV(TWIE); // enable INTs, but not START
                             ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:189:41: error: 'TWEN' undeclared (first use in this function)
     TWCR = _BV(TWINT) | _BV(TWEA) | _BV(TWEN) | _BV(TWIE); // enable INTs, but not START
                                         ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:189:53: error: 'TWIE' undeclared (first use in this function)
     TWCR = _BV(TWINT) | _BV(TWEA) | _BV(TWEN) | _BV(TWIE); // enable INTs, but not START
                                                     ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:193:65: error: 'TWSTA' undeclared (first use in this function)
     TWCR = _BV(TWEN) | _BV(TWIE) | _BV(TWEA) | _BV(TWINT) | _BV(TWSTA);
                                                                 ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c: In function 'twi_writeTo':
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:269:7: error: 'TWDR' undeclared (first use in this function)
       TWDR = twi_slarw;   
       ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:270:13: error: 'TWCR' undeclared (first use in this function)
     } while(TWCR & _BV(TWWC));
             ^
In file included from /Applications/Arduino.app/Contents/Java/hardware/tools/avr/avr/include/avr/io.h:99:0,
                 from /Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:25:
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:270:24: error: 'TWWC' undeclared (first use in this function)
     } while(TWCR & _BV(TWWC));
                        ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:271:16: error: 'TWINT' undeclared (first use in this function)
     TWCR = _BV(TWINT) | _BV(TWEA) | _BV(TWEN) | _BV(TWIE); // enable INTs, but not START
                ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:271:29: error: 'TWEA' undeclared (first use in this function)
     TWCR = _BV(TWINT) | _BV(TWEA) | _BV(TWEN) | _BV(TWIE); // enable INTs, but not START
                             ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:271:41: error: 'TWEN' undeclared (first use in this function)
     TWCR = _BV(TWINT) | _BV(TWEA) | _BV(TWEN) | _BV(TWIE); // enable INTs, but not START
                                         ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:271:53: error: 'TWIE' undeclared (first use in this function)
     TWCR = _BV(TWINT) | _BV(TWEA) | _BV(TWEN) | _BV(TWIE); // enable INTs, but not START
                                                     ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:275:65: error: 'TWSTA' undeclared (first use in this function)
     TWCR = _BV(TWINT) | _BV(TWEA) | _BV(TWEN) | _BV(TWIE) | _BV(TWSTA); // enable INTs
                                                                 ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c: In function 'twi_reply':
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:357:5: error: 'TWCR' undeclared (first use in this function)
     TWCR = _BV(TWEN) | _BV(TWIE) | _BV(TWINT) | _BV(TWEA);
     ^
In file included from /Applications/Arduino.app/Contents/Java/hardware/tools/avr/avr/include/avr/io.h:99:0,
                 from /Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:25:
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:357:16: error: 'TWEN' undeclared (first use in this function)
     TWCR = _BV(TWEN) | _BV(TWIE) | _BV(TWINT) | _BV(TWEA);
                ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:357:28: error: 'TWIE' undeclared (first use in this function)
     TWCR = _BV(TWEN) | _BV(TWIE) | _BV(TWINT) | _BV(TWEA);
                            ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:357:40: error: 'TWINT' undeclared (first use in this function)
     TWCR = _BV(TWEN) | _BV(TWIE) | _BV(TWINT) | _BV(TWEA);
                                        ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:357:53: error: 'TWEA' undeclared (first use in this function)
     TWCR = _BV(TWEN) | _BV(TWIE) | _BV(TWINT) | _BV(TWEA);
                                                     ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c: In function 'twi_stop':
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:372:3: error: 'TWCR' undeclared (first use in this function)
   TWCR = _BV(TWEN) | _BV(TWIE) | _BV(TWEA) | _BV(TWINT) | _BV(TWSTO);
   ^
In file included from /Applications/Arduino.app/Contents/Java/hardware/tools/avr/avr/include/avr/io.h:99:0,
                 from /Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:25:
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:372:14: error: 'TWEN' undeclared (first use in this function)
   TWCR = _BV(TWEN) | _BV(TWIE) | _BV(TWEA) | _BV(TWINT) | _BV(TWSTO);
              ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:372:26: error: 'TWIE' undeclared (first use in this function)
   TWCR = _BV(TWEN) | _BV(TWIE) | _BV(TWEA) | _BV(TWINT) | _BV(TWSTO);
                          ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:372:38: error: 'TWEA' undeclared (first use in this function)
   TWCR = _BV(TWEN) | _BV(TWIE) | _BV(TWEA) | _BV(TWINT) | _BV(TWSTO);
                                      ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:372:50: error: 'TWINT' undeclared (first use in this function)
   TWCR = _BV(TWEN) | _BV(TWIE) | _BV(TWEA) | _BV(TWINT) | _BV(TWSTO);
                                                  ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:372:63: error: 'TWSTO' undeclared (first use in this function)
   TWCR = _BV(TWEN) | _BV(TWIE) | _BV(TWEA) | _BV(TWINT) | _BV(TWSTO);
                                                               ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c: In function 'twi_releaseBus':
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:393:3: error: 'TWCR' undeclared (first use in this function)
   TWCR = _BV(TWEN) | _BV(TWIE) | _BV(TWEA) | _BV(TWINT);
   ^
In file included from /Applications/Arduino.app/Contents/Java/hardware/tools/avr/avr/include/avr/io.h:99:0,
                 from /Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:25:
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:393:14: error: 'TWEN' undeclared (first use in this function)
   TWCR = _BV(TWEN) | _BV(TWIE) | _BV(TWEA) | _BV(TWINT);
              ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:393:26: error: 'TWIE' undeclared (first use in this function)
   TWCR = _BV(TWEN) | _BV(TWIE) | _BV(TWEA) | _BV(TWINT);
                          ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:393:38: error: 'TWEA' undeclared (first use in this function)
   TWCR = _BV(TWEN) | _BV(TWIE) | _BV(TWEA) | _BV(TWINT);
                                      ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:393:50: error: 'TWINT' undeclared (first use in this function)
   TWCR = _BV(TWEN) | _BV(TWIE) | _BV(TWEA) | _BV(TWINT);
                                                  ^
In file included from /Applications/Arduino.app/Contents/Java/hardware/tools/avr/avr/include/compat/twi.h:36:0,
                 from /Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:27:
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c: In function 'TWI_vect':
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:401:10: error: 'TWSR' undeclared (first use in this function)
   switch(TW_STATUS){
          ^
In file included from /Applications/Arduino.app/Contents/Java/hardware/tools/avr/avr/include/avr/io.h:99:0,
                 from /Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:25:
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:401:10: error: 'TWS7' undeclared (first use in this function)
   switch(TW_STATUS){
          ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:401:10: error: 'TWS6' undeclared (first use in this function)
   switch(TW_STATUS){
          ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:401:10: error: 'TWS5' undeclared (first use in this function)
   switch(TW_STATUS){
          ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:401:10: error: 'TWS4' undeclared (first use in this function)
   switch(TW_STATUS){
          ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:401:10: error: 'TWS3' undeclared (first use in this function)
   switch(TW_STATUS){
          ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:406:7: error: 'TWDR' undeclared (first use in this function)
       TWDR = twi_slarw;
       ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:426:4: error: 'TWCR' undeclared (first use in this function)
    TWCR = _BV(TWINT) | _BV(TWSTA)| _BV(TWEN) ;
    ^
In file included from /Applications/Arduino.app/Contents/Java/hardware/tools/avr/avr/include/avr/io.h:99:0,
                 from /Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:25:
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:426:15: error: 'TWINT' undeclared (first use in this function)
    TWCR = _BV(TWINT) | _BV(TWSTA)| _BV(TWEN) ;
               ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:426:28: error: 'TWSTA' undeclared (first use in this function)
    TWCR = _BV(TWINT) | _BV(TWSTA)| _BV(TWEN) ;
                            ^
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/utility/twi.c:426:40: error: 'TWEN' undeclared (first use in this function)
    TWCR = _BV(TWINT) | _BV(TWSTA)| _BV(TWEN) ;
                                        ^
Using library TinyWireM at version 1.0.0 in folder: /Users/clefty/Documents/Arduino/libraries/TinyWireM
Using library Wire at version 1.0 in folder: /Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire
exit status 1
Error compiling for board Arduino Gemma.
Make sure you are running the board file for the Adafruit Gemma if that is what you are using. Also check to see if all your libraries are up to date.

franklin97355
 
Posts: 16652
Joined: Mon Apr 21, 2008 2:33 pm
Location: Lacomb, OR.

Re: Problems compiling Space Invader Gemma Source code

by clefty on Mon Mar 13, 2017 11:48 am

Thanks, will do so in future.
Am using the correct board file - communication with other sketches is fine, and I'm updated all of my libraries as far as I can see.

From what I can see it appears to be trying to call things from the Wire library that show as undefined. My Wire library is fully up to date so I'm not sure where to go from here.

Thanks

C

clefty
 
Posts: 2
Joined: Sun Mar 12, 2017 3:36 pm

Please be positive and constructive with your questions and comments.