GitHub

Fox Red Labs / Software / Move across TI chips / One app, eleven boards

One C file, eleven TI boards

The same app.c reads the ADC, prints a line, blinks the LED, once a second. It ran unchanged on eleven TI boards, from an MSPM0C1104 with 1 kB of RAM to an AM62L running Linux. Moving it to another TI chip costs one small glue file per family. If you know Arduino: app.c is your sketch, and the glue file is the board core, written once per family.

The last line each board printed on its serial port: t is seconds since start, adc the raw reading, avg the 4-reading average
  1. LP-MSPM0L1306t=13 adc=2645 avg=2644
  2. LP-MSPM0C1104t=19 adc=549 avg=536
  3. LP-MSPM0G5187t=18 adc=1449 avg=1449
  4. LP-MSPM0G3519t=14 adc=1085 avg=1085
  5. LP-MSPM33C321At=24 adc=3165 avg=3184
  6. LP-AM13E230t=9 adc=128 avg=128
  7. LP-EM-CC2340R5t=22 adc=1368 avg=1368
  8. LP-EM-CC2755P10t=32 adc=1374 avg=1374
  9. LP-EM-CC35X1t=16 adc=1210 avg=1182
  10. LAUNCHXL-F2800137t=14 adc=2035 avg=2036
  11. TMDS62LEVMt=13 adc=1032 avg=1032
0lines of app.c changed on any of the 11 boards
35 to 66lines of glue per chip familyPlus 5 to 41 lines of board setup. Boards in the same family share one glue file.

What a move costs, family by family

Each card is one glue file. Moving inside a family means a new setup file only (SysConfig, TI's pin and peripheral setup tool, writes most of it); moving to a new family means a new glue file. DriverLib is TI's plain C library for each chip's peripherals; TI Drivers is the portable layer above it. The ADC readings differ because each board reads a different input.

MSPM0

39lines of glue, shared by 4 boards

30 to 34 lines of board setup · 2.3 kB to 2.4 kB flash · DriverLib, no operating system

One glue file for all four boards. Each board adds only its SysConfig file: pins, ADC channel, UART.

Works LP-MSPM0L1306, LP-MSPM0C1104, LP-MSPM0G5187, LP-MSPM0G3519

CC23xx, CC27xx, CC35xx radios

48lines of glue, shared by 3 boards

14 lines of board setup · 18.4 kB to 20.7 kB flash · TI Drivers on FreeRTOS

One glue file across the Bluetooth and Wi-Fi boards and two SDKs. The size is mostly FreeRTOS and the drivers.

Works LP-EM-CC2340R5, LP-EM-CC2755P10, LP-EM-CC35X1

MSPM33

37lines of glue

41 lines of board setup · 2.8 kB flash · DriverLib

The MSPM0 calls for UART, LED and delay. Only the ADC call is new: this chip has a high-speed ADC instead.

Works LP-MSPM33C321A

AM13

38lines of glue

35 lines of board setup · 9.2 kB flash · AM13 DriverLib

A sequencer-style ADC: start a conversion, then wait for its flag. Most of the RAM is the SDK's stack and heap.

Works LP-AM13E230

C2000

35lines of glue

29 lines of board setup · 4.9 kB flash · C2000Ware driverlib

Setup is C calls in board_init, with no SysConfig. Its 29 lines include a 5-line header that defines uint8_t, a type C2000 compilers leave out because the chip has no 8-bit byte.

Works LAUNCHXL-F2800137

AM62L, Linux

66lines of glue

5 lines of board setup · 66.1 kB Linux program file, not flash · Linux files under /sys

No driver code at all: the glue reads the ADC and drives the LED through Linux's sysfs files. Same app.c, compiled with GCC.

Works TMDS62LEVM

What goes in a glue file

Five calls, and nothing else in the app touches the chip. To bring the app to a board that is not here, write these five for it, starting from the glue file of the closest family.

board_initclocks and pins
adc_readone ADC reading
uart_writesend the line
led_toggleflip the LED
sleep_mswait a second

Run it on your board

Build every image (about 3 minutes, no board needed), then flash your board's image and check its serial output. The checker prints PASS when the lines arrive once a second and the average adds up, or FAIL: and what was wrong. Per-board flash commands are in the folder README.

portability/three-ways/build_all.sh
python3 portability/three-ways/serial_check.py /dev/cu.usbmodemXXXX1 12 run.txt

Replace /dev/cu.usbmodemXXXX1 with your board's serial port (ls /dev/cu.usbmodem* lists them). Back up your board first: flashing overwrites the main flash.

Limits

Sources and run details

App, glue and setup files: the three ways folder. Line counts are code lines (no blank or comment-only lines) from count.py. Glue, setup, flash and RAM numbers are rows in each board's results file in the results folder (tests app_glue_lines, app_config_lines, port_flash_bytes, port_ram_bytes), dated 2026-10-25. Flash is the linker map's used total (for the C1104 and G3519, the text size tiarmsize reports from the same build); the AM62L size is the stripped, dynamically linked program. Console captures: portability/three-ways/logs/run-*.txt. Built on macOS with TI Arm Clang 5.1.1 (MSPM0, MSPM33, AM13, radios), the C2000 compiler from C2000Ware (F2800137) and GCC 14 on the board (AM62L). The test is also on Move across TI chips.