Skip to content

Pinout ​

Every peripheral sits on a hardware block, so the CPU does no bit-banging: PWM for the motors, QEI for the encoders, the ADC for the battery, I2C for the IMU and display. Pin functions are from the TM4C123GH6PM datasheet.

The headers ​

EK-TM4C123GXL J1 to J4 header pinout, top view

EK-TM4C123GXL J1 to J4 header pinout, bottom view

The robot's pins ​

FunctionPinPeripheralStepNote
Status LEDsPF1, PF2, PF3GPIO1On the board
Start and mode buttonsPF4 (SW1), PF0 (SW2)GPIO1PF0 is locked
USB logPA0 / PA1UART02Through the debug USB port
Left motor PWMAPB6M0PWM04Remove R9: it shorts PB6 to PD0
Right motor PWMBPB7M0PWM14Remove R10: it shorts PB7 to PD1
Left AIN1 / AIN2PA6 / PA7GPIO4Direction
Right BIN1 / BIN2PC4 / PC7GPIO4Direction
TB6612 STBYPD2GPIO4Low turns both motors off
Left encoder A / BPD6 / PD7QEI0 PhA0 / PhB05PD7 is locked
Right encoder A / BPC5 / PC6QEI1 PhA1 / PhB15
Battery dividerPD3AIN43
IMU and display SCL / SDAPB2 / PB3I2C06One bus, two addresses. Pull-ups on the modules
Bluetooth RX / TXPB0 / PB1UART112

Remove R9 and R10 before Step 4

The LaunchPad ties PB6 to PD0 and PB7 to PD1 through 0 Ω resistors R9 and R10. With them in place, whatever PD0 and PD1 do fights the motor PWM.

Balance Bot Bootcamp