This repo 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.
Download and install the GNU toolchain for ARM Cortex-M.
In a Bash terminal, follow these instructions to install the GNU toolchain and other dependencies.
$ cd <path-to-ot-cc2538>
$ ./script/bootstrap
In a Bash terminal, follow these instructions to build the cc2538 examples.
$ cd <path-to-ot-cc2538>
$ ./script/build
If the build completed successfully, the elf
files may be found in <path-to-cc2538>/build/bin/
.
To flash the images with Flash Programmer 2, the files must have the *.elf
extension.
$ cd <path-to-cc2538>/build/bin/cli/ot-cli-ftd
$ cp ot-cli-ftd ot-cli-ftd.elf
To load the images with the serial bootloader, the images must be converted to bin
. This is done using arm-none-eabi-objcopy
$ cd <path-to-cc2538>/build/bin/cli/ot-cli-ftd
$ arm-none-eabi-objcopy -O binary ot-cli-ftd ot-cli-ftd.bin
The cc2538-bsl.py script provides a convenient method for flashing a CC2538 via the UART. To enter the bootloader backdoor for flashing, hold down SELECT for CC2538DK (corresponds to logic '0') while you press the Reset button.
- Open terminal to
/dev/ttyUSB1
(serial port settings: 115200 8-N-1). - Type
help
for list of commands. - See OpenThread CLI Reference README.md to learn more.
We would love for you to contribute to OpenThread and help make it even better than it is today! See our Contributing Guidelines for more information.
Contributors are required to abide by our Code of Conduct and Coding Conventions and Style Guide.
OpenThread is released under the BSD 3-Clause license. See the LICENSE
file for more information.
Please only use the OpenThread name and marks when accurately referencing this software distribution. Do not use the marks in a way that suggests you are endorsed by or otherwise affiliated with Nest, Google, or The Thread Group.
OpenThread support is available on GitHub:
- Bugs and feature requests pertaining to the OpenThread on CC2538 Example — submit to the openthread/ot-cc2538 Issue Tracker
- OpenThread bugs and feature requests — submit to the OpenThread Issue Tracker
- Community Discussion - ask questions, share ideas, and engage with other community members