Forum Rule: Always post complete source code & details to reproduce any issue!
Page 1 of 2 1 2 LastLast
Results 1 to 25 of 26

Thread: Using a Raspberry Pi Zero W to program a Teensy 3.1/3.2

  1. #1
    Senior Member pictographer's Avatar
    Join Date
    May 2013
    Location
    San Jose, CA
    Posts
    664

    Using a Raspberry Pi Zero W to program a Teensy 3.1/3.2

    I have a couple of lighting installations that are physically inconvenient to update. I never did manage to port the Teensy CLI loader to OpenWrt Linux for the host commanding the Teensy. Figured based on this post that a Raspberry Pi Zero W might be easier.

    Installed Arduino 1.8.8 with Teensyduino 1.45. Have not yet physically connected a Teensy to the RPi. Tried to compile the default sketch.
    Code:
    void setup() {  // put your setup code here, to run once:
    
    
    }
    
    
    void loop() {
      // put your main code here, to run repeatedly:
    
    
    }
    Selected Tools > Board: "Teensy 3.2 / 3.1".
    Ran Sketch > Verify/Compile
    Got the following errors:
    Code:
    In file included from /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:34:0,                 from /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/wiring.h:38,
                     from /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/WProgram.h:45,
                     from /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/Arduino.h:6,
                     from /tmp/arduino_build_415975/sketch/sketch_mar13a.ino.cpp:1:
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/kinetis.h:764:12: error: operator '==' has no left operand
     #if (F_CPU == 256000000)
                ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/kinetis.h:771:14: error: operator '==' has no left operand
     #elif (F_CPU == 240000000)
                  ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/kinetis.h:779:14: error: operator '==' has no left operand
     #elif (F_CPU == 216000000)
                  ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/kinetis.h:787:14: error: operator '==' has no left operand
     #elif (F_CPU == 192000000)
                  ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/kinetis.h:795:14: error: operator '==' has no left operand
     #elif (F_CPU == 180000000)
                  ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/kinetis.h:802:14: error: operator '==' has no left operand
     #elif (F_CPU == 168000000)
                  ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/kinetis.h:806:14: error: operator '==' has no left operand
     #elif (F_CPU == 144000000)
                  ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/kinetis.h:813:14: error: operator '==' has no left operand
     #elif (F_CPU == 120000000)
                  ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/kinetis.h:820:14: error: operator '==' has no left operand
     #elif (F_CPU == 96000000)
                  ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/kinetis.h:827:14: error: operator '==' has no left operand
     #elif (F_CPU == 72000000)
                  ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/kinetis.h:834:14: error: operator '==' has no left operand
     #elif (F_CPU == 48000000)
                  ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/kinetis.h:842:14: error: operator '==' has no left operand
     #elif (F_CPU == 24000000)
                  ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/kinetis.h:846:14: error: operator '==' has no left operand
     #elif (F_CPU == 16000000)
                  ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/kinetis.h:850:14: error: operator '==' has no left operand
     #elif (F_CPU == 8000000)
                  ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/kinetis.h:854:14: error: operator '==' has no left operand
     #elif (F_CPU == 4000000)
                  ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/kinetis.h:858:14: error: operator '==' has no left operand
     #elif (F_CPU == 2000000)
                  ^
    In file included from /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:34:0,
                     from /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/wiring.h:38,
                     from /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/WProgram.h:45,
                     from /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/Arduino.h:6,
                     from /tmp/arduino_build_415975/sketch/sketch_mar13a.ino.cpp:1:
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/kinetis.h:5736:41: error: operator '&&' has no right operand
     #if defined(HAS_KINETIS_HSRUN) && F_CPU > 120000000
                                             ^
    In file included from /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:35:0,
                     from /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/wiring.h:38,
                     from /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/WProgram.h:45,
                     from /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/Arduino.h:6,
                     from /tmp/arduino_build_415975/sketch/sketch_mar13a.ino.cpp:1:
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/pins_arduino.h:260:11: error: operator '>=' has no left operand
     #if F_CPU >= 20000000 && !defined(USB_DISABLED)
               ^
    In file included from /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/wiring.h:38:0,
                     from /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/WProgram.h:45,
                     from /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/Arduino.h:6,
                     from /tmp/arduino_build_415975/sketch/sketch_mar13a.ino.cpp:1:
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:2026:11: error: operator '==' has no left operand
     #if F_CPU == 256000000
               ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:2028:13: error: operator '==' has no left operand
     #elif F_CPU == 240000000
                 ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:2030:13: error: operator '==' has no left operand
     #elif F_CPU == 216000000
                 ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:2032:13: error: operator '==' has no left operand
     #elif F_CPU == 192000000
                 ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:2034:13: error: operator '==' has no left operand
     #elif F_CPU == 180000000
                 ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:2036:13: error: operator '==' has no left operand
     #elif F_CPU == 168000000
                 ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:2038:13: error: operator '==' has no left operand
     #elif F_CPU == 144000000
                 ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:2040:13: error: operator '==' has no left operand
     #elif F_CPU == 120000000
                 ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:2042:13: error: operator '==' has no left operand
     #elif F_CPU == 96000000
                 ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:2044:13: error: operator '==' has no left operand
     #elif F_CPU == 72000000
                 ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:2046:13: error: operator '==' has no left operand
     #elif F_CPU == 48000000
                 ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:2048:13: error: operator '==' has no left operand
     #elif F_CPU == 24000000
                 ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:2050:13: error: operator '==' has no left operand
     #elif F_CPU == 16000000
                 ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:2052:13: error: operator '==' has no left operand
     #elif F_CPU == 8000000
                 ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:2054:13: error: operator '==' has no left operand
     #elif F_CPU == 4000000
                 ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:2056:13: error: operator '==' has no left operand
     #elif F_CPU == 2000000
                 ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:2063:11: error: operator '<' has no left operand
     #if F_CPU < 24000000
               ^
    In file included from /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/WProgram.h:54:0,
                     from /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/Arduino.h:6,
                     from /tmp/arduino_build_415975/sketch/sketch_mar13a.ino.cpp:1:
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/usb_serial.h:40:11: error: operator '>=' has no left operand
     #if F_CPU >= 20000000 && !defined(USB_DISABLED)
               ^
    Error compiling for board Teensy 3.2 / 3.1.
    Last edited by pictographer; 03-17-2019 at 04:04 AM. Reason: added Teensyduino version

  2. #2
    Senior Member pictographer's Avatar
    Join Date
    May 2013
    Location
    San Jose, CA
    Posts
    664
    Verbose compiler messages:
    Code:
    Arduino: 1.8.8 (Linux), TD: 1.45, Board: "Teensy 3.2 / 3.1, Serial"
    
    /home/pi/arduino-1.8.8/arduino-builder -dump-prefs -logger=machine -hardware /home/pi/arduino-1.8.8/hardware -tools /home/pi/arduino-1.8.8/tools-builder -tools /home/pi/arduino-1.8.8/hardware/tools/avr -built-in-libraries /home/pi/arduino-1.8.8/libraries -libraries /home/pi/Arduino/libraries -fqbn=teensy:avr:teensy31:usb=serial -ide-version=10808 -build-path /tmp/arduino_build_415975 -warnings=none -build-cache /tmp/arduino_cache_436972 -verbose /tmp/untitled652039889.tmp/sketch_mar13a/sketch_mar13a.ino
    /home/pi/arduino-1.8.8/arduino-builder -compile -logger=machine -hardware /home/pi/arduino-1.8.8/hardware -tools /home/pi/arduino-1.8.8/tools-builder -tools /home/pi/arduino-1.8.8/hardware/tools/avr -built-in-libraries /home/pi/arduino-1.8.8/libraries -libraries /home/pi/Arduino/libraries -fqbn=teensy:avr:teensy31:usb=serial -ide-version=10808 -build-path /tmp/arduino_build_415975 -warnings=none -build-cache /tmp/arduino_cache_436972 -verbose /tmp/untitled652039889.tmp/sketch_mar13a/sketch_mar13a.ino
    Using board 'teensy31' from platform in folder: /home/pi/arduino-1.8.8/hardware/teensy/avr
    Using core 'teensy3' from platform in folder: /home/pi/arduino-1.8.8/hardware/teensy/avr
    Build options changed, rebuilding all
    Detecting libraries used...
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/arm/bin/arm-none-eabi-g++ -E -CC -x c++ -w -g -Wall -ffunction-sections -fdata-sections -nostdlib -fno-exceptions -felide-constructors -std=gnu++14 -Wno-error=narrowing -fno-rtti -mthumb -mcpu=cortex-m4 -fsingle-precision-constant -D__MK20DX256__ -DTEENSYDUINO=145 -DARDUINO=10808 -DF_CPU= -DUSB_SERIAL -DLAYOUT_ -I/home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3 /tmp/arduino_build_415975/sketch/sketch_mar13a.ino.cpp -o /dev/null
    Error while detecting libraries included by /tmp/arduino_build_415975/sketch/sketch_mar13a.ino.cpp
    Generating function prototypes...
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/arm/bin/arm-none-eabi-g++ -E -CC -x c++ -w -g -Wall -ffunction-sections -fdata-sections -nostdlib -fno-exceptions -felide-constructors -std=gnu++14 -Wno-error=narrowing -fno-rtti -mthumb -mcpu=cortex-m4 -fsingle-precision-constant -D__MK20DX256__ -DTEENSYDUINO=145 -DARDUINO=10808 -DF_CPU= -DUSB_SERIAL -DLAYOUT_ -I/home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3 /tmp/arduino_build_415975/sketch/sketch_mar13a.ino.cpp -o /tmp/arduino_build_415975/preproc/ctags_target_for_gcc_minus_e.cpp
    In file included from /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:34:0,
                     from /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/wiring.h:38,
                     from /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/WProgram.h:45,
                     from /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/Arduino.h:6,
                     from /tmp/arduino_build_415975/sketch/sketch_mar13a.ino.cpp:1:
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/kinetis.h:764:12: error: operator '==' has no left operand
     #if (F_CPU == 256000000)
                ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/kinetis.h:771:14: error: operator '==' has no left operand
     #elif (F_CPU == 240000000)
                  ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/kinetis.h:779:14: error: operator '==' has no left operand
     #elif (F_CPU == 216000000)
                  ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/kinetis.h:787:14: error: operator '==' has no left operand
     #elif (F_CPU == 192000000)
                  ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/kinetis.h:795:14: error: operator '==' has no left operand
     #elif (F_CPU == 180000000)
                  ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/kinetis.h:802:14: error: operator '==' has no left operand
     #elif (F_CPU == 168000000)
                  ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/kinetis.h:806:14: error: operator '==' has no left operand
     #elif (F_CPU == 144000000)
                  ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/kinetis.h:813:14: error: operator '==' has no left operand
     #elif (F_CPU == 120000000)
                  ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/kinetis.h:820:14: error: operator '==' has no left operand
     #elif (F_CPU == 96000000)
                  ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/kinetis.h:827:14: error: operator '==' has no left operand
     #elif (F_CPU == 72000000)
                  ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/kinetis.h:834:14: error: operator '==' has no left operand
     #elif (F_CPU == 48000000)
                  ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/kinetis.h:842:14: error: operator '==' has no left operand
     #elif (F_CPU == 24000000)
                  ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/kinetis.h:846:14: error: operator '==' has no left operand
     #elif (F_CPU == 16000000)
                  ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/kinetis.h:850:14: error: operator '==' has no left operand
     #elif (F_CPU == 8000000)
                  ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/kinetis.h:854:14: error: operator '==' has no left operand
     #elif (F_CPU == 4000000)
                  ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/kinetis.h:858:14: error: operator '==' has no left operand
     #elif (F_CPU == 2000000)
                  ^
    In file included from /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:34:0,
                     from /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/wiring.h:38,
                     from /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/WProgram.h:45,
                     from /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/Arduino.h:6,
                     from /tmp/arduino_build_415975/sketch/sketch_mar13a.ino.cpp:1:
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/kinetis.h:5736:41: error: operator '&&' has no right operand
     #if defined(HAS_KINETIS_HSRUN) && F_CPU > 120000000
                                             ^
    In file included from /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:35:0,
                     from /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/wiring.h:38,
                     from /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/WProgram.h:45,
                     from /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/Arduino.h:6,
                     from /tmp/arduino_build_415975/sketch/sketch_mar13a.ino.cpp:1:
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/pins_arduino.h:260:11: error: operator '>=' has no left operand
     #if F_CPU >= 20000000 && !defined(USB_DISABLED)
               ^
    In file included from /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/wiring.h:38:0,
                     from /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/WProgram.h:45,
                     from /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/Arduino.h:6,
                     from /tmp/arduino_build_415975/sketch/sketch_mar13a.ino.cpp:1:
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:2026:11: error: operator '==' has no left operand
     #if F_CPU == 256000000
               ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:2028:13: error: operator '==' has no left operand
     #elif F_CPU == 240000000
                 ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:2030:13: error: operator '==' has no left operand
     #elif F_CPU == 216000000
                 ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:2032:13: error: operator '==' has no left operand
     #elif F_CPU == 192000000
                 ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:2034:13: error: operator '==' has no left operand
     #elif F_CPU == 180000000
                 ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:2036:13: error: operator '==' has no left operand
     #elif F_CPU == 168000000
                 ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:2038:13: error: operator '==' has no left operand
     #elif F_CPU == 144000000
                 ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:2040:13: error: operator '==' has no left operand
     #elif F_CPU == 120000000
                 ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:2042:13: error: operator '==' has no left operand
     #elif F_CPU == 96000000
                 ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:2044:13: error: operator '==' has no left operand
     #elif F_CPU == 72000000
                 ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:2046:13: error: operator '==' has no left operand
     #elif F_CPU == 48000000
                 ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:2048:13: error: operator '==' has no left operand
     #elif F_CPU == 24000000
                 ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:2050:13: error: operator '==' has no left operand
     #elif F_CPU == 16000000
                 ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:2052:13: error: operator '==' has no left operand
     #elif F_CPU == 8000000
                 ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:2054:13: error: operator '==' has no left operand
     #elif F_CPU == 4000000
                 ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:2056:13: error: operator '==' has no left operand
     #elif F_CPU == 2000000
                 ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:2063:11: error: operator '<' has no left operand
     #if F_CPU < 24000000
               ^
    In file included from /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/WProgram.h:54:0,
                     from /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/Arduino.h:6,
                     from /tmp/arduino_build_415975/sketch/sketch_mar13a.ino.cpp:1:
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/usb_serial.h:40:11: error: operator '>=' has no left operand
     #if F_CPU >= 20000000 && !defined(USB_DISABLED)
               ^
    Error compiling for board Teensy 3.2 / 3.1.

  3. #3
    Senior Member+ defragster's Avatar
    Join Date
    Feb 2015
    Posts
    10,059
    >> Can you try with new Beta TD_1.46?

    The problem is here ::
    -DTEENSYDUINO=145 -DARDUINO=10808 -DF_CPU= -DUSB_SERIAL -DLAYOUT_
    <edit>: Also missing the language string -

    Can you upload the boards.txt from that machine?

    That looks like a battle I had getting Compile.cmd to work on Beta T4.

    Should be like :
    -DTEENSYDUINO=146 -DARDUINO=10600 -DF_CPU=396000000 -DUSB_SERIAL -DLAYOUT_US_ENGLISH
    <edit #2> : comparing to a non-rasPi boards.txt may show a section missing or oddly named versus
    Last edited by defragster; 03-17-2019 at 05:07 AM.

  4. #4
    Senior Member pictographer's Avatar
    Join Date
    May 2013
    Location
    San Jose, CA
    Posts
    664
    Success, though somewhat rough. Thanks for responding, Defragster.

    The boards.txt is unmodified from the installation. See attached.

    Attaching a Teensy 3.0 allows me to get farther. Tools > Get Board Info works. The port menu updated and I selected Port: "/dev/ttyACM0 (Teensy)". I switched to a Teensy 3.0 because I had one ready to hand. It seems that Teensyduino got the settings it needed after querying the board.

    Unfortunately, the Teensy loader application comes up as a blank window and won't update the Teensy without a button press. I did get a progress bar and it uploaded firmware. It redrew the Teensy loader, but after the progress bar disappeared, it didn't update that part of the display.

    Regarding the window manager and OS, I followed the Ada Fruit Raspberry Pi Zero Headless Quick Start but I needed to install more stuff to make VNC and X11 work.

    I can confirm as others have noted that the Raspberry Pi Zero W is indeed very sluggish running the Arduino IDE and running a desktop VNC session.

    I haven't tried the Teensyduino Beta yet. It will probably take me a week to get to it.

    Ultimately, I do not need the IDE on the Raspberry Pi. I tried it as a proof of concept. All I need the Raspberry Pi to do is enable me to wirelessly update Teensy. I plan to build the hex on a faster computer, scp it over to the RPi, and run the Teensy command line loader on the RPi.
    Attached Files Attached Files

  5. #5
    Senior Member+ defragster's Avatar
    Join Date
    Feb 2015
    Posts
    10,059
    <EDIT>:: Just looked at the boards.txt for the 1.46b10 install and those lines exists there too. And I did build with that for a T_3.2 so that likely isn't it ? - but they only exist there for some - possibly great - reason.

    This section looks out of place - and doesn't exist for other boards:
    Code:
    teensy31.menu.keys.usint.build.keylayout=US_INTERNATIONAL
    
    teensy31.vid.0=0x16C0
    teensy31.vid.1=0x16C0
    teensy31.vid.2=0x16C0
    teensy31.vid.3=0x16C0
    teensy31.vid.4=0x16C0
    teensy31.pid.0=0x0483
    teensy31.pid.1=0x0487
    teensy31.pid.2=0x0489
    teensy31.pid.3=0x048A
    teensy31.pid.4=0x0476
    
    teensy30.name=Teensy 3.0
    It may be fixed in the current newest build - or may still need to be.

    Maybe if those 'vid' and 'pid' lines are removed it will work?

    Get the newest current 1.46 beta 10 release installed and try again - if broken still posting on that thread will make sure Paul gives it a look.
    Last edited by defragster; 03-17-2019 at 08:44 AM.

  6. #6
    Senior Member+ defragster's Avatar
    Join Date
    Feb 2015
    Posts
    10,059
    @pictographer - just read the rest of your post - jumped from the start to boards.txt download. Interesting to know it works for T_3.0 - even if not well. A verify build should work on any Board - and not torment the TeensyLoader - maybe when you add the Beta 10 and have a DAY free.

    I wonder if it will build and run TyCommander/TyCmd? I put WSL - Windows Subsystem 4 Linux on my machine and followed his Linux ubuntu build steps and got a working binary - except USB is apparently not passed through in an expected/normal way so it never sees any boards - GUI or CMDLine. Not sure how it may relate but I did do the Teensy Rules. WSL is by design CmdLine only - though xMing did get the GUI up - not sure what would happen with the IDE - and it couldn't see the devices likely either and it was for something else so I didn't try.

    I don't suppose you have any particular Script Foo skillz? Frank made a nice batch file to run the Arduino builder on Windows - and I tweaked it with some added .bat prompts to machine edit rather than hand edit - seems similar 'should' work on Linux - but not by me with what I found so far.

  7. #7
    Senior Member PaulStoffregen's Avatar
    Join Date
    Nov 2012
    Posts
    20,753
    Looks like something is going wrong with F_CPU. It's supposed to be defined by the compiler commands.

    In Arduino, use File > Preferences to turn on verbose info while compiling. Then the IDE will print a *ton* of info. We need to see those compiler commands it prints, to get an idea of what's going wrong here.

  8. #8
    Senior Member pictographer's Avatar
    Join Date
    May 2013
    Location
    San Jose, CA
    Posts
    664
    The F_CPU issue appears to be a first-time thing. I haven't been able to recreate it since plugging in a Teensy. To recap, I think there's an issue trying to build Teensy firmware without a Teensy available on Raspberry Pi. There are UI issues with redraw that have persisted across my experiments. It would be good if I could program the Teensys without manually pushing the program button, but that's probably a conversation for another thread if the problem persists after I switch to the command line loader.

    My second post in this thread has the verbose compile info for a Teensy 3.0. Here's the verbose compile info for a Teensy 3.2 and I've also cranked up the compiler warnings, for what it's worth. This is the output from the blink sketch:
    Code:
    /home/pi/arduino-1.8.8/arduino-builder -dump-prefs -logger=machine -hardware /home/pi/arduino-1.8.8/hardware -tools /home/pi/arduino-1.8.8/tools-builder -tools /home/pi/arduino-1.8.8/hardware/tools/avr -built-in-libraries /home/pi/arduino-1.8.8/libraries -libraries /home/pi/Arduino/libraries -fqbn=teensy:avr:teensy31:usb=serial,speed=96,opt=o2std,keys=en-us -vid-pid=0X16C0_0X0483 -ide-version=10808 -build-path /tmp/arduino_build_861574 -warnings=all -build-cache /tmp/arduino_cache_246245 -verbose /home/pi/arduino-1.8.8/examples/Teensy/Tutorial1/Blink/Blink.pde
    /home/pi/arduino-1.8.8/arduino-builder -compile -logger=machine -hardware /home/pi/arduino-1.8.8/hardware -tools /home/pi/arduino-1.8.8/tools-builder -tools /home/pi/arduino-1.8.8/hardware/tools/avr -built-in-libraries /home/pi/arduino-1.8.8/libraries -libraries /home/pi/Arduino/libraries -fqbn=teensy:avr:teensy31:usb=serial,speed=96,opt=o2std,keys=en-us -vid-pid=0X16C0_0X0483 -ide-version=10808 -build-path /tmp/arduino_build_861574 -warnings=all -build-cache /tmp/arduino_cache_246245 -verbose /home/pi/arduino-1.8.8/examples/Teensy/Tutorial1/Blink/Blink.pde
    Using board 'teensy31' from platform in folder: /home/pi/arduino-1.8.8/hardware/teensy/avr
    Using core 'teensy3' from platform in folder: /home/pi/arduino-1.8.8/hardware/teensy/avr
    Detecting libraries used...
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/arm/bin/arm-none-eabi-g++ -E -CC -x c++ -w -g -Wall -ffunction-sections -fdata-sections -nostdlib -fno-exceptions -felide-constructors -std=gnu++14 -Wno-error=narrowing -fno-rtti -mthumb -mcpu=cortex-m4 -fsingle-precision-constant -D__MK20DX256__ -DTEENSYDUINO=145 -DARDUINO=10808 -DF_CPU=96000000 -DUSB_SERIAL -DLAYOUT_US_ENGLISH -I/home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3 /tmp/arduino_build_861574/sketch/Blink.pde.cpp -o /dev/null
    Generating function prototypes...
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/arm/bin/arm-none-eabi-g++ -E -CC -x c++ -w -g -Wall -ffunction-sections -fdata-sections -nostdlib -fno-exceptions -felide-constructors -std=gnu++14 -Wno-error=narrowing -fno-rtti -mthumb -mcpu=cortex-m4 -fsingle-precision-constant -D__MK20DX256__ -DTEENSYDUINO=145 -DARDUINO=10808 -DF_CPU=96000000 -DUSB_SERIAL -DLAYOUT_US_ENGLISH -I/home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3 /tmp/arduino_build_861574/sketch/Blink.pde.cpp -o /tmp/arduino_build_861574/preproc/ctags_target_for_gcc_minus_e.cpp
    /home/pi/arduino-1.8.8/tools-builder/ctags/5.8-arduino11/ctags -u --language-force=c++ -f - --c++-kinds=svpf --fields=KSTtzns --line-directives /tmp/arduino_build_861574/preproc/ctags_target_for_gcc_minus_e.cpp
    Compiling sketch...
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/precompile_helper /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3 /tmp/arduino_build_861574 /home/pi/arduino-1.8.8/hardware/teensy/../tools/arm/bin/arm-none-eabi-g++ -x c++-header -O2 -g -Wall -ffunction-sections -fdata-sections -nostdlib -MMD -fno-exceptions -felide-constructors -std=gnu++14 -Wno-error=narrowing -fno-rtti -mthumb -mcpu=cortex-m4 -fsingle-precision-constant -D__MK20DX256__ -DTEENSYDUINO=145 -DARDUINO=10808 -DF_CPU=96000000 -DUSB_SERIAL -DLAYOUT_US_ENGLISH -I/home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3 /tmp/arduino_build_861574/pch/Arduino.h -o /tmp/arduino_build_861574/pch/Arduino.h.gch
    Using previously compiled file: /tmp/arduino_build_861574/pch/Arduino.h.gch
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/arm/bin/arm-none-eabi-g++ -c -O2 -g -Wall -ffunction-sections -fdata-sections -nostdlib -MMD -fno-exceptions -felide-constructors -std=gnu++14 -Wno-error=narrowing -fno-rtti -mthumb -mcpu=cortex-m4 -fsingle-precision-constant -D__MK20DX256__ -DTEENSYDUINO=145 -DARDUINO=10808 -DF_CPU=96000000 -DUSB_SERIAL -DLAYOUT_US_ENGLISH -I/tmp/arduino_build_861574/pch -I/home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3 /tmp/arduino_build_861574/sketch/Blink.pde.cpp -o /tmp/arduino_build_861574/sketch/Blink.pde.cpp.o
    Compiling libraries...
    Compiling core...
    Using precompiled core: /tmp/arduino_cache_246245/core/core_teensy_avr_teensy31_usb_serial,speed_96,opt_o2std,keys_en-us_4405c7511dcfb8c33750f4a4e34a4474.a
    Linking everything together...
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/arm/bin/arm-none-eabi-gcc -O2 -Wl,--gc-sections,--relax,--defsym=__rtc_localtime=1552847436 -T/home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/mk20dx256.ld -lstdc++ -mthumb -mcpu=cortex-m4 -fsingle-precision-constant -o /tmp/arduino_build_861574/Blink.pde.elf /tmp/arduino_build_861574/sketch/Blink.pde.cpp.o /tmp/arduino_build_861574/../arduino_cache_246245/core/core_teensy_avr_teensy31_usb_serial,speed_96,opt_o2std,keys_en-us_4405c7511dcfb8c33750f4a4e34a4474.a -L/tmp/arduino_build_861574 -larm_cortexM4l_math -lm
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/arm/bin/arm-none-eabi-objcopy -O ihex -j .eeprom --set-section-flags=.eeprom=alloc,load --no-change-warnings --change-section-lma .eeprom=0 /tmp/arduino_build_861574/Blink.pde.elf /tmp/arduino_build_861574/Blink.pde.eep
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/arm/bin/arm-none-eabi-objcopy -O ihex -R .eeprom /tmp/arduino_build_861574/Blink.pde.elf /tmp/arduino_build_861574/Blink.pde.hex
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/stdout_redirect /tmp/arduino_build_861574/Blink.pde.lst /home/pi/arduino-1.8.8/hardware/teensy/../tools/arm/bin/arm-none-eabi-objdump -d -S -C /tmp/arduino_build_861574/Blink.pde.elf
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/stdout_redirect /tmp/arduino_build_861574/Blink.pde.sym /home/pi/arduino-1.8.8/hardware/teensy/../tools/arm/bin/arm-none-eabi-objdump -t -C /tmp/arduino_build_861574/Blink.pde.elf
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/teensy_post_compile -file=Blink.pde -path=/tmp/arduino_build_861574 -tools=/home/pi/arduino-1.8.8/hardware/teensy/../tools/ -board=TEENSY31
    Opening Teensy Loader...
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/arm/bin/arm-none-eabi-size -A /tmp/arduino_build_861574/Blink.pde.elf
    Sketch uses 9364 bytes (3%) of program storage space. Maximum is 262144 bytes.
    Global variables use 3436 bytes (5%) of dynamic memory, leaving 62100 bytes for local variables. Maximum is 65536 bytes.
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/teensy_post_compile -file=Blink.pde -path=/tmp/arduino_build_861574 -tools=/home/pi/arduino-1.8.8/hardware/teensy/../tools -board=TEENSY31 -reboot -port=/dev/ttyACM0 -portlabel=/dev/ttyACM0 (Teensy) -portprotocol=serial
    When I have no Teensy plugged in, the Verify option now behaves more like I'd expect. No F_CPU errors.
    Code:
    Arduino: 1.8.8 (Linux), TD: 1.45, Board: "Teensy 3.2 / 3.1, Serial, 96 MHz (overclock), Faster, US English"
    
    
    /home/pi/arduino-1.8.8/arduino-builder -dump-prefs -logger=machine -hardware /home/pi/arduino-1.8.8/hardware -tools /home/pi/arduino-1.8.8/tools-builder -tools /home/pi/arduino-1.8.8/hardware/tools/avr -built-in-libraries /home/pi/arduino-1.8.8/libraries -libraries /home/pi/Arduino/libraries -fqbn=teensy:avr:teensy31:usb=serial,speed=96,opt=o2std,keys=en-us -ide-version=10808 -build-path /tmp/arduino_build_880247 -warnings=all -build-cache /tmp/arduino_cache_246245 -verbose /home/pi/arduino-1.8.8/examples/Teensy/Tutorial3/HelloSerialMonitor/HelloSerialMonitor.pde
    /home/pi/arduino-1.8.8/arduino-builder -compile -logger=machine -hardware /home/pi/arduino-1.8.8/hardware -tools /home/pi/arduino-1.8.8/tools-builder -tools /home/pi/arduino-1.8.8/hardware/tools/avr -built-in-libraries /home/pi/arduino-1.8.8/libraries -libraries /home/pi/Arduino/libraries -fqbn=teensy:avr:teensy31:usb=serial,speed=96,opt=o2std,keys=en-us -ide-version=10808 -build-path /tmp/arduino_build_880247 -warnings=all -build-cache /tmp/arduino_cache_246245 -verbose /home/pi/arduino-1.8.8/examples/Teensy/Tutorial3/HelloSerialMonitor/HelloSerialMonitor.pde
    Using board 'teensy31' from platform in folder: /home/pi/arduino-1.8.8/hardware/teensy/avr
    Using core 'teensy3' from platform in folder: /home/pi/arduino-1.8.8/hardware/teensy/avr
    Unable find Teensy Loader.  (p)  Is the Teensy Loader application running?
    quitexit status 1
    Error compiling for board Teensy 3.2 / 3.1.
    Detecting libraries used...
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/arm/bin/arm-none-eabi-g++ -E -CC -x c++ -w -g -Wall -ffunction-sections -fdata-sections -nostdlib -fno-exceptions -felide-constructors -std=gnu++14 -Wno-error=narrowing -fno-rtti -mthumb -mcpu=cortex-m4 -fsingle-precision-constant -D__MK20DX256__ -DTEENSYDUINO=145 -DARDUINO=10808 -DF_CPU=96000000 -DUSB_SERIAL -DLAYOUT_US_ENGLISH -I/home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3 /tmp/arduino_build_880247/sketch/HelloSerialMonitor.pde.cpp -o /dev/null
    Generating function prototypes...
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/arm/bin/arm-none-eabi-g++ -E -CC -x c++ -w -g -Wall -ffunction-sections -fdata-sections -nostdlib -fno-exceptions -felide-constructors -std=gnu++14 -Wno-error=narrowing -fno-rtti -mthumb -mcpu=cortex-m4 -fsingle-precision-constant -D__MK20DX256__ -DTEENSYDUINO=145 -DARDUINO=10808 -DF_CPU=96000000 -DUSB_SERIAL -DLAYOUT_US_ENGLISH -I/home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3 /tmp/arduino_build_880247/sketch/HelloSerialMonitor.pde.cpp -o /tmp/arduino_build_880247/preproc/ctags_target_for_gcc_minus_e.cpp
    /home/pi/arduino-1.8.8/tools-builder/ctags/5.8-arduino11/ctags -u --language-force=c++ -f - --c++-kinds=svpf --fields=KSTtzns --line-directives /tmp/arduino_build_880247/preproc/ctags_target_for_gcc_minus_e.cpp
    Compiling sketch...
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/precompile_helper /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3 /tmp/arduino_build_880247 /home/pi/arduino-1.8.8/hardware/teensy/../tools/arm/bin/arm-none-eabi-g++ -x c++-header -O2 -g -Wall -ffunction-sections -fdata-sections -nostdlib -MMD -fno-exceptions -felide-constructors -std=gnu++14 -Wno-error=narrowing -fno-rtti -mthumb -mcpu=cortex-m4 -fsingle-precision-constant -D__MK20DX256__ -DTEENSYDUINO=145 -DARDUINO=10808 -DF_CPU=96000000 -DUSB_SERIAL -DLAYOUT_US_ENGLISH -I/home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3 /tmp/arduino_build_880247/pch/Arduino.h -o /tmp/arduino_build_880247/pch/Arduino.h.gch
    Using previously compiled file: /tmp/arduino_build_880247/pch/Arduino.h.gch
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/arm/bin/arm-none-eabi-g++ -c -O2 -g -Wall -ffunction-sections -fdata-sections -nostdlib -MMD -fno-exceptions -felide-constructors -std=gnu++14 -Wno-error=narrowing -fno-rtti -mthumb -mcpu=cortex-m4 -fsingle-precision-constant -D__MK20DX256__ -DTEENSYDUINO=145 -DARDUINO=10808 -DF_CPU=96000000 -DUSB_SERIAL -DLAYOUT_US_ENGLISH -I/tmp/arduino_build_880247/pch -I/home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3 /tmp/arduino_build_880247/sketch/HelloSerialMonitor.pde.cpp -o /tmp/arduino_build_880247/sketch/HelloSerialMonitor.pde.cpp.o
    Compiling libraries...
    Compiling core...
    Using precompiled core: /tmp/arduino_cache_246245/core/core_teensy_avr_teensy31_usb_serial,speed_96,opt_o2std,keys_en-us_4405c7511dcfb8c33750f4a4e34a4474.a
    Linking everything together...
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/arm/bin/arm-none-eabi-gcc -O2 -Wl,--gc-sections,--relax,--defsym=__rtc_localtime=1552847914 -T/home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/mk20dx256.ld -lstdc++ -mthumb -mcpu=cortex-m4 -fsingle-precision-constant -o /tmp/arduino_build_880247/HelloSerialMonitor.pde.elf /tmp/arduino_build_880247/sketch/HelloSerialMonitor.pde.cpp.o /tmp/arduino_build_880247/../arduino_cache_246245/core/core_teensy_avr_teensy31_usb_serial,speed_96,opt_o2std,keys_en-us_4405c7511dcfb8c33750f4a4e34a4474.a -L/tmp/arduino_build_880247 -larm_cortexM4l_math -lm
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/arm/bin/arm-none-eabi-objcopy -O ihex -j .eeprom --set-section-flags=.eeprom=alloc,load --no-change-warnings --change-section-lma .eeprom=0 /tmp/arduino_build_880247/HelloSerialMonitor.pde.elf /tmp/arduino_build_880247/HelloSerialMonitor.pde.eep
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/arm/bin/arm-none-eabi-objcopy -O ihex -R .eeprom /tmp/arduino_build_880247/HelloSerialMonitor.pde.elf /tmp/arduino_build_880247/HelloSerialMonitor.pde.hex
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/stdout_redirect /tmp/arduino_build_880247/HelloSerialMonitor.pde.lst /home/pi/arduino-1.8.8/hardware/teensy/../tools/arm/bin/arm-none-eabi-objdump -d -S -C /tmp/arduino_build_880247/HelloSerialMonitor.pde.elf
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/stdout_redirect /tmp/arduino_build_880247/HelloSerialMonitor.pde.sym /home/pi/arduino-1.8.8/hardware/teensy/../tools/arm/bin/arm-none-eabi-objdump -t -C /tmp/arduino_build_880247/HelloSerialMonitor.pde.elf
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/teensy_post_compile -file=HelloSerialMonitor.pde -path=/tmp/arduino_build_880247 -tools=/home/pi/arduino-1.8.8/hardware/teensy/../tools/ -board=TEENSY31
    Opening Teensy Loader...
    Unable find Teensy Loader.  (p)  Is the Teensy Loader application running?

  9. #9
    Senior Member+ KurtE's Avatar
    Join Date
    Jan 2014
    Posts
    5,689
    As mentioned in other threads, another option is to build on another computer and then transfer the binary to RPI and then use the tens loader app on the pi.

    I was doing this earlier on RPI to program OpenCM boards, where I had a hacked up setup (boards.txt,...), that had upload using Wi-Fi, and setup a connection where this would copy the file to RPI, where there was a script running that checked for changed file, and would run their upload program... sort of like the Edison used to do. Wish to someday do similar for teensy

  10. #10
    Senior Member pictographer's Avatar
    Join Date
    May 2013
    Location
    San Jose, CA
    Posts
    664
    Was able to recreate the F_CPU error with a Teensy 3.2 plugged in and after invoking Get Board Info. The key was to run it again from a new user account. So there's definitely an initial state bug of some kind on the RPi build. Haven't been able to make the problem go away on the new account yet.

    Meanwhile, got tycommander running. Very nice work, Koromix!

    Opening an example with a Teensy 3.2 connected (as a different user than before. Before I was signed in as pi. Now I'm corbett.):

    Code:
    Exception in thread "AWT-EventQueue-0" java.lang.NullPointerException
        at processing.app.EditorLineStatus.setSerialPort(EditorLineStatus.java:136)
        at processing.app.EditorLineStatus.paintComponent(EditorLineStatus.java:101)
        at javax.swing.JComponent.paint(JComponent.java:1056)
        at javax.swing.JComponent.paintChildren(JComponent.java:889)
        at javax.swing.JComponent.paint(JComponent.java:1065)
        at javax.swing.JComponent.paintChildren(JComponent.java:889)
        at javax.swing.JSplitPane.paintChildren(JSplitPane.java:1047)
        at javax.swing.JComponent.paint(JComponent.java:1065)
        at javax.swing.JComponent.paintChildren(JComponent.java:889)
        at javax.swing.JComponent.paint(JComponent.java:1065)
        at javax.swing.JComponent.paintChildren(JComponent.java:889)
        at javax.swing.JComponent.paint(JComponent.java:1065)
        at javax.swing.JComponent.paintChildren(JComponent.java:889)
        at javax.swing.JComponent.paint(JComponent.java:1065)
        at javax.swing.JComponent.paintChildren(JComponent.java:889)
        at javax.swing.JComponent.paint(JComponent.java:1065)
        at javax.swing.JLayeredPane.paint(JLayeredPane.java:586)
        at javax.swing.JComponent.paintChildren(JComponent.java:889)
        at javax.swing.JComponent.paintToOffscreen(JComponent.java:5217)
        at javax.swing.RepaintManager$PaintManager.paintDoubleBuffered(RepaintManager.java:1579)
        at javax.swing.RepaintManager$PaintManager.paint(RepaintManager.java:1502)
        at javax.swing.BufferStrategyPaintManager.paint(BufferStrategyPaintManager.java:306)
        at javax.swing.RepaintManager.paint(RepaintManager.java:1272)
        at javax.swing.JComponent.paint(JComponent.java:1042)
        at java.awt.GraphicsCallback$PaintCallback.run(GraphicsCallback.java:39)
        at sun.awt.SunGraphicsCallback.runOneComponent(SunGraphicsCallback.java:79)
        at sun.awt.SunGraphicsCallback.runComponents(SunGraphicsCallback.java:116)
        at java.awt.Container.paint(Container.java:1978)
        at java.awt.Window.paint(Window.java:3906)
        at javax.swing.RepaintManager$4.run(RepaintManager.java:842)
        at javax.swing.RepaintManager$4.run(RepaintManager.java:814)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:74)
        at javax.swing.RepaintManager.paintDirtyRegions(RepaintManager.java:814)
        at javax.swing.RepaintManager.paintDirtyRegions(RepaintManager.java:789)
        at javax.swing.RepaintManager.prePaintDirtyRegions(RepaintManager.java:738)
        at javax.swing.RepaintManager.access$1200(RepaintManager.java:64)
        at javax.swing.RepaintManager$ProcessingRunnable.run(RepaintManager.java:1732)
        at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:311)
        at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:758)
        at java.awt.EventQueue.access$500(EventQueue.java:97)
        at java.awt.EventQueue$3.run(EventQueue.java:709)
        at java.awt.EventQueue$3.run(EventQueue.java:703)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:74)
        at java.awt.EventQueue.dispatchEvent(EventQueue.java:728)
        at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:205)
        at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:116)
        at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:105)
        at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101)
        at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:93)
        at java.awt.EventDispatchThread.run(EventDispatchThread.java:82)
    As a new user with a Teensy 3.2 connected. Haven't run board info.
    Attempting to compile Hello Serial Monitor.

    Code:
    Arduino: 1.8.8 (Linux), TD: 1.45, Board: "Teensy 3.2 / 3.1, Serial"
    
    
    In file included from /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:34:0,
                     from /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/wiring.h:38,
                     from /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/WProgram.h:45,
                     from /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/Arduino.h:6,
                     from /tmp/arduino_build_95914/sketch/HelloSerialMonitor.ino.cpp:1:
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/kinetis.h:764:12: error: operator '==' has no left operand
     #if (F_CPU == 256000000)
                ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/kinetis.h:771:14: error: operator '==' has no left operand
     #elif (F_CPU == 240000000)
                  ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/kinetis.h:779:14: error: operator '==' has no left operand
     #elif (F_CPU == 216000000)
                  ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/kinetis.h:787:14: error: operator '==' has no left operand
     #elif (F_CPU == 192000000)
                  ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/kinetis.h:795:14: error: operator '==' has no left operand
     #elif (F_CPU == 180000000)
                  ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/kinetis.h:802:14: error: operator '==' has no left operand
     #elif (F_CPU == 168000000)
                  ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/kinetis.h:806:14: error: operator '==' has no left operand
     #elif (F_CPU == 144000000)
                  ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/kinetis.h:813:14: error: operator '==' has no left operand
     #elif (F_CPU == 120000000)
                  ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/kinetis.h:820:14: error: operator '==' has no left operand
     #elif (F_CPU == 96000000)
                  ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/kinetis.h:827:14: error: operator '==' has no left operand
     #elif (F_CPU == 72000000)
                  ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/kinetis.h:834:14: error: operator '==' has no left operand
     #elif (F_CPU == 48000000)
                  ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/kinetis.h:842:14: error: operator '==' has no left operand
     #elif (F_CPU == 24000000)
                  ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/kinetis.h:846:14: error: operator '==' has no left operand
     #elif (F_CPU == 16000000)
                  ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/kinetis.h:850:14: error: operator '==' has no left operand
     #elif (F_CPU == 8000000)
                  ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/kinetis.h:854:14: error: operator '==' has no left operand
     #elif (F_CPU == 4000000)
                  ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/kinetis.h:858:14: error: operator '==' has no left operand
     #elif (F_CPU == 2000000)
                  ^
    In file included from /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:34:0,
                     from /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/wiring.h:38,
                     from /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/WProgram.h:45,
                     from /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/Arduino.h:6,
                     from /tmp/arduino_build_95914/sketch/HelloSerialMonitor.ino.cpp:1:
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/kinetis.h:5736:41: error: operator '&&' has no right operand
     #if defined(HAS_KINETIS_HSRUN) && F_CPU > 120000000
                                             ^
    In file included from /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:35:0,
                     from /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/wiring.h:38,
                     from /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/WProgram.h:45,
                     from /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/Arduino.h:6,
                     from /tmp/arduino_build_95914/sketch/HelloSerialMonitor.ino.cpp:1:
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/pins_arduino.h:260:11: error: operator '>=' has no left operand
     #if F_CPU >= 20000000 && !defined(USB_DISABLED)
               ^
    In file included from /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/wiring.h:38:0,
                     from /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/WProgram.h:45,
                     from /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/Arduino.h:6,
                     from /tmp/arduino_build_95914/sketch/HelloSerialMonitor.ino.cpp:1:
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:2026:11: error: operator '==' has no left operand
     #if F_CPU == 256000000
               ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:2028:13: error: operator '==' has no left operand
     #elif F_CPU == 240000000
                 ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:2030:13: error: operator '==' has no left operand
     #elif F_CPU == 216000000
                 ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:2032:13: error: operator '==' has no left operand
     #elif F_CPU == 192000000
                 ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:2034:13: error: operator '==' has no left operand
     #elif F_CPU == 180000000
                 ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:2036:13: error: operator '==' has no left operand
     #elif F_CPU == 168000000
                 ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:2038:13: error: operator '==' has no left operand
     #elif F_CPU == 144000000
                 ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:2040:13: error: operator '==' has no left operand
     #elif F_CPU == 120000000
                 ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:2042:13: error: operator '==' has no left operand
     #elif F_CPU == 96000000
                 ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:2044:13: error: operator '==' has no left operand
     #elif F_CPU == 72000000
                 ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:2046:13: error: operator '==' has no left operand
     #elif F_CPU == 48000000
                 ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:2048:13: error: operator '==' has no left operand
     #elif F_CPU == 24000000
                 ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:2050:13: error: operator '==' has no left operand
     #elif F_CPU == 16000000
                 ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:2052:13: error: operator '==' has no left operand
     #elif F_CPU == 8000000
                 ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:2054:13: error: operator '==' has no left operand
     #elif F_CPU == 4000000
                 ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:2056:13: error: operator '==' has no left operand
     #elif F_CPU == 2000000
                 ^
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/core_pins.h:2063:11: error: operator '<' has no left operand
     #if F_CPU < 24000000
               ^
    In file included from /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/WProgram.h:54:0,
                     from /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/Arduino.h:6,
                     from /tmp/arduino_build_95914/sketch/HelloSerialMonitor.ino.cpp:1:
    /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/usb_serial.h:40:11: error: operator '>=' has no left operand
     #if F_CPU >= 20000000 && !defined(USB_DISABLED)
               ^
    Error compiling for board Teensy 3.2 / 3.1.
    After running get board info, compilation still fails.

  11. #11
    Senior Member+ defragster's Avatar
    Join Date
    Feb 2015
    Posts
    10,059
    Odd - the only thing I discovered was noted in post #3 - Beta Teensy Hardware didn't have a menu.speed section and when builder ran - not from IDE - it was messing up the passed params F_CPU and KeyBd_Lang were coming out badly until I added a minimal menu.speed.

    Not seeing that as a problem in boards.txt here - but seems a similar symptom where those 'Board' items are passed as Params somewhere 'under the covers'?

    Very Cool tycommander running on RasPi! Without that I would not appreciate the programming environment nearly as much given the IDE limitation on single SerMon and Board per instance.

  12. #12
    Senior Member PaulStoffregen's Avatar
    Join Date
    Nov 2012
    Posts
    20,753
    Quote Originally Posted by pictographer View Post
    Was able to recreate the F_CPU error with a Teensy 3.2 plugged in and after invoking Get Board Info. The key was to run it again from a new user account. So there's definitely an initial state bug of some kind on the RPi build. Haven't been able to make the problem go away on the new account yet.
    I'm trying to reproduce this here on x86 Linux, so far unsuccessfully. I don't have a Raspberry Pi set up at this moment, but can get one later this week if needed.

    There are 2 separate problems here. I want to focus on the F_CPU issue. The NullPointerException exception in processing.app.EditorLineStatus.setSerialPort is indeed a known bug that was fixed quite some time ago in 1.46-beta. The undefined F_CPU issue is new. I really want to figure out what's going wrong with F_CPU and get it fixed before we release 1.46 (in ~2 weeks).

    Good to know creating a new user account on the Pi causes it to happen again. That will be easier than having to completely rewrite the SD card back to an unused system!

    Can you try deleting the preferences file? From the command line, run this:

    rm ~/.arduino15/preferences.txt

    Then when you run Arduino again, does the F_CPU problem return?

  13. #13
    Senior Member PaulStoffregen's Avatar
    Join Date
    Nov 2012
    Posts
    20,753
    Could I talk you into also giving 1.46-beta10 a try on that Raspberry Pi?

    https://forum.pjrc.com/threads/55471...o-1-46-Beta-10

    It's entirely possible the F_CPU problem is somehow a side effect of the EditorLineStatus.setSerialPort NullPointerException bug. Perhaps the catch of that exception is happening in such a way that F_CPU (and maybe other startup stuff) isn't getting done properly. This NullPointerException bug is fixed in 1.46-beta10.

  14. #14
    Senior Member+ KurtE's Avatar
    Join Date
    Jan 2014
    Posts
    5,689
    For what it is worth,

    I just instilled 1.8.9 and Beta 10 on an RPI3+ that I had sitting around, that was setup with vncserver code.

    Under VNCServer on my PC in a VNC viewer I was able to download and install the software.

    I also downloaded and copied in the udev rules into /etc/udev/rules.d

    I then started up Arduino, loaded up blink.ino I plugged in a T3.2 and choose it in the boards menu and in the ports menu.

    And the RPI was able to program the Teensy...

    My RPI: uname -a
    Linux rpi3p-Turtle-ROS2 4.14.79-v7+ #1159 SMP Sun Nov 4 17:50:20 GMT 2018 armv7l GNU/Linux

    EDIT: I also have one or two RPI0w around here as well, just pulled one out and updating) sudo apt....

    Not sure if I had VNC on this or not.
    Last edited by KurtE; 03-19-2019 at 12:47 AM.

  15. #15
    Senior Member pictographer's Avatar
    Join Date
    May 2013
    Location
    San Jose, CA
    Posts
    664
    Installed https://www.pjrc.com/teensy/td_145/T...stall.linuxarm as the pi user because I installed Arduino 1.8.8 as the pi user
    Verified the HelloSerialMonitor example sketch
    Note: verbose compiler output was still selected along with maximum compiler warnings
    Note: I didn't save the sketch at this point
    The compile appeared to succeed, but the teensy loader seemed to stuck on a previous blink hex
    Forced the teensy loader to close
    This time tried to upload the sketch with the arrow rather than the verify checkmark
    Code:
    Arduino: 1.8.8 (Linux), TD: 1.46-beta10, Board: "Teensy 3.2 / 3.1, Serial, 96 MHz (overclock), Faster, US English"
    
    /home/pi/arduino-1.8.8/arduino-builder -dump-prefs -logger=machine -hardware /home/pi/arduino-1.8.8/hardware -tools /home/pi/arduino-1.8.8/tools-builder -tools /home/pi/arduino-1.8.8/hardware/tools/avr -built-in-libraries /home/pi/arduino-1.8.8/libraries -libraries /home/pi/Arduino/libraries -fqbn=teensy:avr:teensy31:usb=serial,speed=96,opt=o2std,keys=en-us -vid-pid=0X16C0_0X0483 -ide-version=10808 -build-path /tmp/arduino_build_862300 -warnings=all -build-cache /tmp/arduino_cache_723413 -verbose /tmp/arduino_modified_sketch_877628/HelloSerialMonitor.pde
    /home/pi/arduino-1.8.8/arduino-builder -compile -logger=machine -hardware /home/pi/arduino-1.8.8/hardware -tools /home/pi/arduino-1.8.8/tools-builder -tools /home/pi/arduino-1.8.8/hardware/tools/avr -built-in-libraries /home/pi/arduino-1.8.8/libraries -libraries /home/pi/Arduino/libraries -fqbn=teensy:avr:teensy31:usb=serial,speed=96,opt=o2std,keys=en-us -vid-pid=0X16C0_0X0483 -ide-version=10808 -build-path /tmp/arduino_build_862300 -warnings=all -build-cache /tmp/arduino_cache_723413 -verbose /tmp/arduino_modified_sketch_877628/HelloSerialMonitor.pde
    Using board 'teensy31' from platform in folder: /home/pi/arduino-1.8.8/hardware/teensy/avr
    Using core 'teensy3' from platform in folder: /home/pi/arduino-1.8.8/hardware/teensy/avr
    Detecting libraries used...
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/arm/bin/arm-none-eabi-g++ -E -CC -x c++ -w -g -Wall -ffunction-sections -fdata-sections -nostdlib -fno-exceptions -felide-constructors -std=gnu++14 -Wno-error=narrowing -fno-rtti -mthumb -mcpu=cortex-m4 -fsingle-precision-constant -D__MK20DX256__ -DTEENSYDUINO=146 -DARDUINO=10808 -DF_CPU=96000000 -DUSB_SERIAL -DLAYOUT_US_ENGLISH -I/home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3 /tmp/arduino_build_862300/sketch/HelloSerialMonitor.pde.cpp -o /dev/null
    Generating function prototypes...
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/arm/bin/arm-none-eabi-g++ -E -CC -x c++ -w -g -Wall -ffunction-sections -fdata-sections -nostdlib -fno-exceptions -felide-constructors -std=gnu++14 -Wno-error=narrowing -fno-rtti -mthumb -mcpu=cortex-m4 -fsingle-precision-constant -D__MK20DX256__ -DTEENSYDUINO=146 -DARDUINO=10808 -DF_CPU=96000000 -DUSB_SERIAL -DLAYOUT_US_ENGLISH -I/home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3 /tmp/arduino_build_862300/sketch/HelloSerialMonitor.pde.cpp -o /tmp/arduino_build_862300/preproc/ctags_target_for_gcc_minus_e.cpp
    /home/pi/arduino-1.8.8/tools-builder/ctags/5.8-arduino11/ctags -u --language-force=c++ -f - --c++-kinds=svpf --fields=KSTtzns --line-directives /tmp/arduino_build_862300/preproc/ctags_target_for_gcc_minus_e.cpp
    Compiling sketch...
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/precompile_helper /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3 /tmp/arduino_build_862300 /home/pi/arduino-1.8.8/hardware/teensy/../tools/arm/bin/arm-none-eabi-g++ -x c++-header -O2 -g -Wall -ffunction-sections -fdata-sections -nostdlib -MMD -fno-exceptions -felide-constructors -std=gnu++14 -Wno-error=narrowing -fno-rtti -mthumb -mcpu=cortex-m4 -fsingle-precision-constant -D__MK20DX256__ -DTEENSYDUINO=146 -DARDUINO=10808 -DF_CPU=96000000 -DUSB_SERIAL -DLAYOUT_US_ENGLISH -I/home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3 /tmp/arduino_build_862300/pch/Arduino.h -o /tmp/arduino_build_862300/pch/Arduino.h.gch
    Using previously compiled file: /tmp/arduino_build_862300/pch/Arduino.h.gch
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/arm/bin/arm-none-eabi-g++ -c -O2 -g -Wall -ffunction-sections -fdata-sections -nostdlib -MMD -fno-exceptions -felide-constructors -std=gnu++14 -Wno-error=narrowing -fno-rtti -mthumb -mcpu=cortex-m4 -fsingle-precision-constant -D__MK20DX256__ -DTEENSYDUINO=146 -DARDUINO=10808 -DF_CPU=96000000 -DUSB_SERIAL -DLAYOUT_US_ENGLISH -I/tmp/arduino_build_862300/pch -I/home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3 /tmp/arduino_build_862300/sketch/HelloSerialMonitor.pde.cpp -o /tmp/arduino_build_862300/sketch/HelloSerialMonitor.pde.cpp.o
    Compiling libraries...
    Compiling core...
    Using precompiled core: /tmp/arduino_cache_723413/core/core_teensy_avr_teensy31_usb_serial,speed_96,opt_o2std,keys_en-us_4405c7511dcfb8c33750f4a4e34a4474.a
    Linking everything together...
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/arm/bin/arm-none-eabi-gcc -O2 -Wl,--gc-sections,--relax,--defsym=__rtc_localtime=1552951577 -T/home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/mk20dx256.ld -lstdc++ -mthumb -mcpu=cortex-m4 -fsingle-precision-constant -o /tmp/arduino_build_862300/HelloSerialMonitor.pde.elf /tmp/arduino_build_862300/sketch/HelloSerialMonitor.pde.cpp.o /tmp/arduino_build_862300/../arduino_cache_723413/core/core_teensy_avr_teensy31_usb_serial,speed_96,opt_o2std,keys_en-us_4405c7511dcfb8c33750f4a4e34a4474.a -L/tmp/arduino_build_862300 -larm_cortexM4l_math -lm
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/arm/bin/arm-none-eabi-objcopy -O ihex -j .eeprom --set-section-flags=.eeprom=alloc,load --no-change-warnings --change-section-lma .eeprom=0 /tmp/arduino_build_862300/HelloSerialMonitor.pde.elf /tmp/arduino_build_862300/HelloSerialMonitor.pde.eep
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/arm/bin/arm-none-eabi-objcopy -O ihex -R .eeprom /tmp/arduino_build_862300/HelloSerialMonitor.pde.elf /tmp/arduino_build_862300/HelloSerialMonitor.pde.hex
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/stdout_redirect /tmp/arduino_build_862300/HelloSerialMonitor.pde.lst /home/pi/arduino-1.8.8/hardware/teensy/../tools/arm/bin/arm-none-eabi-objdump -d -S -C /tmp/arduino_build_862300/HelloSerialMonitor.pde.elf
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/stdout_redirect /tmp/arduino_build_862300/HelloSerialMonitor.pde.sym /home/pi/arduino-1.8.8/hardware/teensy/../tools/arm/bin/arm-none-eabi-objdump -t -C /tmp/arduino_build_862300/HelloSerialMonitor.pde.elf
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/teensy_post_compile -file=HelloSerialMonitor.pde -path=/tmp/arduino_build_862300 -tools=/home/pi/arduino-1.8.8/hardware/teensy/../tools/ -board=TEENSY31
    Opening Teensy Loader...
    Unable find Teensy Loader.  (p)  Is the Teensy Loader application running?
    quitexit status 1
    Error compiling for board Teensy 3.2 / 3.1.
    Was unable to reprogram the Teensy despite pushing the button, but only tried twice.

    Deleted the preferences.
    Restarted Arduino 1.8.8
    Closed the default sketch
    Reopened my HelloSerialMonitor
    Set the board to Teensy 3.1/3.2
    Clicked the Upload arrow button
    (Forgot to turn on verbose compiler messages, doh!)
    Noted in the status line at the bottom of the IDE, 96 Mhz appears
    Code:
    Arduino: 1.8.8 (Linux), TD: 1.46-beta10, Board: "Teensy 3.2 / 3.1, Serial, 96 MHz (overclock), Faster, US English"
    
    Opening Teensy Loader...
    Unable find Teensy Loader.  (p)  Is the Teensy Loader application running?
    quitexit status 1
    Error compiling for board Teensy 3.2 / 3.1.
    Board at null is not available
    
    
    This report would have more information with
    "Show verbose output during compilation"
    option enabled in File -> Preferences.
    And the Teensy loader came up blank. After pressing the Teensy program button, the Teensy loader refreshed, but it had "Blink.pde.hex (unre... " in the status line, not HelloSerialMonitor.
    Attempted to open the serial monitor but at this point, the Teensy was in program mode.
    Updated the preferences to turn on verbose compilation and upload output.
    Again, reported unable to find Teensy loader, but launched it anyhow.
    Pressed the Teensy program button.
    The loader window refreshed.
    Briefly flashed a message about pressing the button.
    Serial monitor showed "[offline] (Teensy 3.2)"
    Selected the port /dev/ttyAMA0, but the menu showed Teensy grayed out below the separator.
    Tried pressing the program button again. This time, the Teensy was configured, but with the wrong hex. It started blinking rather than outputting to the serial console.
    Maybe the hex was left over from the last successful compile.

    Code:
    /home/pi/arduino-1.8.8/arduino-builder -dump-prefs -logger=machine -hardware /home/pi/arduino-1.8.8/hardware -tools /home/pi/arduino-1.8.8/tools-builder -tools /home/pi/arduino-1.8.8/hardware/tools/avr -built-in-libraries /home/pi/arduino-1.8.8/libraries -libraries /home/pi/Arduino/libraries -fqbn=teensy:avr:teensy31:usb=serial,speed=96,opt=o2std,keys=en-us -ide-version=10808 -build-path /tmp/arduino_build_581472 -warnings=all -build-cache /tmp/arduino_cache_265556 -verbose /home/pi/sketchbook/HelloSerialMonitor/HelloSerialMonitor.ino
    /home/pi/arduino-1.8.8/arduino-builder -compile -logger=machine -hardware /home/pi/arduino-1.8.8/hardware -tools /home/pi/arduino-1.8.8/tools-builder -tools /home/pi/arduino-1.8.8/hardware/tools/avr -built-in-libraries /home/pi/arduino-1.8.8/libraries -libraries /home/pi/Arduino/libraries -fqbn=teensy:avr:teensy31:usb=serial,speed=96,opt=o2std,keys=en-us -ide-version=10808 -build-path /tmp/arduino_build_581472 -warnings=all -build-cache /tmp/arduino_cache_265556 -verbose /home/pi/sketchbook/HelloSerialMonitor/HelloSerialMonitor.ino
    Using board 'teensy31' from platform in folder: /home/pi/arduino-1.8.8/hardware/teensy/avr
    Using core 'teensy3' from platform in folder: /home/pi/arduino-1.8.8/hardware/teensy/avr
    Detecting libraries used...
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/arm/bin/arm-none-eabi-g++ -E -CC -x c++ -w -g -Wall -ffunction-sections -fdata-sections -nostdlib -fno-exceptions -felide-constructors -std=gnu++14 -Wno-error=narrowing -fno-rtti -mthumb -mcpu=cortex-m4 -fsingle-precision-constant -D__MK20DX256__ -DTEENSYDUINO=146 -DARDUINO=10808 -DF_CPU=96000000 -DUSB_SERIAL -DLAYOUT_US_ENGLISH -I/home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3 /tmp/arduino_build_581472/sketch/HelloSerialMonitor.ino.cpp -o /dev/null
    Generating function prototypes...
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/arm/bin/arm-none-eabi-g++ -E -CC -x c++ -w -g -Wall -ffunction-sections -fdata-sections -nostdlib -fno-exceptions -felide-constructors -std=gnu++14 -Wno-error=narrowing -fno-rtti -mthumb -mcpu=cortex-m4 -fsingle-precision-constant -D__MK20DX256__ -DTEENSYDUINO=146 -DARDUINO=10808 -DF_CPU=96000000 -DUSB_SERIAL -DLAYOUT_US_ENGLISH -I/home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3 /tmp/arduino_build_581472/sketch/HelloSerialMonitor.ino.cpp -o /tmp/arduino_build_581472/preproc/ctags_target_for_gcc_minus_e.cpp
    /home/pi/arduino-1.8.8/tools-builder/ctags/5.8-arduino11/ctags -u --language-force=c++ -f - --c++-kinds=svpf --fields=KSTtzns --line-directives /tmp/arduino_build_581472/preproc/ctags_target_for_gcc_minus_e.cpp
    Compiling sketch...
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/precompile_helper /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3 /tmp/arduino_build_581472 /home/pi/arduino-1.8.8/hardware/teensy/../tools/arm/bin/arm-none-eabi-g++ -x c++-header -O2 -g -Wall -ffunction-sections -fdata-sections -nostdlib -MMD -fno-exceptions -felide-constructors -std=gnu++14 -Wno-error=narrowing -fno-rtti -mthumb -mcpu=cortex-m4 -fsingle-precision-constant -D__MK20DX256__ -DTEENSYDUINO=146 -DARDUINO=10808 -DF_CPU=96000000 -DUSB_SERIAL -DLAYOUT_US_ENGLISH -I/home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3 /tmp/arduino_build_581472/pch/Arduino.h -o /tmp/arduino_build_581472/pch/Arduino.h.gch
    Using previously compiled file: /tmp/arduino_build_581472/pch/Arduino.h.gch
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/arm/bin/arm-none-eabi-g++ -c -O2 -g -Wall -ffunction-sections -fdata-sections -nostdlib -MMD -fno-exceptions -felide-constructors -std=gnu++14 -Wno-error=narrowing -fno-rtti -mthumb -mcpu=cortex-m4 -fsingle-precision-constant -D__MK20DX256__ -DTEENSYDUINO=146 -DARDUINO=10808 -DF_CPU=96000000 -DUSB_SERIAL -DLAYOUT_US_ENGLISH -I/tmp/arduino_build_581472/pch -I/home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3 /tmp/arduino_build_581472/sketch/HelloSerialMonitor.ino.cpp -o /tmp/arduino_build_581472/sketch/HelloSerialMonitor.ino.cpp.o
    Compiling libraries...
    Compiling core...
    Using previously compiled file: /tmp/arduino_build_581472/core/memcpy-armv7m.S.o
    Using previously compiled file: /tmp/arduino_build_581472/core/memset.S.o
    Using previously compiled file: /tmp/arduino_build_581472/core/eeprom.c.o
    Using previously compiled file: /tmp/arduino_build_581472/core/pins_teensy.c.o
    Using previously compiled file: /tmp/arduino_build_581472/core/ser_print.c.o
    Using previously compiled file: /tmp/arduino_build_581472/core/serial2.c.o
    Using previously compiled file: /tmp/arduino_build_581472/core/serial3.c.o
    Using previously compiled file: /tmp/arduino_build_581472/core/serial4.c.o
    Using previously compiled file: /tmp/arduino_build_581472/core/serial6.c.o
    Using previously compiled file: /tmp/arduino_build_581472/core/serial6_lpuart.c.o
    Using previously compiled file: /tmp/arduino_build_581472/core/touch.c.o
    Using previously compiled file: /tmp/arduino_build_581472/core/usb_dev.c.o
    Using previously compiled file: /tmp/arduino_build_581472/core/usb_joystick.c.o
    Using previously compiled file: /tmp/arduino_build_581472/core/usb_keyboard.c.o
    Using previously compiled file: /tmp/arduino_build_581472/core/math_helper.c.o
    Using previously compiled file: /tmp/arduino_build_581472/core/mk20dx128.c.o
    Using previously compiled file: /tmp/arduino_build_581472/core/nonstd.c.o
    Using previously compiled file: /tmp/arduino_build_581472/core/serial1.c.o
    Using previously compiled file: /tmp/arduino_build_581472/core/keylayouts.c.o
    Using previously compiled file: /tmp/arduino_build_581472/core/serial5.c.o
    Using previously compiled file: /tmp/arduino_build_581472/core/usb_mem.c.o
    Using previously compiled file: /tmp/arduino_build_581472/core/usb_desc.c.o
    Using previously compiled file: /tmp/arduino_build_581472/core/usb_midi.c.o
    Using previously compiled file: /tmp/arduino_build_581472/core/usb_mtp.c.o
    Using previously compiled file: /tmp/arduino_build_581472/core/usb_rawhid.c.o
    Using previously compiled file: /tmp/arduino_build_581472/core/usb_seremu.c.o
    Using previously compiled file: /tmp/arduino_build_581472/core/usb_touch.c.o
    Using previously compiled file: /tmp/arduino_build_581472/core/analog.c.o
    Using previously compiled file: /tmp/arduino_build_581472/core/usb_serial.c.o
    Using previously compiled file: /tmp/arduino_build_581472/core/usb_mouse.c.o
    Using previously compiled file: /tmp/arduino_build_581472/core/HardwareSerial1.cpp.o
    Using previously compiled file: /tmp/arduino_build_581472/core/HardwareSerial5.cpp.o
    Using previously compiled file: /tmp/arduino_build_581472/core/IntervalTimer.cpp.o
    Using previously compiled file: /tmp/arduino_build_581472/core/Stream.cpp.o
    Using previously compiled file: /tmp/arduino_build_581472/core/WMath.cpp.o
    Using previously compiled file: /tmp/arduino_build_581472/core/avr_emulation.cpp.o
    Using previously compiled file: /tmp/arduino_build_581472/core/Tone.cpp.o
    Using previously compiled file: /tmp/arduino_build_581472/core/HardwareSerial6.cpp.o
    Using previously compiled file: /tmp/arduino_build_581472/core/WString.cpp.o
    Using previously compiled file: /tmp/arduino_build_581472/core/main.cpp.o
    Using previously compiled file: /tmp/arduino_build_581472/core/new.cpp.o
    Using previously compiled file: /tmp/arduino_build_581472/core/usb_inst.cpp.o
    Using previously compiled file: /tmp/arduino_build_581472/core/DMAChannel.cpp.o
    Using previously compiled file: /tmp/arduino_build_581472/core/EventResponder.cpp.o
    Using previously compiled file: /tmp/arduino_build_581472/core/HardwareSerial3.cpp.o
    Using previously compiled file: /tmp/arduino_build_581472/core/HardwareSerial4.cpp.o
    Using previously compiled file: /tmp/arduino_build_581472/core/AudioStream.cpp.o
    Using previously compiled file: /tmp/arduino_build_581472/core/IPAddress.cpp.o
    Using previously compiled file: /tmp/arduino_build_581472/core/Print.cpp.o
    Using previously compiled file: /tmp/arduino_build_581472/core/HardwareSerial2.cpp.o
    Using previously compiled file: /tmp/arduino_build_581472/core/usb_audio.cpp.o
    Using previously compiled file: /tmp/arduino_build_581472/core/usb_flightsim.cpp.o
    Using previously compiled file: /tmp/arduino_build_581472/core/yield.cpp.o
    Using previously compiled file: /tmp/arduino_build_581472/core/core.a
    Archiving built core (caching) in: /tmp/arduino_cache_265556/core/core_teensy_avr_teensy31_usb_serial,speed_96,opt_o2std,keys_en-us_4405c7511dcfb8c33750f4a4e34a4474.a
    Linking everything together...
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/arm/bin/arm-none-eabi-gcc -O2 -Wl,--gc-sections,--relax,--defsym=__rtc_localtime=1552952727 -T/home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/mk20dx256.ld -lstdc++ -mthumb -mcpu=cortex-m4 -fsingle-precision-constant -o /tmp/arduino_build_581472/HelloSerialMonitor.ino.elf /tmp/arduino_build_581472/sketch/HelloSerialMonitor.ino.cpp.o /tmp/arduino_build_581472/core/core.a -L/tmp/arduino_build_581472 -larm_cortexM4l_math -lm
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/arm/bin/arm-none-eabi-objcopy -O ihex -j .eeprom --set-section-flags=.eeprom=alloc,load --no-change-warnings --change-section-lma .eeprom=0 /tmp/arduino_build_581472/HelloSerialMonitor.ino.elf /tmp/arduino_build_581472/HelloSerialMonitor.ino.eep
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/arm/bin/arm-none-eabi-objcopy -O ihex -R .eeprom /tmp/arduino_build_581472/HelloSerialMonitor.ino.elf /tmp/arduino_build_581472/HelloSerialMonitor.ino.hex
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/stdout_redirect /tmp/arduino_build_581472/HelloSerialMonitor.ino.lst /home/pi/arduino-1.8.8/hardware/teensy/../tools/arm/bin/arm-none-eabi-objdump -d -S -C /tmp/arduino_build_581472/HelloSerialMonitor.ino.elf
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/stdout_redirect /tmp/arduino_build_581472/HelloSerialMonitor.ino.sym /home/pi/arduino-1.8.8/hardware/teensy/../tools/arm/bin/arm-none-eabi-objdump -t -C /tmp/arduino_build_581472/HelloSerialMonitor.ino.elf
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/teensy_post_compile -file=HelloSerialMonitor.ino -path=/tmp/arduino_build_581472 -tools=/home/pi/arduino-1.8.8/hardware/teensy/../tools/ -board=TEENSY31
    Opening Teensy Loader...
    Unable find Teensy Loader.  (p)  Is the Teensy Loader application running?
    quitexit status 1
    Error compiling for board Teensy 3.2 / 3.1.
    Attempted to compile and upload again, this time with the serial monitor window still open. Still can't find HelloSerialMonitor.hex.
    Code:
    Arduino: 1.8.8 (Linux), TD: 1.46-beta10, Board: "Teensy 3.2 / 3.1, Serial, 96 MHz (overclock), Faster, US English"
    
    /home/pi/arduino-1.8.8/arduino-builder -dump-prefs -logger=machine -hardware /home/pi/arduino-1.8.8/hardware -tools /home/pi/arduino-1.8.8/tools-builder -tools /home/pi/arduino-1.8.8/hardware/tools/avr -built-in-libraries /home/pi/arduino-1.8.8/libraries -libraries /home/pi/Arduino/libraries -fqbn=teensy:avr:teensy31:usb=serial,speed=96,opt=o2std,keys=en-us -ide-version=10808 -build-path /tmp/arduino_build_581472 -warnings=all -build-cache /tmp/arduino_cache_265556 -verbose /home/pi/sketchbook/HelloSerialMonitor/HelloSerialMonitor.ino
    /home/pi/arduino-1.8.8/arduino-builder -compile -logger=machine -hardware /home/pi/arduino-1.8.8/hardware -tools /home/pi/arduino-1.8.8/tools-builder -tools /home/pi/arduino-1.8.8/hardware/tools/avr -built-in-libraries /home/pi/arduino-1.8.8/libraries -libraries /home/pi/Arduino/libraries -fqbn=teensy:avr:teensy31:usb=serial,speed=96,opt=o2std,keys=en-us -ide-version=10808 -build-path /tmp/arduino_build_581472 -warnings=all -build-cache /tmp/arduino_cache_265556 -verbose /home/pi/sketchbook/HelloSerialMonitor/HelloSerialMonitor.ino
    Using board 'teensy31' from platform in folder: /home/pi/arduino-1.8.8/hardware/teensy/avr
    Using core 'teensy3' from platform in folder: /home/pi/arduino-1.8.8/hardware/teensy/avr
    Detecting libraries used...
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/arm/bin/arm-none-eabi-g++ -E -CC -x c++ -w -g -Wall -ffunction-sections -fdata-sections -nostdlib -fno-exceptions -felide-constructors -std=gnu++14 -Wno-error=narrowing -fno-rtti -mthumb -mcpu=cortex-m4 -fsingle-precision-constant -D__MK20DX256__ -DTEENSYDUINO=146 -DARDUINO=10808 -DF_CPU=96000000 -DUSB_SERIAL -DLAYOUT_US_ENGLISH -I/home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3 /tmp/arduino_build_581472/sketch/HelloSerialMonitor.ino.cpp -o /dev/null
    Generating function prototypes...
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/arm/bin/arm-none-eabi-g++ -E -CC -x c++ -w -g -Wall -ffunction-sections -fdata-sections -nostdlib -fno-exceptions -felide-constructors -std=gnu++14 -Wno-error=narrowing -fno-rtti -mthumb -mcpu=cortex-m4 -fsingle-precision-constant -D__MK20DX256__ -DTEENSYDUINO=146 -DARDUINO=10808 -DF_CPU=96000000 -DUSB_SERIAL -DLAYOUT_US_ENGLISH -I/home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3 /tmp/arduino_build_581472/sketch/HelloSerialMonitor.ino.cpp -o /tmp/arduino_build_581472/preproc/ctags_target_for_gcc_minus_e.cpp
    /home/pi/arduino-1.8.8/tools-builder/ctags/5.8-arduino11/ctags -u --language-force=c++ -f - --c++-kinds=svpf --fields=KSTtzns --line-directives /tmp/arduino_build_581472/preproc/ctags_target_for_gcc_minus_e.cpp
    Compiling sketch...
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/precompile_helper /home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3 /tmp/arduino_build_581472 /home/pi/arduino-1.8.8/hardware/teensy/../tools/arm/bin/arm-none-eabi-g++ -x c++-header -O2 -g -Wall -ffunction-sections -fdata-sections -nostdlib -MMD -fno-exceptions -felide-constructors -std=gnu++14 -Wno-error=narrowing -fno-rtti -mthumb -mcpu=cortex-m4 -fsingle-precision-constant -D__MK20DX256__ -DTEENSYDUINO=146 -DARDUINO=10808 -DF_CPU=96000000 -DUSB_SERIAL -DLAYOUT_US_ENGLISH -I/home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3 /tmp/arduino_build_581472/pch/Arduino.h -o /tmp/arduino_build_581472/pch/Arduino.h.gch
    Using previously compiled file: /tmp/arduino_build_581472/pch/Arduino.h.gch
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/arm/bin/arm-none-eabi-g++ -c -O2 -g -Wall -ffunction-sections -fdata-sections -nostdlib -MMD -fno-exceptions -felide-constructors -std=gnu++14 -Wno-error=narrowing -fno-rtti -mthumb -mcpu=cortex-m4 -fsingle-precision-constant -D__MK20DX256__ -DTEENSYDUINO=146 -DARDUINO=10808 -DF_CPU=96000000 -DUSB_SERIAL -DLAYOUT_US_ENGLISH -I/tmp/arduino_build_581472/pch -I/home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3 /tmp/arduino_build_581472/sketch/HelloSerialMonitor.ino.cpp -o /tmp/arduino_build_581472/sketch/HelloSerialMonitor.ino.cpp.o
    Compiling libraries...
    Compiling core...
    Using precompiled core: /tmp/arduino_cache_265556/core/core_teensy_avr_teensy31_usb_serial,speed_96,opt_o2std,keys_en-us_4405c7511dcfb8c33750f4a4e34a4474.a
    Linking everything together...
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/arm/bin/arm-none-eabi-gcc -O2 -Wl,--gc-sections,--relax,--defsym=__rtc_localtime=1552953232 -T/home/pi/arduino-1.8.8/hardware/teensy/avr/cores/teensy3/mk20dx256.ld -lstdc++ -mthumb -mcpu=cortex-m4 -fsingle-precision-constant -o /tmp/arduino_build_581472/HelloSerialMonitor.ino.elf /tmp/arduino_build_581472/sketch/HelloSerialMonitor.ino.cpp.o /tmp/arduino_build_581472/../arduino_cache_265556/core/core_teensy_avr_teensy31_usb_serial,speed_96,opt_o2std,keys_en-us_4405c7511dcfb8c33750f4a4e34a4474.a -L/tmp/arduino_build_581472 -larm_cortexM4l_math -lm
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/arm/bin/arm-none-eabi-objcopy -O ihex -j .eeprom --set-section-flags=.eeprom=alloc,load --no-change-warnings --change-section-lma .eeprom=0 /tmp/arduino_build_581472/HelloSerialMonitor.ino.elf /tmp/arduino_build_581472/HelloSerialMonitor.ino.eep
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/arm/bin/arm-none-eabi-objcopy -O ihex -R .eeprom /tmp/arduino_build_581472/HelloSerialMonitor.ino.elf /tmp/arduino_build_581472/HelloSerialMonitor.ino.hex
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/stdout_redirect /tmp/arduino_build_581472/HelloSerialMonitor.ino.lst /home/pi/arduino-1.8.8/hardware/teensy/../tools/arm/bin/arm-none-eabi-objdump -d -S -C /tmp/arduino_build_581472/HelloSerialMonitor.ino.elf
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/stdout_redirect /tmp/arduino_build_581472/HelloSerialMonitor.ino.sym /home/pi/arduino-1.8.8/hardware/teensy/../tools/arm/bin/arm-none-eabi-objdump -t -C /tmp/arduino_build_581472/HelloSerialMonitor.ino.elf
    /home/pi/arduino-1.8.8/hardware/teensy/../tools/teensy_post_compile -file=HelloSerialMonitor.ino -path=/tmp/arduino_build_581472 -tools=/home/pi/arduino-1.8.8/hardware/teensy/../tools/ -board=TEENSY31
    Opening Teensy Loader...
    Unable find Teensy Loader.  (p)  Is the Teensy Loader application running?
    quitexit status 1
    Error compiling for board Teensy 3.2 / 3.1.
    Used the Teensy Loader Open Hex File command to load HelloSerialMonitor.ino.hex
    Rebooted the teensy
    Switch the port to /dev/ttyACM0
    At last got expected output in the Serial Monitor window.

    I'm out of time for today.

  16. #16
    Senior Member PaulStoffregen's Avatar
    Join Date
    Nov 2012
    Posts
    20,753
    Wow, sounds like things are going pretty badly on Raspberry Pi Zero.

    I'll admit, I've never tested on that board, only on the 3B model... the one just before they put a metal heat spreader on the main chip.

    This makes me suspect we might not be allowing enough time on such a slow system.

    Code:
    Opening Teensy Loader...
    Unable find Teensy Loader.  (p)  Is the Teensy Loader application running?
    quitexit status 1
    Error compiling for board Teensy 3.2 / 3.1.
    Board at null is not available
    You said "Teensy loader came up blank". Not sure I know quite what that means, but I'm guessing that poor Pi Zero may be running so slowly and maybe having to use the SD card as swap space due to the low memory (and Java hogging lots of RAM) that Teensy Loader wasn't able to fully start running before the code on the Arduino side gave up trying to inform it of your freshly compiled code.

  17. #17
    Senior Member+ KurtE's Avatar
    Join Date
    Jan 2014
    Posts
    5,689
    Again for what it is worth I downloaded Arduino to a RPI0w yesterday and it installed, and crawled... I also downloaded Teensyduino Beta 10, and chmod +x the file and tried running it from a command window run over vnc server and nothing came up... There were no error messages, but nothing showed up on screen. Today I will try plugging it into monitor instead and see if not running with SCP...

    So again so far If I ever choose to use one of these... I think I would use the just run the command line teensy loader program to update a teensy.

  18. #18
    Senior Member pictographer's Avatar
    Join Date
    May 2013
    Location
    San Jose, CA
    Posts
    664
    By came up blank, I mean the window appeared, but it was all white. I'll post pictures later. Looks like the window isn't drawing for some of the exposure events. Pressing the program button on the Teensy causes the Loader application to redraw.

    Paul, if you'd like me to mail you my pi zero w and sd card, I'm willing. Otherwise, I'll gladly keep trying suggestions and debugging, but work and family duties don't allow much tinkering time.

  19. #19
    Senior Member pictographer's Avatar
    Join Date
    May 2013
    Location
    San Jose, CA
    Posts
    664
    Kurt, I needed to install many packages to make vncserver work.

    Agreed that this platform is too slow to use for a desktop. My aim here is to help troubleshoot the bugs. Eventually, the RPi may have no other job than to sit on my wifi network watching a directory so it can squirt new firmware into a Teensy without me needing a ladder.

  20. #20
    Senior Member+ KurtE's Avatar
    Join Date
    Jan 2014
    Posts
    5,689
    Quote Originally Posted by pictographer View Post
    Kurt, I needed to install many packages to make vncserver work.

    Agreed that this platform is too slow to use for a desktop. My aim here is to help troubleshoot the bugs. Eventually, the RPi may have no other job than to sit on my wifi network watching a directory so it can squirt new firmware into a Teensy without me needing a ladder.
    Yep - VNCServer worked on the RPI0W, I was able to run the Web browser and get to the Arduino download to install Arduino 1.8.9, and was able to download the Teensyduino...
    But it did not run yesterday. WIll try to re-download it and try it again.

    But as I mentioned I may also try it plugged into monitor directly to see if that makes any difference. (I too am doing this just to help debug).

    I purchased them awhile ago (like when they first came out) to see if they might be good for things like this. So far they typically sit in my cabinet in a box labeled RPI (and Beagle Bone Black)...

  21. #21
    Senior Member+ KurtE's Avatar
    Join Date
    Jan 2014
    Posts
    5,689
    Again for what it is worth, I now have Teensyduino beta 10 on 1.8.9 installed on RPI0W with directly plugged into HDMI and Mouse/Keyboard.

    Was able to compile Blink example, but Teensy app does not work... It shows white as mentioned earlier.

    Also have: htop running, shows 100%CPU with the Teensy app taking over 90%... Mem is about 223 out of 433, now noticing anything with Swp right now

    Note: I then killed the Teensy app, and loaded it by command line and it came up without a problem.

    Then tried another upload command in Arduino and again hung opening Teensy Loader and htop showing 100% teensy app eating most
    Last edited by KurtE; 03-19-2019 at 08:36 PM.

  22. #22
    Senior Member pictographer's Avatar
    Join Date
    May 2013
    Location
    San Jose, CA
    Posts
    664
    Here's an example of how the Teensy Loader application looks on Raspberry Pi W over VNC on Beta 10 and the previous release:

    Click image for larger version. 

Name:	Screen Shot 2019-03-21 at 6.28.47 PM.png 
Views:	14 
Size:	502.9 KB 
ID:	16209
    It redraws reasonably quickly after I press the program button so I don't think the slow platform explains all of it. Also, this blank screen persisted for several days. The RPi isn't that slow.

    The Teensy Loader CPU fluctuates between 40% and 80% while it is idle. I don' t see this behavior with the other applications.

    It's entirely possible the F_CPU problem is somehow a side effect of the EditorLineStatus.setSerialPort NullPointerException bug. Perhaps the catch of that exception is happening in such a way that F_CPU (and maybe other startup stuff) isn't getting done properly. This NullPointerException bug is fixed in 1.46-beta10.
    Agreed. I haven't been able to reproduce the F_CPU undefined bug with the beta.

  23. #23
    Senior Member pictographer's Avatar
    Join Date
    May 2013
    Location
    San Jose, CA
    Posts
    664
    Here's what the verbose info from the Loader says:
    Code:
    18:39:24.365 (ports 2): Begin, version=1.46-beta1018:39:24.965 (ports 2): add device: subsys=usb, type=usb_device, location=/sys/devices/platform/soc/20980000.usb/usb1/1-1
    18:39:24.965 (ports 2):   devnode=/dev/bus/usb/001/019, subsystem=usb, ifacenum=-1
    18:39:24.965 (ports 2): usb_add: /dev/bus/usb/001/019 (Teensy) Serial
    18:39:25.015 (ports 2): add child:  subsys=usb, type=usb_interface, location=/sys/devices/platform/soc/20980000.usb/usb1/1-1/1-1:1.0
    18:39:25.015 (ports 2):   parent location=/sys/devices/platform/soc/20980000.usb/usb1/1-1
    18:39:25.015 (ports 2):   model=33 (Teensy 3.2)
    18:39:25.015 (ports 2): usb_add: /dev/bus/usb/001/019 (Teensy 3.2) Serial
    18:39:25.034 (ports 2): add child:  subsys=tty, type=(null), location=/sys/devices/platform/soc/20980000.usb/usb1/1-1/1-1:1.0/tty/ttyACM0
    18:39:25.034 (ports 2):   parent location=/sys/devices/platform/soc/20980000.usb/usb1/1-1
    18:39:25.035 (ports 2):   devnode=/dev/ttyACM0, subsystem=tty, ifacenum=0
    18:39:25.035 (ports 2): usb_add: /dev/ttyACM0 (Teensy 3.2) Serial
    18:39:25.077 (ports 2): add child:  subsys=usb, type=usb_interface, location=/sys/devices/platform/soc/20980000.usb/usb1/1-1/1-1:1.1
    18:39:25.077 (ports 2):   parent location=/sys/devices/platform/soc/20980000.usb/usb1/1-1
    18:39:25.077 (ports 2): usb_add: /dev/ttyACM0 (Teensy 3.2) Serial
    18:45:10.821 (loader): Teensy Loader 1.46-beta10, begin program
    18:45:11.138 (loader): Listening for remote control on port 3149
    18:45:11.142 (loader): initialized, showing main window
    18:46:04.617 (ports 2): del child: location=/sys/devices/platform/soc/20980000.usb/usb1/1-1/1-1:1.0/tty/ttyACM0
    18:46:04.617 (ports 2):   devnode=/dev/bus/usb/001/019, subsystem=usb, ifacenum=-1
    18:46:07.375 (loader): Device came online, code_size = 262144
    18:46:07.377 (loader): Board is: Teensy 3.2 (MK20DX256), version 1.03
    18:46:07.391 (loader): set background IMG_ONLINE
    18:46:08.105 (loader): remote connection 5 opened
    18:46:08.126 (loader): remote connection 5 opened
    18:46:08.141 (ports 2): del child: location=/sys/devices/platform/soc/20980000.usb/usb1/1-1/1-1:1.1
    18:46:08.141 (ports 2): del child: location=/sys/devices/platform/soc/20980000.usb/usb1/1-1/1-1:1.0
    18:46:08.142 (ports 2): del device: location=/sys/devices/platform/soc/20980000.usb/usb1/1-1
    18:46:08.144 (ports 2): add device: subsys=usb, type=usb_device, location=/sys/devices/platform/soc/20980000.usb/usb1/1-1
    18:46:08.144 (ports 2):   devnode=/dev/bus/usb/001/020, subsystem=usb, ifacenum=-1
    18:46:08.145 (ports 2): usb_add: /dev/bus/usb/001/020 (Teensy 3.2) Bootloader
    18:46:08.146 (loader): remote connection 5 closed
    18:46:08.166 (ports 2): add child:  subsys=usb, type=usb_interface, location=/sys/devices/platform/soc/20980000.usb/usb1/1-1/1-1:1.0
    18:46:08.166 (ports 2):   parent location=/sys/devices/platform/soc/20980000.usb/usb1/1-1
    18:46:08.166 (ports 2): usb_add: /dev/bus/usb/001/020 (Teensy 3.2) Bootloader
    18:46:08.174 (ports 2): add child:  subsys=hid, type=(null), location=/sys/devices/platform/soc/20980000.usb/usb1/1-1/1-1:1.0/0003:16C0:0478.000A
    18:46:08.174 (ports 2):   parent location=/sys/devices/platform/soc/20980000.usb/usb1/1-1
    18:46:08.174 (ports 2): usb_add: /dev/bus/usb/001/020 (Teensy 3.2) Bootloader
    18:46:08.190 (ports 2): add child:  subsys=hidraw, type=(null), location=/sys/devices/platform/soc/20980000.usb/usb1/1-1/1-1:1.0/0003:16C0:0478.000A/hidraw/hidraw0
    18:46:08.190 (ports 2):   parent location=/sys/devices/platform/soc/20980000.usb/usb1/1-1
    18:46:08.191 (ports 2): usb_add: /dev/bus/usb/001/020 (Teensy 3.2) Bootloader
    18:46:08.195 (ports 2): del child: location=/sys/devices/platform/soc/20980000.usb/usb1/1-1/1-1:1.0/0003:16C0:0478.000A/hidraw/hidraw0
    18:46:08.200 (ports 2): del child: location=/sys/devices/platform/soc/20980000.usb/usb1/1-1/1-1:1.0/0003:16C0:0478.000A
    18:46:22.766 (loader): Open File event
    18:46:50.837 (loader): Verbose Info event

  24. #24
    Junior Member
    Join Date
    Apr 2019
    Posts
    10

    Could you link to the mentioned threads ?

    Quote Originally Posted by KurtE View Post
    As mentioned in other threads, another option is to build on another computer and then transfer the binary to RPI and then use the tens loader app on the pi.

    I was doing this earlier on RPI to program OpenCM boards, where I had a hacked up setup (boards.txt,...), that had upload using Wi-Fi, and setup a connection where this would copy the file to RPI, where there was a script running that checked for changed file, and would run their upload program... sort of like the Edison used to do. Wish to someday do similar for teensy
    Hi,
    i had the intension to do exactly that. But i somehow came to the conclusion, that i will be not able to handle the trubleshooting by my own needed to get a setup like this up and running... I have no real experience neither with Raspberry nor with Linux OS and it seems to be, you have to be some kind of Linux wizzard to get anything running on the raspberry that goes above realy basic stuff.
    Tho, if there is someone out there who has already handled a lot of the problems coming with such a kind of OTA programming of the Teensy, I would really appreciate any kind of help!

  25. #25
    Senior Member+ KurtE's Avatar
    Join Date
    Jan 2014
    Posts
    5,689
    I know that this has come up several times...

    Here is a thread I did two years ago: https://forum.pjrc.com/threads/42790...Ty-or-the-like

    As I mentioned then, it would be great if we could somehow setup a remote location to send binaries to, but the thread shows the pieces...

    The manual steps involved include:
    a) Compile your app on the PC (Windows, MAC, Linux...)
    b) Find the binary (can use the export compiled binary command)
    c) Copy the binary to your RPI - On windows I use WinSCP to do this. (I normally use KiTTY) which ha command to launch WinSCP...
    d) Use a command prompt on RPI (I use KiTTY, which is derived from PuTTy), and run the command line to program the teensy

    Nice thing with this approach is you don't need a GUI on the RPI to program the teensy, just a command line interface. What commands you would use on Mac or Linux would be different.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •