Forum Rule: Always post complete source code & details to reproduce any issue!
Results 1 to 10 of 10

Thread: PlatformIO Config Options

  1. #1
    Senior Member
    Join Date
    Dec 2015
    Posts
    133

    PlatformIO Config Options

    Hi all,

    I'm starting to play around with PlatformIO, and one thing I haven't found yet are the list of specific Teensy related platformio.ini options. For instance, I have been using USB Audio a bunch recently, I haven't figured out how to enable that in PlatformIO.

    Any pointers would be appreciated!

    Thank you!

  2. #2
    Junior Member
    Join Date
    Aug 2018
    Posts
    6
    https://docs.platformio.org/en/lates...ms/teensy.html

    I struggled with this for a while as well. The link above shows how to add options to the platformio.ini config file. Hope it helps!

  3. #3
    Junior Member
    Join Date
    Aug 2020
    Posts
    9
    Hello... have anyone could successfully compiled and uploaded on Teensy 4.1 using Platform IO.

    //------------------------------------------------------------------------------------------------------------------------------------
    below is platform.ini
    [env:teensy41]
    platform = teensy
    board = teensy41

    ; change microcontroller
    board_build.mcu = imxrt1062

    ; change MCU frequency
    board_build.f_cpu = 600000000L

    framework = arduino

    upload_protocol = teensy-gui
    //--------------------------------------------------------------------------------------------------------
    error during building process...

    > Executing task: platformio run <

    Processing teensy41 (platform: teensy; board: teensy41; framework: arduino)
    -----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
    Verbose mode can be enabled via `-v, --verbose` option
    CONFIGURATION: https://docs.platformio.org/page/boa.../teensy41.html
    PLATFORM: Teensy 4.11.0 > Teensy 4.1
    HARDWARE: IMXRT1062 600MHz, 512KB RAM, 7.75MB Flash
    DEBUG: Current (jlink) External (jlink)
    PACKAGES:
    - framework-arduinoteensy 1.153.0 (1.53)
    - toolchain-gccarmnoneeabi 1.50401.0 (5.4.1)
    LDF: Library Dependency Finder -> http://bit.ly/configure-pio-ldf
    LDF Modes: Finder ~ chain, Compatibility ~ soft
    Found 89 compatible libraries
    Scanning dependencies...
    No dependencies
    Building in release mode
    Compiling .pio/build/teensy41/src/main.cpp.o
    Compiling .pio/build/teensy41/FrameworkArduino/AudioStream.cpp.o
    Compiling .pio/build/teensy41/FrameworkArduino/Blink.cc.o
    In file included from /home/pi/.platformio/packages/framework-arduinoteensy/cores/teensy4/wiring.h:45:0,
    from /home/pi/.platformio/packages/framework-arduinoteensy/cores/teensy4/WProgram.h:45,
    from /home/pi/.platformio/packages/framework-arduinoteensy/cores/teensy4/Arduino.h:6,
    from src/main.cpp:1:
    /home/pi/.platformio/packages/toolchain-gccarmnoneeabi/arm-none-eabi/include/c++/5.4.1/type_traits:38:28: fatal error: bits/c++config.h: No such file or directory
    compilation terminated.
    *** [.pio/build/teensy41/src/main.cpp.o] Error 1
    Compiling .pio/build/teensy41/FrameworkArduino/EventResponder.cpp.o
    In file included from /home/pi/.platformio/packages/framework-arduinoteensy/cores/teensy4/wiring.h:45:0,
    from /home/pi/.platformio/packages/framework-arduinoteensy/cores/teensy4/WProgram.h:45,
    from /home/pi/.platformio/packages/framework-arduinoteensy/cores/teensy4/Arduino.h:6,
    from /home/pi/.platformio/packages/framework-arduinoteensy/cores/teensy4/AudioStream.cpp:32:
    /home/pi/.platformio/packages/toolchain-gccarmnoneeabi/arm-none-eabi/include/c++/5.4.1/type_traits:38:28: fatal error: bits/c++config.h: No such file or directory
    compilation terminated.
    *** [.pio/build/teensy41/FrameworkArduino/AudioStream.cpp.o] Error 1
    In file included from /home/pi/.platformio/packages/framework-arduinoteensy/cores/teensy4/wiring.h:45:0,
    from /home/pi/.platformio/packages/framework-arduinoteensy/cores/teensy4/WProgram.h:45,
    from /home/pi/.platformio/packages/framework-arduinoteensy/cores/teensy4/Arduino.h:6,
    from /home/pi/.platformio/packages/framework-arduinoteensy/cores/teensy4/Blink.cc:3:
    /home/pi/.platformio/packages/toolchain-gccarmnoneeabi/arm-none-eabi/include/c++/5.4.1/type_traits:38:28: fatal error: bits/c++config.h: No such file or directory
    compilation terminated.
    *** [.pio/build/teensy41/FrameworkArduino/Blink.cc.o] Error 1
    In file included from /home/pi/.platformio/packages/framework-arduinoteensy/cores/teensy4/wiring.h:45:0,
    from /home/pi/.platformio/packages/framework-arduinoteensy/cores/teensy4/WProgram.h:45,
    from /home/pi/.platformio/packages/framework-arduinoteensy/cores/teensy4/Arduino.h:6,
    from /home/pi/.platformio/packages/framework-arduinoteensy/cores/teensy4/EventResponder.cpp:34:
    /home/pi/.platformio/packages/toolchain-gccarmnoneeabi/arm-none-eabi/include/c++/5.4.1/type_traits:38:28: fatal error: bits/c++config.h: No such file or directory
    compilation terminated.
    *** [.pio/build/teensy41/FrameworkArduino/EventResponder.cpp.o] Error 1
    ================================================== =============================== [FAILED] Took 3.17 seconds ================================================== ===============================
    The terminal process terminated with exit code: 1

    Terminal will be reused by tasks, press any key to close it.


    can anyone please help to resolve the above problem.

    Thanks in advance.

  4. #4
    Senior Member
    Join Date
    Aug 2017
    Posts
    298
    Quote Originally Posted by jishnuch View Post
    Hello... have anyone could successfully compiled and uploaded on Teensy 4.1 using Platform IO.

    //------------------------------------------------------------------------------------------------------------------------------------
    below is platform.ini
    [env:teensy41]
    platform = teensy
    board = teensy41

    ; change microcontroller
    board_build.mcu = imxrt1062

    ; change MCU frequency
    board_build.f_cpu = 600000000L

    framework = arduino

    upload_protocol = teensy-gui
    //--------------------------------------------------------------------------------------------------------
    error during building process...

    > Executing task: platformio run <

    Processing teensy41 (platform: teensy; board: teensy41; framework: arduino)
    -----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
    Verbose mode can be enabled via `-v, --verbose` option
    CONFIGURATION: https://docs.platformio.org/page/boa.../teensy41.html
    PLATFORM: Teensy 4.11.0 > Teensy 4.1
    HARDWARE: IMXRT1062 600MHz, 512KB RAM, 7.75MB Flash
    DEBUG: Current (jlink) External (jlink)
    PACKAGES:
    - framework-arduinoteensy 1.153.0 (1.53)
    - toolchain-gccarmnoneeabi 1.50401.0 (5.4.1)
    LDF: Library Dependency Finder -> http://bit.ly/configure-pio-ldf
    LDF Modes: Finder ~ chain, Compatibility ~ soft
    Found 89 compatible libraries
    Scanning dependencies...
    No dependencies
    Building in release mode
    Compiling .pio/build/teensy41/src/main.cpp.o
    Compiling .pio/build/teensy41/FrameworkArduino/AudioStream.cpp.o
    Compiling .pio/build/teensy41/FrameworkArduino/Blink.cc.o
    In file included from /home/pi/.platformio/packages/framework-arduinoteensy/cores/teensy4/wiring.h:45:0,
    from /home/pi/.platformio/packages/framework-arduinoteensy/cores/teensy4/WProgram.h:45,
    from /home/pi/.platformio/packages/framework-arduinoteensy/cores/teensy4/Arduino.h:6,
    from src/main.cpp:1:
    /home/pi/.platformio/packages/toolchain-gccarmnoneeabi/arm-none-eabi/include/c++/5.4.1/type_traits:38:28: fatal error: bits/c++config.h: No such file or directory
    compilation terminated.
    *** [.pio/build/teensy41/src/main.cpp.o] Error 1
    Compiling .pio/build/teensy41/FrameworkArduino/EventResponder.cpp.o
    In file included from /home/pi/.platformio/packages/framework-arduinoteensy/cores/teensy4/wiring.h:45:0,
    from /home/pi/.platformio/packages/framework-arduinoteensy/cores/teensy4/WProgram.h:45,
    from /home/pi/.platformio/packages/framework-arduinoteensy/cores/teensy4/Arduino.h:6,
    from /home/pi/.platformio/packages/framework-arduinoteensy/cores/teensy4/AudioStream.cpp:32:
    /home/pi/.platformio/packages/toolchain-gccarmnoneeabi/arm-none-eabi/include/c++/5.4.1/type_traits:38:28: fatal error: bits/c++config.h: No such file or directory
    compilation terminated.
    *** [.pio/build/teensy41/FrameworkArduino/AudioStream.cpp.o] Error 1
    In file included from /home/pi/.platformio/packages/framework-arduinoteensy/cores/teensy4/wiring.h:45:0,
    from /home/pi/.platformio/packages/framework-arduinoteensy/cores/teensy4/WProgram.h:45,
    from /home/pi/.platformio/packages/framework-arduinoteensy/cores/teensy4/Arduino.h:6,
    from /home/pi/.platformio/packages/framework-arduinoteensy/cores/teensy4/Blink.cc:3:
    /home/pi/.platformio/packages/toolchain-gccarmnoneeabi/arm-none-eabi/include/c++/5.4.1/type_traits:38:28: fatal error: bits/c++config.h: No such file or directory
    compilation terminated.
    *** [.pio/build/teensy41/FrameworkArduino/Blink.cc.o] Error 1
    In file included from /home/pi/.platformio/packages/framework-arduinoteensy/cores/teensy4/wiring.h:45:0,
    from /home/pi/.platformio/packages/framework-arduinoteensy/cores/teensy4/WProgram.h:45,
    from /home/pi/.platformio/packages/framework-arduinoteensy/cores/teensy4/Arduino.h:6,
    from /home/pi/.platformio/packages/framework-arduinoteensy/cores/teensy4/EventResponder.cpp:34:
    /home/pi/.platformio/packages/toolchain-gccarmnoneeabi/arm-none-eabi/include/c++/5.4.1/type_traits:38:28: fatal error: bits/c++config.h: No such file or directory
    compilation terminated.
    *** [.pio/build/teensy41/FrameworkArduino/EventResponder.cpp.o] Error 1
    ================================================== =============================== [FAILED] Took 3.17 seconds ================================================== ===============================
    The terminal process terminated with exit code: 1

    Terminal will be reused by tasks, press any key to close it.


    can anyone please help to resolve the above problem.

    Thanks in advance.
    If you look at the line that says fatal error: you are missing the f
    oward slash between "c++" and "config.h". The compiler thinks "c++config.h" if a filename.

  5. #5
    Junior Member
    Join Date
    Aug 2020
    Posts
    9
    Quote Originally Posted by wwatson View Post
    If you look at the line that says fatal error: you are missing the f
    oward slash between "c++" and "config.h". The compiler thinks "c++config.h" if a filename.
    It didn't work....

    > Executing task: platformio run <

    Processing teensy41 (platform: teensy; board: teensy41; framework: arduino)
    -----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
    Verbose mode can be enabled via `-v, --verbose` option
    CONFIGURATION: https://docs.platformio.org/page/boa.../teensy41.html
    PLATFORM: Teensy 4.11.0 > Teensy 4.1
    HARDWARE: IMXRT1062 600MHz, 512KB RAM, 7.75MB Flash
    DEBUG: Current (jlink) External (jlink)
    PACKAGES:
    - framework-arduinoteensy 1.153.0 (1.53)
    - toolchain-gccarmnoneeabi 1.50401.0 (5.4.1)
    LDF: Library Dependency Finder -> http://bit.ly/configure-pio-ldf
    LDF Modes: Finder ~ chain, Compatibility ~ soft
    Found 89 compatible libraries
    Scanning dependencies...
    No dependencies
    Building in release mode
    Compiling .pio/build/teensy41/src/main.cpp.o
    Compiling .pio/build/teensy41/FrameworkArduino/AudioStream.cpp.o
    Compiling .pio/build/teensy41/FrameworkArduino/Blink.cc.o
    In file included from /home/pi/.platformio/packages/framework-arduinoteensy/cores/teensy4/wiring.h:45:0,
    from /home/pi/.platformio/packages/framework-arduinoteensy/cores/teensy4/WProgram.h:45,
    from /home/pi/.platformio/packages/framework-arduinoteensy/cores/teensy4/Arduino.h:6,
    from src/main.cpp:1:
    /home/pi/.platformio/packages/toolchain-gccarmnoneeabi/arm-none-eabi/include/c++/5.4.1/type_traits:39:29: fatal error: bits/c++/config.h: No such file or directory
    compilation terminated.
    *** [.pio/build/teensy41/src/main.cpp.o] Error 1
    Compiling .pio/build/teensy41/FrameworkArduino/EventResponder.cpp.o
    In file included from /home/pi/.platformio/packages/framework-arduinoteensy/cores/teensy4/wiring.h:45:0,
    from /home/pi/.platformio/packages/framework-arduinoteensy/cores/teensy4/WProgram.h:45,
    from /home/pi/.platformio/packages/framework-arduinoteensy/cores/teensy4/Arduino.h:6,
    from /home/pi/.platformio/packages/framework-arduinoteensy/cores/teensy4/AudioStream.cpp:32:
    /home/pi/.platformio/packages/toolchain-gccarmnoneeabi/arm-none-eabi/include/c++/5.4.1/type_traits:39:29: fatal error: bits/c++/config.h: No such file or directory
    compilation terminated.
    *** [.pio/build/teensy41/FrameworkArduino/AudioStream.cpp.o] Error 1
    In file included from /home/pi/.platformio/packages/framework-arduinoteensy/cores/teensy4/wiring.h:45:0,
    from /home/pi/.platformio/packages/framework-arduinoteensy/cores/teensy4/WProgram.h:45,
    from /home/pi/.platformio/packages/framework-arduinoteensy/cores/teensy4/Arduino.h:6,
    from /home/pi/.platformio/packages/framework-arduinoteensy/cores/teensy4/Blink.cc:3:
    /home/pi/.platformio/packages/toolchain-gccarmnoneeabi/arm-none-eabi/include/c++/5.4.1/type_traits:39:29: fatal error: bits/c++/config.h: No such file or directory
    compilation terminated.
    *** [.pio/build/teensy41/FrameworkArduino/Blink.cc.o] Error 1
    In file included from /home/pi/.platformio/packages/framework-arduinoteensy/cores/teensy4/wiring.h:45:0,
    from /home/pi/.platformio/packages/framework-arduinoteensy/cores/teensy4/WProgram.h:45,
    from /home/pi/.platformio/packages/framework-arduinoteensy/cores/teensy4/Arduino.h:6,
    from /home/pi/.platformio/packages/framework-arduinoteensy/cores/teensy4/EventResponder.cpp:34:
    /home/pi/.platformio/packages/toolchain-gccarmnoneeabi/arm-none-eabi/include/c++/5.4.1/type_traits:39:29: fatal error: bits/c++/config.h: No such file or directory
    compilation terminated.
    *** [.pio/build/teensy41/FrameworkArduino/EventResponder.cpp.o] Error 1
    ================================================== =============================== [FAILED] Took 3.25 seconds ================================================== ===============================
    The terminal process terminated with exit code: 1

  6. #6
    Junior Member
    Join Date
    Aug 2020
    Posts
    9
    another useful informations...

    pi@raspberrypi:~/Documents/PlatformIO/Projects/blinka $ platformio update
    Updating contrib-piohome @ 3.2.3 [Up-to-date]
    Updating contrib-pysite @ 2.37.191020 [Up-to-date]
    Updating tool-unity @ 1.20500.200612 [Up-to-date]
    Updating tool-scons @ 3.30102.0 [Up-to-date]

    Platform Manager
    ================
    Platform Teensy
    --------
    Updating teensy @ 4.11.0 [Up-to-date]
    Updating toolchain-atmelavr @ 1.50400.190710 [Up-to-date]
    Updating toolchain-gccarmnoneeabi @ 1.50401.0 [Up-to-date]
    Updating framework-arduinoteensy @ 1.153.0 [Up-to-date]


    Library Manager
    ===============
    Library Storage: /home/pi/.platformio/lib

  7. #7
    Member
    Join Date
    Apr 2020
    Location
    Germany, NRW
    Posts
    85
    I use platform.io all the time. Usually the platformio.ini file which gets generated is ok, it would look like this:

    Code:
    [env:teensy41]
    platform = teensy
    board = teensy41
    framework = arduino

  8. #8
    Junior Member
    Join Date
    Aug 2020
    Posts
    9
    Quote Originally Posted by mstiller View Post
    I use platform.io all the time. Usually the platformio.ini file which gets generated is ok, it would look like this:

    Code:
    [env:teensy41]
    platform = teensy
    board = teensy41
    framework = arduino
    Mine platformio.ini file also looks same like yours. But while building it says that bits/c++config.h: No such file or directory.....

    Hence the code not getting compiled.

  9. #9
    Senior Member houtson's Avatar
    Join Date
    Aug 2015
    Location
    Scotland
    Posts
    101
    hi jishnuch

    compiling for 4.1 works fine for me with the standard ini file like above.

    i'm using: Teensy 4.11.0 on a mac with macOS10.15.

    If you change the env to Teensy 4.0 does that compile ok?

    Cheers Paul

  10. #10
    Senior Member
    Join Date
    Dec 2015
    Posts
    133
    @speed12 Ah thank you very much, that does help!!!

Posting Permissions

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