Teensyduino 1.21 + Arduino 1.6.1 Libraries Location?

quarterturn

Well-known member
Why does the Teensyduino 1.21 install put selected libraries into ./Applications/Arduino.app/Contents/Resources/Java/hardware/teensy/avr/libraries/ vs ~/Documents/Arduino/Libraries? What about ./Applications/Arduino.app/Contents/Resources/Java/hardware/arduino/avr/libraries/ and ./Applications/Arduino.app/Contents/Resources/Java/hardware/arduino/sam/libraries/, and the one I am most familiar with, ./Applications/Arduino.app/Contents/Resources/Java/libraries?

If I need to make changes to a library, ie. FastLLED, should I put my version into my home path for libraries? Will it override the default?

Thanks!
 
Why does the Teensyduino 1.21 install put selected libraries into ./Applications/Arduino.app/Contents/Resources/Java/hardware/teensy/avr/libraries/

Because that location is least likely to interfere with any other boards.

If I need to make changes to a library, ie. FastLLED, should I put my version into my home path for libraries? Will it override the default?

Yes, the Arduino IDE allows you override all other locations by placing it into your sketchbook libraries folder.
 
placing it into your sketchbook libraries folder

Paul: Have you tested that? Not sure it is working as expected - unless I'm missing something in my effort?

I put a modified ILI9341 library in my sketches\libraries ("C:\tCode\libraries\git-github.com-Defragster-ILI9341_t3.git\ILI9341_t3.cpp") and I had to rename the "I:\Teensy161\hardware\teensy\avr\libraries\ILI9341_t3\ILI9341_t3.cpp.txt"&.h.txt to get it to be used.
 
Thanks, Paul. This explains why, under 1.6.1 and Teensyduino 1.21 I wasn't seeing any libraries. I was using an Arduino Leonardo, which is the same MCU as the classic Teensy but isn't 'teensy' hardware.

So I guess if I copy the teensy libraries back to my home path, they'll be available to the other AVR-based boards.

I understand why you're doing this, though, since we now have non-AVR MCUs.
 
More changes are coming to Arduino soon (not my doing), regarding how libraries are managed. I can't share details at this time. But I can tell you, things will again be changing.

As always, I will try to provide the best experience possible for Teensy users, and I try to share and contribute improvements in general with the Arduino community.

I also generally try to avoid Teensy unexpectedly changing behavior on non-Teensy boards, even if those changes would be beneficial. With Arduino 1.6.x, the Arduino devs added better ways to avoid conflicts, so I'm using them. My position is generally that I publish all this stuff as open source AND I also go to quite a bit of extra effort to work with the Arduino devs (sometimes a *lot* of extra effort). That feels like the correct path for Teensy developed improvements to make their way to non-Teensy users.
 
On a Mac, control-click Arduino and select "show package contents". That will let you navigate to all the folders and files inside.

Inside, the libraries are placed into Contents/Resources/Java/hardware/teensy/avr/libraries or Contents/Java/hardware/teensy/avr/libraries, depending on which Mac version of Arduino you installed: "java 6 (recommended)" or "java 7+ (experimental)".
 
Thanks Paul. I hadn't thought to show package contents. I forgot that that was where the default install was.
 
Back
Top