Devicetree
A devicetree is a hierarchical data structure primarily used to describe hardware. Zephyr uses devicetree in two main ways:
to describe hardware to the Device Driver Model
to provide that hardware’s initial configuration
This page links to a high level guide on devicetree as well as reference material.
Devicetree Guide
The pages in this section are a high-level guide to using devicetree for Zephyr development.
- Introduction to devicetree
- Design goals
- Devicetree bindings
- Devicetree access from C/C++
- Phandles
- The
/zephyr,usernode - Devicetree HOWTOs
- Troubleshooting devicetree
- Try again with a pristine build directory
- Use Devicetree diagnostics tool (DT Doctor)
- Make sure <devicetree.h> is included
- undefined reference to
__device_dts_ord_<N> - Make sure you’re using the right names
- Look at the preprocessor output
- Do not track macro expansion
- Validate properties
- Check for missing bindings
- Errors with DT_INST_() APIs
- Devicetree versus Kconfig
Devicetree Reference
These pages contain reference material for Zephyr’s devicetree APIs and built-in bindings.
For the platform-independent details, see the Devicetree specification.