jcchurch13 / Mechaduino-Firmware

Hardware available here:
http://tropical-labs.com
Other
389 stars 232 forks source link

invalid type argument of '->' (have 'uint16_t') #20

Closed pearl-qeautomation closed 7 years ago

pearl-qeautomation commented 7 years ago

Just cloned the latest version and trying to upload to my Mechaduino and getting an invalid type argument of '->' (have 'uint16_t') error.

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

/Applications/Arduino.app/Contents/Java/arduino-builder -dump-prefs -logger=machine -hardware /Applications/Arduino.app/Contents/Java/hardware -hardware /Users/allen/Library/Arduino15/packages -hardware /Users/allen/Documents/Arduino/hardware -tools /Applications/Arduino.app/Contents/Java/tools-builder -tools /Applications/Arduino.app/Contents/Java/hardware/tools/avr -tools /Users/allen/Library/Arduino15/packages -built-in-libraries /Applications/Arduino.app/Contents/Java/libraries -libraries /Users/allen/Documents/Arduino/libraries -fqbn=arduino:avr:uno -ide-version=10801 -build-path /var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632 -warnings=all -prefs=build.warn_data_percentage=75 -prefs=runtime.tools.avrdude.path=/Users/allen/Library/Arduino15/packages/arduino/tools/avrdude/6.0.1-arduino5 -prefs=runtime.tools.avr-gcc.path=/Applications/Arduino.app/Contents/Java/hardware/tools/avr -verbose /Users/allen/code/Mechaduino-Firmware/Mechaduino_01/Mechaduino_01/Mechaduino_01.ino
/Applications/Arduino.app/Contents/Java/arduino-builder -compile -logger=machine -hardware /Applications/Arduino.app/Contents/Java/hardware -hardware /Users/allen/Library/Arduino15/packages -hardware /Users/allen/Documents/Arduino/hardware -tools /Applications/Arduino.app/Contents/Java/tools-builder -tools /Applications/Arduino.app/Contents/Java/hardware/tools/avr -tools /Users/allen/Library/Arduino15/packages -built-in-libraries /Applications/Arduino.app/Contents/Java/libraries -libraries /Users/allen/Documents/Arduino/libraries -fqbn=arduino:avr:uno -ide-version=10801 -build-path /var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632 -warnings=all -prefs=build.warn_data_percentage=75 -prefs=runtime.tools.avrdude.path=/Users/allen/Library/Arduino15/packages/arduino/tools/avrdude/6.0.1-arduino5 -prefs=runtime.tools.avr-gcc.path=/Applications/Arduino.app/Contents/Java/hardware/tools/avr -verbose /Users/allen/code/Mechaduino-Firmware/Mechaduino_01/Mechaduino_01/Mechaduino_01.ino
Using board 'uno' from platform in folder: /Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13
Using core 'arduino' from platform in folder: /Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13
Build options changed, rebuilding all
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=atmega328p -DF_CPU=16000000L -DARDUINO=10801 -DARDUINO_AVR_UNO -DARDUINO_ARCH_AVR   "-I/Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13/cores/arduino" "-I/Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13/variants/standard" "/var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632/sketch/Mechaduino_01.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=atmega328p -DF_CPU=16000000L -DARDUINO=10801 -DARDUINO_AVR_UNO -DARDUINO_ARCH_AVR   "-I/Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13/cores/arduino" "-I/Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13/variants/standard" "/var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632/sketch/Controller.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=atmega328p -DF_CPU=16000000L -DARDUINO=10801 -DARDUINO_AVR_UNO -DARDUINO_ARCH_AVR   "-I/Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13/cores/arduino" "-I/Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13/variants/standard" "-I/Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13/libraries/SPI/src" "/var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632/sketch/Controller.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=atmega328p -DF_CPU=16000000L -DARDUINO=10801 -DARDUINO_AVR_UNO -DARDUINO_ARCH_AVR   "-I/Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13/cores/arduino" "-I/Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13/variants/standard" "-I/Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13/libraries/SPI/src" "/var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632/sketch/Parameters.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=atmega328p -DF_CPU=16000000L -DARDUINO=10801 -DARDUINO_AVR_UNO -DARDUINO_ARCH_AVR   "-I/Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13/cores/arduino" "-I/Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13/variants/standard" "-I/Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13/libraries/SPI/src" "-I/Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13/libraries/Wire/src" "/var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632/sketch/Parameters.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=atmega328p -DF_CPU=16000000L -DARDUINO=10801 -DARDUINO_AVR_UNO -DARDUINO_ARCH_AVR   "-I/Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13/cores/arduino" "-I/Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13/variants/standard" "-I/Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13/libraries/SPI/src" "-I/Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13/libraries/Wire/src" "/var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632/sketch/State.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=atmega328p -DF_CPU=16000000L -DARDUINO=10801 -DARDUINO_AVR_UNO -DARDUINO_ARCH_AVR   "-I/Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13/cores/arduino" "-I/Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13/variants/standard" "-I/Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13/libraries/SPI/src" "-I/Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13/libraries/Wire/src" "/var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632/sketch/Utils.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=atmega328p -DF_CPU=16000000L -DARDUINO=10801 -DARDUINO_AVR_UNO -DARDUINO_ARCH_AVR   "-I/Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13/cores/arduino" "-I/Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13/variants/standard" "-I/Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13/libraries/SPI/src" "-I/Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13/libraries/Wire/src" "/var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632/sketch/analogFastWrite.c" -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=atmega328p -DF_CPU=16000000L -DARDUINO=10801 -DARDUINO_AVR_UNO -DARDUINO_ARCH_AVR   "-I/Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13/cores/arduino" "-I/Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13/variants/standard" "-I/Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13/libraries/SPI/src" "-I/Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13/libraries/Wire/src" "/Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13/libraries/SPI/src/SPI.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=atmega328p -DF_CPU=16000000L -DARDUINO=10801 -DARDUINO_AVR_UNO -DARDUINO_ARCH_AVR   "-I/Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13/cores/arduino" "-I/Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13/variants/standard" "-I/Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13/libraries/SPI/src" "-I/Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13/libraries/Wire/src" "/Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13/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=atmega328p -DF_CPU=16000000L -DARDUINO=10801 -DARDUINO_AVR_UNO -DARDUINO_ARCH_AVR   "-I/Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13/cores/arduino" "-I/Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13/variants/standard" "-I/Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13/libraries/SPI/src" "-I/Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13/libraries/Wire/src" "/Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13/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=atmega328p -DF_CPU=16000000L -DARDUINO=10801 -DARDUINO_AVR_UNO -DARDUINO_ARCH_AVR   "-I/Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13/cores/arduino" "-I/Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13/variants/standard" "-I/Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13/libraries/SPI/src" "-I/Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13/libraries/Wire/src" "/var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632/sketch/Mechaduino_01.ino.cpp" -o "/var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632/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/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632/preproc/ctags_target_for_gcc_minus_e.cpp"
Compiling sketch...
"/Applications/Arduino.app/Contents/Java/hardware/tools/avr/bin/avr-gcc" -c -g -Os -Wall -Wextra -std=gnu11 -ffunction-sections -fdata-sections -MMD -flto -fno-fat-lto-objects -mmcu=atmega328p -DF_CPU=16000000L -DARDUINO=10801 -DARDUINO_AVR_UNO -DARDUINO_ARCH_AVR   "-I/Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13/cores/arduino" "-I/Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13/variants/standard" "-I/Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13/libraries/SPI/src" "-I/Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13/libraries/Wire/src" "/var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632/sketch/analogFastWrite.c" -o "/var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632/sketch/analogFastWrite.c.o"
/var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632/sketch/analogFastWrite.c: In function 'syncADC':
analogFastWrite.c:17: error: invalid type argument of '->' (have 'uint16_t')
   while (ADC->STATUS.bit.SYNCBUSY == 1)
             ^
/var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632/sketch/analogFastWrite.c: In function 'syncDAC':
analogFastWrite.c:24: error: 'DAC' undeclared (first use in this function)
   while (DAC->STATUS.bit.SYNCBUSY == 1)
          ^
/var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632/sketch/analogFastWrite.c:24:10: note: each undeclared identifier is reported only once for each function it appears in
/var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632/sketch/analogFastWrite.c: At top level:
analogFastWrite.c:29: error: unknown type name 'Tc'
 static __inline__ void syncTC_8(Tc* TCx) __attribute__((always_inline, unused));
                                 ^
analogFastWrite.c:30: error: unknown type name 'Tc'
 static void syncTC_8(Tc* TCx) {
                      ^
analogFastWrite.c:35: error: unknown type name 'Tcc'
 static __inline__ void syncTCC(Tcc* TCCx) __attribute__((always_inline, unused));
                                ^
analogFastWrite.c:36: error: unknown type name 'Tcc'
 static void syncTCC(Tcc* TCCx) {
                     ^
/var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632/sketch/analogFastWrite.c: In function 'analogFastWrite':
analogFastWrite.c:67: error: unknown type name 'PinDescription'
   PinDescription pinDesc = g_APinDescription[pin];
   ^
analogFastWrite.c:67: error: 'g_APinDescription' undeclared (first use in this function)
   PinDescription pinDesc = g_APinDescription[pin];
                            ^
analogFastWrite.c:68: error: request for member 'ulPinAttribute' in something not a structure or union
   uint32_t attr = pinDesc.ulPinAttribute;
                          ^
analogFastWrite.c:70: error: 'PIN_ATTR_ANALOG' undeclared (first use in this function)
   if ((attr & PIN_ATTR_ANALOG) == PIN_ATTR_ANALOG)
               ^
analogFastWrite.c:81: error: 'DAC' undeclared (first use in this function)
     DAC->DATA.reg = value & 0x3FF;  // DAC on 10 bits.
     ^
analogFastWrite.c:88: error: 'PIN_ATTR_PWM' undeclared (first use in this function)
   if ((attr & PIN_ATTR_PWM) == PIN_ATTR_PWM)
               ^
/var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632/sketch/analogFastWrite.c:91:5: warning: implicit declaration of function 'GetTCNumber' [-Wimplicit-function-declaration]
     uint32_t tcNum = GetTCNumber(pinDesc.ulPWMChannel);
     ^
analogFastWrite.c:91: error: request for member 'ulPWMChannel' in something not a structure or union
     uint32_t tcNum = GetTCNumber(pinDesc.ulPWMChannel);
                                         ^
/var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632/sketch/analogFastWrite.c:92:5: warning: implicit declaration of function 'GetTCChannelNumber' [-Wimplicit-function-declaration]
     uint8_t tcChannel = GetTCChannelNumber(pinDesc.ulPWMChannel);
     ^
analogFastWrite.c:92: error: request for member 'ulPWMChannel' in something not a structure or union
     uint8_t tcChannel = GetTCChannelNumber(pinDesc.ulPWMChannel);
                                                   ^
analogFastWrite.c:93: error: 'TCC_INST_NUM' undeclared (first use in this function)
     static bool tcEnabled[TCC_INST_NUM+TC_INST_NUM];
                           ^
analogFastWrite.c:93: error: 'TC_INST_NUM' undeclared (first use in this function)
     static bool tcEnabled[TCC_INST_NUM+TC_INST_NUM];
                                        ^
analogFastWrite.c:98: error: 'PIN_ATTR_TIMER' undeclared (first use in this function)
       if (attr & PIN_ATTR_TIMER) {
                  ^
analogFastWrite.c:101: error: request for member 'ulPinType' in something not a structure or union
         if (pinDesc.ulPinType == PIO_TIMER_ALT) {
                    ^
analogFastWrite.c:101: error: 'PIO_TIMER_ALT' undeclared (first use in this function)
         if (pinDesc.ulPinType == PIO_TIMER_ALT) {
                                  ^
/var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632/sketch/analogFastWrite.c:102:11: warning: implicit declaration of function 'pinPeripheral' [-Wimplicit-function-declaration]
           pinPeripheral(pin, PIO_TIMER_ALT);
           ^
analogFastWrite.c:106: error: 'PIO_TIMER' undeclared (first use in this function)
           pinPeripheral(pin, PIO_TIMER);
                              ^
/var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632/sketch/analogFastWrite.c:114:9: warning: implicit declaration of function 'GCLK_CLKCTRL_ID' [-Wimplicit-function-declaration]
         GCLK_CLKCTRL_ID(GCM_TCC0_TCC1), // TCC0
         ^
analogFastWrite.c:114: error: 'GCM_TCC0_TCC1' undeclared (first use in this function)
         GCLK_CLKCTRL_ID(GCM_TCC0_TCC1), // TCC0
                         ^
analogFastWrite.c:116: error: 'GCM_TCC2_TC3' undeclared (first use in this function)
         GCLK_CLKCTRL_ID(GCM_TCC2_TC3),  // TCC2
                         ^
analogFastWrite.c:118: error: 'GCM_TC4_TC5' undeclared (first use in this function)
         GCLK_CLKCTRL_ID(GCM_TC4_TC5),   // TC4
                         ^
analogFastWrite.c:120: error: 'GCM_TC6_TC7' undeclared (first use in this function)
         GCLK_CLKCTRL_ID(GCM_TC6_TC7),   // TC6
                         ^
analogFastWrite.c:123: error: 'GCLK' undeclared (first use in this function)
       GCLK->CLKCTRL.reg = (uint16_t) (GCLK_CLKCTRL_CLKEN | GCLK_CLKCTRL_GEN_GCLK0 | GCLK_CLKCTRL_IDs[tcNum]);
       ^
analogFastWrite.c:123: error: request for member 'CLKCTRL' in something not a structure or union
       GCLK->CLKCTRL.reg = (uint16_t) (GCLK_CLKCTRL_CLKEN | GCLK_CLKCTRL_GEN_GCLK0 | GCLK_CLKCTRL_IDs[tcNum]);
           ^
analogFastWrite.c:123: error: request for member 'reg' in something not a structure or union
       GCLK->CLKCTRL.reg = (uint16_t) (GCLK_CLKCTRL_CLKEN | GCLK_CLKCTRL_GEN_GCLK0 | GCLK_CLKCTRL_IDs[tcNum]);
                    ^
analogFastWrite.c:123: error: 'GCLK_CLKCTRL_CLKEN' undeclared (first use in this function)
       GCLK->CLKCTRL.reg = (uint16_t) (GCLK_CLKCTRL_CLKEN | GCLK_CLKCTRL_GEN_GCLK0 | GCLK_CLKCTRL_IDs[tcNum]);
                                       ^
analogFastWrite.c:123: error: 'GCLK_CLKCTRL_GEN_GCLK0' undeclared (first use in this function)
       GCLK->CLKCTRL.reg = (uint16_t) (GCLK_CLKCTRL_CLKEN | GCLK_CLKCTRL_GEN_GCLK0 | GCLK_CLKCTRL_IDs[tcNum]);
                                                            ^
analogFastWrite.c:123: error: invalid operands to binary | (have 'uint16_t *' and 'uint16_t *')
       GCLK->CLKCTRL.reg = (uint16_t) (GCLK_CLKCTRL_CLKEN | GCLK_CLKCTRL_GEN_GCLK0 | GCLK_CLKCTRL_IDs[tcNum]);
                                                          ^
analogFastWrite.c:123: error: invalid operands to binary | (have 'uint16_t *' and 'uint16_t')
       GCLK->CLKCTRL.reg = (uint16_t) (GCLK_CLKCTRL_CLKEN | GCLK_CLKCTRL_GEN_GCLK0 | GCLK_CLKCTRL_IDs[tcNum]);
                                                                                   ^
/var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632/sketch/analogFastWrite.c:123:7: warning: statement with no effect [-Wunused-value]
       GCLK->CLKCTRL.reg = (uint16_t) (GCLK_CLKCTRL_CLKEN | GCLK_CLKCTRL_GEN_GCLK0 | GCLK_CLKCTRL_IDs[tcNum]);
       ^
analogFastWrite.c:124: error: request for member 'STATUS' in something not a structure or union
       while (GCLK->STATUS.bit.SYNCBUSY == 1);
                  ^
analogFastWrite.c:124: error: request for member 'bit' in something not a structure or union
       while (GCLK->STATUS.bit.SYNCBUSY == 1);
                          ^
analogFastWrite.c:124: error: request for member 'SYNCBUSY' in something not a structure or union
       while (GCLK->STATUS.bit.SYNCBUSY == 1);
                              ^
/var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632/sketch/analogFastWrite.c:124:40: warning: comparison between pointer and integer
       while (GCLK->STATUS.bit.SYNCBUSY == 1);
                                        ^
/var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632/sketch/analogFastWrite.c:127:17: warning: comparison between pointer and integer
       if (tcNum >= TCC_INST_NUM) {
                 ^
analogFastWrite.c:129: error: unknown type name 'Tc'
         Tc* TCx = (Tc*) GetTC(pinDesc.ulPWMChannel);
         ^
analogFastWrite.c:129: error: 'Tc' undeclared (first use in this function)
         Tc* TCx = (Tc*) GetTC(pinDesc.ulPWMChannel);
                    ^
analogFastWrite.c:129: error: expected expression before ')' token
         Tc* TCx = (Tc*) GetTC(pinDesc.ulPWMChannel);
                       ^
analogFastWrite.c:129: error: invalid operands to binary * (have 'uint16_t *' and 'uint16_t *')
         Tc* TCx = (Tc*) GetTC(pinDesc.ulPWMChannel);
                      ^
/var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632/sketch/analogFastWrite.c:129:19: warning: pointer targets in initialization differ in signedness [-Wpointer-sign]
         Tc* TCx = (Tc*) GetTC(pinDesc.ulPWMChannel);
                   ^
analogFastWrite.c:131: error: request for member 'COUNT8' in something not a structure or union
         TCx->COUNT8.CTRLA.bit.ENABLE = 0;
            ^
analogFastWrite.c:131: error: request for member 'CTRLA' in something not a structure or union
         TCx->COUNT8.CTRLA.bit.ENABLE = 0;
                    ^
analogFastWrite.c:131: error: request for member 'bit' in something not a structure or union
         TCx->COUNT8.CTRLA.bit.ENABLE = 0;
                          ^
analogFastWrite.c:131: error: request for member 'ENABLE' in something not a structure or union
         TCx->COUNT8.CTRLA.bit.ENABLE = 0;
                              ^
/var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632/sketch/analogFastWrite.c:131:9: warning: statement with no effect [-Wunused-value]
         TCx->COUNT8.CTRLA.bit.ENABLE = 0;
         ^
/var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632/sketch/analogFastWrite.c:132:9: warning: implicit declaration of function 'syncTC_8' [-Wimplicit-function-declaration]
         syncTC_8(TCx);
         ^
analogFastWrite.c:134: error: request for member 'COUNT8' in something not a structure or union
         TCx->COUNT8.CTRLA.reg |= TC_CTRLA_MODE_COUNT8 | TC_CTRLA_WAVEGEN_NPWM;
            ^
analogFastWrite.c:134: error: request for member 'CTRLA' in something not a structure or union
         TCx->COUNT8.CTRLA.reg |= TC_CTRLA_MODE_COUNT8 | TC_CTRLA_WAVEGEN_NPWM;
                    ^
analogFastWrite.c:134: error: request for member 'reg' in something not a structure or union
         TCx->COUNT8.CTRLA.reg |= TC_CTRLA_MODE_COUNT8 | TC_CTRLA_WAVEGEN_NPWM;
                          ^
analogFastWrite.c:134: error: 'TC_CTRLA_MODE_COUNT8' undeclared (first use in this function)
         TCx->COUNT8.CTRLA.reg |= TC_CTRLA_MODE_COUNT8 | TC_CTRLA_WAVEGEN_NPWM;
                                  ^
analogFastWrite.c:134: error: 'TC_CTRLA_WAVEGEN_NPWM' undeclared (first use in this function)
         TCx->COUNT8.CTRLA.reg |= TC_CTRLA_MODE_COUNT8 | TC_CTRLA_WAVEGEN_NPWM;
                                                         ^
analogFastWrite.c:134: error: invalid operands to binary | (have 'uint16_t *' and 'uint16_t *')
         TCx->COUNT8.CTRLA.reg |= TC_CTRLA_MODE_COUNT8 | TC_CTRLA_WAVEGEN_NPWM;
                                                       ^
/var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632/sketch/analogFastWrite.c:134:9: warning: statement with no effect [-Wunused-value]
         TCx->COUNT8.CTRLA.reg |= TC_CTRLA_MODE_COUNT8 | TC_CTRLA_WAVEGEN_NPWM;
         ^
analogFastWrite.c:137: error: request for member 'COUNT8' in something not a structure or union
         TCx->COUNT8.CC[tcChannel].reg = (uint8_t) value;
            ^
analogFastWrite.c:137: error: request for member 'CC' in something not a structure or union
         TCx->COUNT8.CC[tcChannel].reg = (uint8_t) value;
                    ^
analogFastWrite.c:137: error: request for member 'reg' in something not a structure or union
         TCx->COUNT8.CC[tcChannel].reg = (uint8_t) value;
                                  ^
/var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632/sketch/analogFastWrite.c:137:9: warning: statement with no effect [-Wunused-value]
         TCx->COUNT8.CC[tcChannel].reg = (uint8_t) value;
         ^
analogFastWrite.c:140: error: request for member 'COUNT8' in something not a structure or union
         TCx->COUNT8.PER.reg = 0xFF;
            ^
analogFastWrite.c:140: error: request for member 'PER' in something not a structure or union
         TCx->COUNT8.PER.reg = 0xFF;
                    ^
analogFastWrite.c:140: error: request for member 'reg' in something not a structure or union
         TCx->COUNT8.PER.reg = 0xFF;
                        ^
/var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632/sketch/analogFastWrite.c:140:9: warning: statement with no effect [-Wunused-value]
         TCx->COUNT8.PER.reg = 0xFF;
         ^
analogFastWrite.c:143: error: request for member 'COUNT8' in something not a structure or union
         TCx->COUNT8.CTRLA.bit.ENABLE = 1;
            ^
analogFastWrite.c:143: error: request for member 'CTRLA' in something not a structure or union
         TCx->COUNT8.CTRLA.bit.ENABLE = 1;
                    ^
analogFastWrite.c:143: error: request for member 'bit' in something not a structure or union
         TCx->COUNT8.CTRLA.bit.ENABLE = 1;
                          ^
analogFastWrite.c:143: error: request for member 'ENABLE' in something not a structure or union
         TCx->COUNT8.CTRLA.bit.ENABLE = 1;
                              ^
/var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632/sketch/analogFastWrite.c:143:9: warning: statement with no effect [-Wunused-value]
         TCx->COUNT8.CTRLA.bit.ENABLE = 1;
         ^
analogFastWrite.c:147: error: unknown type name 'Tcc'
         Tcc* TCCx = (Tcc*) GetTC(pinDesc.ulPWMChannel);
         ^
analogFastWrite.c:147: error: 'Tcc' undeclared (first use in this function)
         Tcc* TCCx = (Tcc*) GetTC(pinDesc.ulPWMChannel);
                      ^
analogFastWrite.c:147: error: expected expression before ')' token
         Tcc* TCCx = (Tcc*) GetTC(pinDesc.ulPWMChannel);
                          ^
analogFastWrite.c:147: error: invalid operands to binary * (have 'uint16_t *' and 'uint16_t *')
         Tcc* TCCx = (Tcc*) GetTC(pinDesc.ulPWMChannel);
                         ^
/var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632/sketch/analogFastWrite.c:147:21: warning: pointer targets in initialization differ in signedness [-Wpointer-sign]
         Tcc* TCCx = (Tcc*) GetTC(pinDesc.ulPWMChannel);
                     ^
analogFastWrite.c:149: error: request for member 'CTRLA' in something not a structure or union
         TCCx->CTRLA.bit.ENABLE = 0;
             ^
analogFastWrite.c:149: error: request for member 'bit' in something not a structure or union
         TCCx->CTRLA.bit.ENABLE = 0;
                    ^
analogFastWrite.c:149: error: request for member 'ENABLE' in something not a structure or union
         TCCx->CTRLA.bit.ENABLE = 0;
                        ^
/var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632/sketch/analogFastWrite.c:149:9: warning: statement with no effect [-Wunused-value]
         TCCx->CTRLA.bit.ENABLE = 0;
         ^
/var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632/sketch/analogFastWrite.c:150:9: warning: implicit declaration of function 'syncTCC' [-Wimplicit-function-declaration]
         syncTCC(TCCx);
         ^
analogFastWrite.c:153: error: request for member 'WAVE' in something not a structure or union
         TCCx->WAVE.reg |= TCC_WAVE_WAVEGEN_NPWM;
             ^
analogFastWrite.c:153: error: request for member 'reg' in something not a structure or union
         TCCx->WAVE.reg |= TCC_WAVE_WAVEGEN_NPWM;
                   ^
analogFastWrite.c:153: error: 'TCC_WAVE_WAVEGEN_NPWM' undeclared (first use in this function)
         TCCx->WAVE.reg |= TCC_WAVE_WAVEGEN_NPWM;
                           ^
/var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632/sketch/analogFastWrite.c:153:9: warning: statement with no effect [-Wunused-value]
         TCCx->WAVE.reg |= TCC_WAVE_WAVEGEN_NPWM;
         ^
analogFastWrite.c:156: error: request for member 'CC' in something not a structure or union
         TCCx->CC[tcChannel].reg = (uint32_t) value;
             ^
analogFastWrite.c:156: error: request for member 'reg' in something not a structure or union
         TCCx->CC[tcChannel].reg = (uint32_t) value;
                            ^
/var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632/sketch/analogFastWrite.c:156:9: warning: statement with no effect [-Wunused-value]
         TCCx->CC[tcChannel].reg = (uint32_t) value;
         ^
analogFastWrite.c:159: error: request for member 'PER' in something not a structure or union
         TCCx->PER.reg = 0xFF; //change to 0x43FF for 10 bit... must also change mapping above
             ^
analogFastWrite.c:159: error: request for member 'reg' in something not a structure or union
         TCCx->PER.reg = 0xFF; //change to 0x43FF for 10 bit... must also change mapping above
                  ^
/var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632/sketch/analogFastWrite.c:159:9: warning: statement with no effect [-Wunused-value]
         TCCx->PER.reg = 0xFF; //change to 0x43FF for 10 bit... must also change mapping above
         ^
analogFastWrite.c:162: error: request for member 'CTRLA' in something not a structure or union
         TCCx->CTRLA.bit.ENABLE = 1;
             ^
analogFastWrite.c:162: error: request for member 'bit' in something not a structure or union
         TCCx->CTRLA.bit.ENABLE = 1;
                    ^
analogFastWrite.c:162: error: request for member 'ENABLE' in something not a structure or union
         TCCx->CTRLA.bit.ENABLE = 1;
                        ^
/var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632/sketch/analogFastWrite.c:162:9: warning: statement with no effect [-Wunused-value]
         TCCx->CTRLA.bit.ENABLE = 1;
         ^
/var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632/sketch/analogFastWrite.c:166:17: warning: comparison between pointer and integer
       if (tcNum >= TCC_INST_NUM) {
                 ^
analogFastWrite.c:167: error: 'TCx' undeclared (first use in this function)
         Tc* TCx = (Tc*) GetTC(pinDesc.ulPWMChannel);
             ^
analogFastWrite.c:167: error: invalid operands to binary * (have 'uint16_t *' and 'uint16_t *')
         Tc* TCx = (Tc*) GetTC(pinDesc.ulPWMChannel);
           ^
analogFastWrite.c:167: error: expected expression before ')' token
         Tc* TCx = (Tc*) GetTC(pinDesc.ulPWMChannel);
                       ^
analogFastWrite.c:167: error: invalid operands to binary * (have 'uint16_t *' and 'uint16_t *')
         Tc* TCx = (Tc*) GetTC(pinDesc.ulPWMChannel);
                      ^
/var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632/sketch/analogFastWrite.c:167:9: warning: statement with no effect [-Wunused-value]
         Tc* TCx = (Tc*) GetTC(pinDesc.ulPWMChannel);
         ^
analogFastWrite.c:168: error: request for member 'COUNT8' in something not a structure or union
         TCx->COUNT8.CC[tcChannel].reg = (uint8_t) value;
            ^
analogFastWrite.c:168: error: request for member 'CC' in something not a structure or union
         TCx->COUNT8.CC[tcChannel].reg = (uint8_t) value;
                    ^
analogFastWrite.c:168: error: request for member 'reg' in something not a structure or union
         TCx->COUNT8.CC[tcChannel].reg = (uint8_t) value;
                                  ^
/var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632/sketch/analogFastWrite.c:168:9: warning: statement with no effect [-Wunused-value]
         TCx->COUNT8.CC[tcChannel].reg = (uint8_t) value;
         ^
analogFastWrite.c:171: error: 'TCCx' undeclared (first use in this function)
         Tcc* TCCx = (Tcc*) GetTC(pinDesc.ulPWMChannel);
              ^
analogFastWrite.c:171: error: invalid operands to binary * (have 'uint16_t *' and 'uint16_t *')
         Tcc* TCCx = (Tcc*) GetTC(pinDesc.ulPWMChannel);
            ^
analogFastWrite.c:171: error: expected expression before ')' token
         Tcc* TCCx = (Tcc*) GetTC(pinDesc.ulPWMChannel);
                          ^
analogFastWrite.c:171: error: invalid operands to binary * (have 'uint16_t *' and 'uint16_t *')
         Tcc* TCCx = (Tcc*) GetTC(pinDesc.ulPWMChannel);
                         ^
/var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632/sketch/analogFastWrite.c:171:9: warning: statement with no effect [-Wunused-value]
         Tcc* TCCx = (Tcc*) GetTC(pinDesc.ulPWMChannel);
         ^
analogFastWrite.c:172: error: request for member 'CTRLBSET' in something not a structure or union
         TCCx->CTRLBSET.bit.LUPD = 1;
             ^
analogFastWrite.c:172: error: request for member 'bit' in something not a structure or union
         TCCx->CTRLBSET.bit.LUPD = 1;
                       ^
analogFastWrite.c:172: error: request for member 'LUPD' in something not a structure or union
         TCCx->CTRLBSET.bit.LUPD = 1;
                           ^
/var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632/sketch/analogFastWrite.c:172:9: warning: statement with no effect [-Wunused-value]
         TCCx->CTRLBSET.bit.LUPD = 1;
         ^
analogFastWrite.c:174: error: request for member 'CCB' in something not a structure or union
         TCCx->CCB[tcChannel].reg = (uint32_t) value;
             ^
analogFastWrite.c:174: error: request for member 'reg' in something not a structure or union
         TCCx->CCB[tcChannel].reg = (uint32_t) value;
                             ^
/var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632/sketch/analogFastWrite.c:174:9: warning: statement with no effect [-Wunused-value]
         TCCx->CCB[tcChannel].reg = (uint32_t) value;
         ^
analogFastWrite.c:176: error: request for member 'CTRLBCLR' in something not a structure or union
         TCCx->CTRLBCLR.bit.LUPD = 1;
             ^
analogFastWrite.c:176: error: request for member 'bit' in something not a structure or union
         TCCx->CTRLBCLR.bit.LUPD = 1;
                       ^
analogFastWrite.c:176: error: request for member 'LUPD' in something not a structure or union
         TCCx->CTRLBCLR.bit.LUPD = 1;
                           ^
/var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632/sketch/analogFastWrite.c:176:9: warning: statement with no effect [-Wunused-value]
         TCCx->CTRLBCLR.bit.LUPD = 1;
         ^
/var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632/sketch/analogFastWrite.c:93:17: warning: unused variable 'tcEnabled' [-Wunused-variable]
     static bool tcEnabled[TCC_INST_NUM+TC_INST_NUM];
                 ^
/var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632/sketch/analogFastWrite.c:67:18: warning: variable 'pinDesc' set but not used [-Wunused-but-set-variable]
   PinDescription pinDesc = g_APinDescription[pin];
                  ^
/var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632/sketch/analogFastWrite.c: At top level:
/var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632/sketch/analogFastWrite.c:10:12: warning: '_readResolution' defined but not used [-Wunused-variable]
 static int _readResolution = 10;
            ^
/var/folders/_y/wxctgwss5zv1fq27s5hw50zr0000gn/T/arduino_build_11632/sketch/analogFastWrite.c:11:12: warning: '_ADCResolution' defined but not used [-Wunused-variable]
 static int _ADCResolution = 10;
            ^
Using library SPI at version 1.0 in folder: /Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13/libraries/SPI 
Using library Wire at version 1.0 in folder: /Users/allen/Library/Arduino15/packages/arduino/hardware/avr/1.6.13/libraries/Wire 
exit status 1
invalid type argument of '->' (have 'uint16_t')
jcchurch13 commented 7 years ago

I believe you have the wrong board selected (It says Board: "Arduino/Genuino Uno"). You need to select Board: "Arduino/Genuino Zero (Native USB)". For more info, please see the getting started instruction in the Mechaduino Manual (included in repo).