Programming Teensy 3.6 without Arduino IDE.

Status
Not open for further replies.
I want to learn how to program ARM processors using embedded C for my Embedded Systems course. Hence I don't want to use the Arduino IDE & Libraries(Teensyduino). I already own a Teensy 3.6. I have programmed an 8051 before & I am going to start simulating code (& circuits) on an LPC2103 using Keil & Proteus. But since I have a Teensy, I want to start building physical projects using embedded C only.

I have read(forums) which suggest that the Teensy 3.x use a bootloader chip with proprietary code. This would make it simply not possible to program the Teensy 3.6 without using the Teensyduino software. Is this true?

How do I go about burning my Embedded C code into the Teensy 3.6?
Which are the recommended IDE's & compilers for programming the Teensy 3.6 in Embedded C?
 
So, no C++?
well, all the code (C,C++,Makefile) is in https://github.com/PaulStoffregen/cores/tree/master/teensy3
you have to find and download ARM compiler that understand embedded C extensions and generate hex files
you can download the code to teensy with command line loader https://github.com/PaulStoffregen/teensy_loader_cli

Or you make yourself life easier and download Arduino and install Teensyduino, where all you need is bundled, and program in plain and regular C.
You can still use any editor to create a program, use the makefile to compile and the command line loader to download program

you can install eclipse, visual studio, use keil, if it is only the IDE that bothers you
or buy yourself a non-teensy ARM processor that you have to program with debugger/HW-programmer.
 
Re the bootloader IC, the code it runs is closed source, but all it is doing is getting code into the main chip RAM to bring up USB to get a hex file from the PC, and that protocol is open(ish) - see below. Making your hex file is a case of firing a compiler that knows ARM at the language of your choice.

While the easiest way to get code onto a Teensy is the Teensyduino download program you get with an Arduino install (and would suggest using that as a saniety check first) there is a common line version + source available to either use in a script or embed into something bigger, or even turn into your own IDE.
 
If I understand the question - any files installed with TeensyDuino are designed for use with the IDE and toolchain provided. As noted a makefile interface to the toolchain can be used in place of the IDE.

If using an alternate ARM toolchain - those processor definition files would be unique to the tools in use and need to be found or defined.
 
I'm just starting ARM programming. I really don't know what a makefile is. I'm currently going to try and upload the code to my Teensy 3.6 using Platformio & the kinets.h header file functions.
 
If you're just beginning, I highly recommend using the Arduino IDE until you've gained some experience. You can still edit the core library files, and you have full access to all hardware registers and features from the Arduino code. Do yourself a favor and use the easy tool path, so you can focus on learning the hardware. Mess with the tools later, after you've learned more...

Also, if you're going to get into the low-level details, you really should buy this book:

https://www.amazon.com/dp/0124080820

You can get the reference manual here, but it only covers the peripherals from Freescale. For the ARM part, you need that book.

https://www.pjrc.com/teensy/datasheets.html
 
I know this is an older thread, but Paul, do you use something other than Arduino IDE? Curious what options are out there while maintaining compatibility with your libraries.
 
One notable alternative is Sloeber. That‘s a package of the well renowned multi-platform Eclipse IDE and a an Arduino specific plugin from a guy called Jantje. After the Sloeber installation, you have to setup the Hardware Definition path only once, pointing towards your Arduino/Teensyduino installation, and it will pick all required information from there and you can work fully in Eclipse, having your sketch in one tab and if needed, library files in another tab, so you can edit libraries or even the core files at the same time as your sketch. You can lookup core and library function and constant definitions with a Hotkey which makes writing code much more comfortable that with the Arduino IDE.
 
Status
Not open for further replies.
Back
Top