mirror of
https://github.com/espressif/openthread.git
synced 2026-07-10 22:30:21 +00:00
OpenThread on CC2538 Example
This directory contains example platform drivers for the Texas Instruments CC2538.
The example platform drivers are intended to present the minimal code necessary to support OpenThread. As a result, the example platform drivers do not necessarily highlight the platform's full capabilities.
Toolchain
Download and install the GNU toolchain for ARM Cortex-M.
Build Examples
$ cd <path-to-openthread>
$ ./bootstrap
$ make -f examples/Makefile-cc2538
After a successful build, the elf files are found in
<path-to-openthread>/output/bin. You can convert them to bin
files using arm-none-eabi-objcopy:
$ arm-none-eabi-objcopy -O binary arm-none-eabi-ot-cli arm-none-eabi-ot-cli.bin
Flash Binaries
Compiled binaries may be flashed onto the CC2538 using the Serial Bootloader Interface or JTAG interface. The cc2538-bsl.py script provides a convenient method for flashing a CC2538 via the UART.
Interact
- Open terminal to
/dev/ttyUSB1(serial port settings: 115200 8-N-1). - Type
helpfor list of commands.
> help
help
channel
childtimeout
contextreusedelay
extaddr
extpanid
ipaddr
keysequence
leaderweight
masterkey
mode
netdataregister
networkidtimeout
networkname
panid
ping
prefix
releaserouterid
rloc16
route
routerupgradethreshold
scan
start
state
stop
whitelist