Close
0%
0%

Arduino-Tiva

An Arduino clone based on a TI's TM4C123G (An ARM M4F running at 80Mhz with USB OTG)

Similar projects worth following
Project Goal

The goal of this project is to build a bridge between Texas Instrument's Tiva™ C LaunchPad, based on the TM4C123GH6PM, and the Arduino form factor. The LaunchPad series of development kits already benefit from an Arduino-like code development environment in the form of Energia, but lack a compatible form factor to make use of the extensive shield ecosystem.

This project aims to merge these two worlds by putting the processing power and integrated peripheral set of the 80-MHz ARM M4F based TM4C123 series of micro controllers into the Arduino-Leo (and Uno, Duemilanove, Due, *Mega) compatible form factor. This will provide typical Arduino users with a much more powerful board while maintaining a familiar programming environment (through either Arduino IDE or Energia). It's also a platform for those wanting to grow beyond this basic development approach into a more low-level IDE by using TI's free Code Composer Studio and selecting the EK-TM4C123GXL

Project Goal (the challenge & solution)

The goal of this project is to build a bridge between Texas Instrument's Tiva™ C LaunchPad, based on the TM4C123GH6PM, and the Arduino form factor. The LaunchPad series of development kits already benefit from an Arduino-like code development environment in the form of Energia, but lack a compatible form factor to make use of the extensive list of shields.

This project aims to merge these two worlds by putting the processing power and integrated peheripherial set of the 80-MHz ARM M4F based TM4C123 series of micro controllers into the Arduino-Leo (and Uno, Duemilanove, Due, *Mega) compatible form factor.

This will provide typical Arduino users with a much more powerful board while maintaining a familiar programming environment (through the use of Energia). It also provides a platform for those wanting to grow beyond this basic development approach into a more low-level IDE (with breakpoints and stepping) by using TI's free Code Composer Studio and selecting the EK-TM4C123GXL project configuration.

I have a target retail cost of $20 per board, but it'll only get there if the demand is there. For the three I built, the cost per board was about $34 with the majority of the cost attributed to the TM4C123 and board fabrication. Volume pricing can cut that by more than half.

*The board breaks out all pins, but only utilizes the basic set of headers to maintain a 2" x 3" form factor.

Project Planning / Features List

✔ Circuit designed using KiCAD

✔ Initial method of programming using an EK-TM4C123GXL dev kit by tapping into its target ICDI JTAG headers

✔ Board layout. Includes placing pins such to be compatible with the Arduino form factor

✔ Board Fabrication (sent to OSH Park 4/16/2017)

✔ Board assembly (2 completed)

✔ Create custom pin map for use in Energia

✔ Be able to compile and flash over LaunchPad in Arduino and Energia IDE's

✔ Add USB Virtual COM enumeration to base sketch

✔ Hook in bootloader init to VCOM connection at 1200 baud

▢ gcc compiler support for Arduino and Energia in

✔ Windows 10
▢ Ubuntu 16

▢ USB DFU flashing support for Arduino and Energia in

✔ Windows 10
▢ Ubuntu 16

▢ Hardware testing and verification

✔ GPIO using Arduino API and integrated ROM drivers
▢ ADC using Arduino API and integrated ROM drivers
▢ PWM using Arduino API
✔ PWM using integrated ROM drivers
✔ I2C using Arduino API
▢ I2C using integrated ROM drivers
✔ SPI using Arduino API and integrated ROM drivers
✔ Serial using Arduino API
▢ Serial using integrated ROM drivers
▢ CAN using Arduino API and integrated ROM drivers

▢ Choose a better name for the board (see comments below)

▢ Small production run if enough people are interested

Probability of a World Changing Event

I suspect this will revolutionize hacker spaces everywhere. As the complexity and computational requirements of projects grow the basic Arduino just won't cut it any longer. This board is the next step in terms of performance, flash and memory size, low power modes, and low cost development and debug options. Will this solve world hunger? Not by itself. But maybe someone, somewhere, will use it to that end.

Specifications

(taken from TI's website)

CPU ARM Cortex-M4F
Pin & Package 64LQFP
Flash (KB) 256
DMA Channels 32
EEPROM (KB) 2
Capture Pins 24
Battery-Backed Hibernation Module Yes
Boot Loader in ROM Yes
Digital Comparators 16
SRAM (kB) 32
CCP Timers 24
Max Speed (MHz) 80
Motion PWM Outputs 16
QEI 2
GPIO 43
Operating Temperature Range (C) -40 to 105
USB D, H/D, or OTG OTG
SSI/SPI 4
I2C 4
UART 8
ADC Channels 12
ADC Resolution (Bits) 12
CAN MAC 2
SysTick Yes
SPI 4


Other notable parameters

  • Most GPIO are 5V tolerant
  • Peripheral libraries are pre-loaded onto on-board ROM, reducing...
Read more »

package_arduino-tiva-board-1.0_index.json

Release version 1.0. Fully functioning for Arduino and Energia on Windows

JavaScript Object Notation (JSON) - 3.92 kB - 06/16/2017 at 20:02

Download

sheet - 11.37 kB - 05/26/2017 at 03:53

Download

Arduino-Tiva Schematic.pdf

Board schematic

Adobe Portable Document Format - 131.70 kB - 05/06/2017 at 10:30

Preview Download

  • 1 × LM1117IMPX-3.3/NOPBCT-ND Power Management ICs / Linear Voltage Regulators and LDOs
  • 1 × 10118192-0001LF Connectors and Accessories / Telecom and Datacom (Modular) Connectors
  • 4 × CL21A226MOCLRNC CAP CER 22UF 16V X5R 0805
  • 1 × GRM188R61C225KE15D Capacitors / Ceramic
  • 1 × LG R971-KN-1 LEDs and Accessories / Light Emitting Diodes (LEDs)

View all 18 components

  • Flashing in Arduino / Energia IDE Complete

    Jacob06/16/2017 at 19:41 1 comment

    I've just completed building, integrating and testing the custom DFU programmer in doth Arduino and Energia. I'll publish the board manager JSON file and support packages to github shortly. I'm pleased with how relatively smooth the integration went. I've learned a lot about integrating custom board support packages into Arduino along the way and will do a write about the process soon since I found it convoluted at first myself.

    The only thing left to do before releasing this into the wild is to add Linux support and do some minor fixes to the board layout.

    If this was crowdfunded for small run of 100 boards, probably priced at $30, would you be in?

  • Flashing in Windows - Progress

    Jacob06/15/2017 at 04:35 0 comments

    I've almost completed putting together the program to initiate DFU mode and flash the board from within Arduino / Energia. It's pieced together from source code provided by TI in their TivaWare sdk. This will be a Windows only flashing tool customized to the boot loader process of this particular board. I've not begun the Linux side yet, but my research tells me that it will be a much easier task. I believe "dfu-util" will work for it with only minor modifications.

  • Now with built in USB Virtual COM support

    Jacob06/10/2017 at 03:08 0 comments

    I'm claiming 95% success in adding USB VCOM support right out of the box. This means the base Arduino sketch will run with USB VCOM enabled. This allows the board to be powered by USB and enumerate as a virtual com port, even with an empty sketch. In practice, it's modeled after the HardwareSerial class, which instantiates an object called "Serial" object before jumping in "loop()" and running the user sketch. This new class creates an instance called "USBSerial".

    So when connected by SB to a host you can use USBSerial.print(), USBSerial.println(), etc to send /receive data over the virtual com port. Additionally, calls to Serial.print, etc. still work, but are tied to the physical pins on the board. If using a TivaC LaunchPad, calls to Serial go over its enumerated debug com port.

    The 95% success is due to the way the boot loader is initiated currently. It works, but not as well as I would like.

    Next Steps: Modify Arduino IDE to initiate boot loader mode after compiling, then upload over the DFU endpoint.

  • USBlib in Arduino and Energia IDE

    Jacob06/07/2017 at 22:32 0 comments

    After spending a long ninght working through the Arduino IDE compile options, I was able to add support for TI's USBlib, which is used as part of the boot loader trigger. I decided to emulate he Arduino Loenardo boot loader process. This board appears as a USB VCOM port and connecting to it at 1200 baud causes it to switch into USB DFU mode.

    Once I get DFU flashing working from the IDE's I'll post an update to the board package and corresponding json index file.

  • Small Progress - Energia Not Necessary

    Jacob06/02/2017 at 03:11 0 comments

    Tonight I just finished creating a JSON index file for the Boards Manager that is compatible with both the Arduino and Energia IDEs. I've successfully tested compilation and flashing through both IDEs. For some reason the current JSON index file was only compatible with Energia, and would cause Arduino IDE to throw java null pointer exceptions. After reworking the file it's properly parsed by both IDEs.

    Something learned along the way:

    When building a custom JSON index file for theBoards Manager, toolsDependencies.packager should match the top level packages.name value where the tools are described.

    For instance when building the new file I had to make in order to have arm-none-eabi-gcc compiler and dslite flasher installed along with this board.

    packages.platforms.toolsDependencies.packager = packages.name
    I'll post the new JSON in the file section here for anyone interested in seeing a working example.

  • Boot Loading...

    Jacob05/27/2017 at 12:34 0 comments

    Just wanted to give big THANKS to all who have liked this project and give some insight as to the direction this is going. Lately I've been working on learning the USB boot loader process for this chip with the goal of being able to use it in a similar manner to how Arduino boards do and eliminating the need for a separate LaunchPad dev kit. One really nice features of this chip are the on board drivers in ROM and the already present and active USB-DFU boot loader. It's activated whenever the flash is erased/empty which allows for fresh-from-assembly programming over USB, without the need for an external hardware programmer. It can also be activated directly from user the application with just a few API calls.

    My next step is to try and integrate this approach into the Energia flashing process. Being able to flash directly from Energia would truly allow for Arduino-like development on this chip.

  • A Few More Items Completed

    Jacob05/21/2017 at 01:18 0 comments

    I completed verifying all hardware PWM and SPI outputs via CCS. I've been creating individual projects for each tested feature. Shortly I'll post these so that they are available to anyone wanting basic examples of how to get each running. They will of course also work on the EK-TM4C123GXL LaunchPad (minus any pinout conflicts).

  • Working Through PWM API

    Jacob05/19/2017 at 17:28 0 comments

    While working trough verifying each function of the chip I've begun to notice that much of the Energia API for hardware features are actually implemented in software (vs. using the on chip hardware). For instance, PWM. The Energia Servo, or PWM, library is actually implemented manually using general purpose timers rather than the integrated PWM module.

    I guess this is fine, but what I'd really like to see is Energia making use of the integrated hardware for these functions. I was tempted to "fix" that and actually spent a few hours attempting to get the TivaC drivers to work in Energia but had no success for PWM. GPIO works though. Ultimately doing this is out of scope for my immediate project so I'll just focus on verifying the rest of the features of the chip and finalize the circuit design and board layout.

  • Hardware Testing Started

    Jacob05/09/2017 at 02:26 0 comments

    Quick update - I've tested all GPIO pins in digital output mode through both Energia and CCS v6.1.1 and All pins are functioning correctly.

    I did some minor rework on the layout by fixing an incorrect pin assignment for D0 and D1 (they were swapped in the schematic) and slightly enlarging the LEGO sized mounting holes and removing the through-hole plating. The holes were exactly 4.8 mm and did not allow for tolerance in LEGO manufacturing. The hole on the board were cutting into a few of the LEGO pieces I tried on it.

    More peripheral testing to come soon.

  • It's Alive!!

    Jacob05/06/2017 at 01:45 0 comments

    I built another board today using only the minimal number of components required to support running the microprocessor. I then tested it and got the same result from LM Flash programmer as I had before - No communication with the board. Surely I had made a mistake in my schematic. I decided to take time later today and hit the forums to see if someone else could spot the mistake.

    I then had a stroke of inspiration. I had left the VDDA and GNDA disconnected on the two boards I tested, thinking they were not important to the initial board bring up. I decided that I should connect them properly and retest. Well... that was the missing element it seems. Taking a look in the datasheet at section 24.6.1 "VDDA Levels", it clearly states

    The POR monitor is used to keep the analog circuitry in reset until the VDDA supply has reached the correct range for the analog circuitry to begin operating. The POK monitor is used to keep the digital circuitry in reset until the VDDA power supply is at an acceptable operational level. The digital Power-On Reset (Digital POR) is only released when the Power-On Reset has deasserted and all of the Power-OK monitors for each of the supplies indicate that power levels are in operational ranges.

    Lesson Learned: Read your chips documentation thoroughly.

    I now have two functioning boards that I can program in Energia and receive serial data over the COMM port monitor. Here are pictures of the the two bards, both in different states of being populated

View all 17 project logs

View all instructions

Enjoy this project?

Share

Discussions

Jacob wrote 06/02/2017 at 03:21 point

It's about time I came up with a proper name for this thing since Tiva is actually trademarked. Any suggestions?

Some ideas I am throwing around are:

TI-M4U

Armchair

ShieldMaiden-4U

Ollie Board

Easy ARM

Armduino

ARTI 256 (ARduino-TIva 256K)

  Are you sure? yes | no

Similar Projects

Does this project spark your interest?

Become a member to follow this project and never miss any updates