/
Compilation
Compilation
The routine to compile dronecan packet definitions into .c and .h files.
Dependencies
Make sure a recent-ish version of python and pip is installed (I used python 3.10.12 and pip 25.0.1)
In a convenient place (I used my Documents folder) on your computer, run the following from:
mkdir -p dronecan_datatype_compiler
cd dronecan_datatype_compiler
pip install empy==3.3.4
pip install pexpect
git clone https://github.com/dronecan/dronecan_dsdlc
git clone https://github.com/dronecan/pydronecan
git clone https://github.com/dronecan/DSDL
git clone https://github.com/dronecan/libcanard
Steps
All packets should have the
.uavcan
extension and be placed in a folder namedwarg
. You can nest this in other folders if you want, for example:
root/
|- Core
|- dsdlc_generated/
|- src/
|- inc/
|- packets/
|- warg/
|- SetControlState.uavcan
Ensure you are in the
dronecan_datatype_compiler
folder you made during setupRun
cp -r /path/to/root/packets/warg .
Run
python dronecan_dsdlc/dronecan_dsdlc.py -O /path/to/root/Core/dsdlc_generated` DSDL/ardupilot DSDL/com DSDL/cuav DSDL/dronecan DSDL/uavcan warg
, multiple selections available,
Related content
Using libcanard for DroneCAN
Using libcanard for DroneCAN
More like this
Integration
Integration
More like this
Dronekit-python fork
Dronekit-python fork
More like this
DroneKit-Python
DroneKit-Python
More like this
Ardupilot CAN interfacing over Lua scripts
Ardupilot CAN interfacing over Lua scripts
More like this
Custom Dronecan Packets
Custom Dronecan Packets
More like this