Skip to content

Commit 50e1715

Browse files
committed
updated mavlink code generation instructions
1 parent d70511b commit 50e1715

File tree

2 files changed

+13
-12
lines changed

2 files changed

+13
-12
lines changed

comms/mavlink/generating_v1.0_instructions.txt

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -5,20 +5,20 @@ git clone https://github.com/rosflight/mavlink.git
55
# Put the rosflight.xml file there if not already there
66

77
# Create the .c/h files from that directory
8-
# If python3 doesn't work install Python2.7 and run with python2.7 instead.
8+
# If python3 doesn't work try installing future (pip install future).
9+
# If that doesn't work install Python2.7 and run with python2.7 instead.
910
# in windows:
1011
rmdir /s v1.0
11-
1212
set PYTHONPATH=%PYTHONPATH%;path\to\mavlink\repo && python3 -m pymavlink.tools.mavgen --lang=C --wire-protocol=1.0 --output=./v1.0 rosflight.xml
13+
1314
# e.g.,
1415
rmdir /s v1.0
15-
1616
set PYTHONPATH=%PYTHONPATH%;C:\Projects\mavlink && python3 -m pymavlink.tools.mavgen --lang=C --wire-protocol=1.0 --output=./v1.0 rosflight.xml
1717

18-
# in linux:
18+
# in Linux:
1919
sudo rm -r ./v1.0
2020
PYTHONPATH=$PYTHONPATH:/path/to/mavlink/repo python3 -m pymavlink.tools.mavgen --lang=C --wire-protocol=1.0 --output=./v1.0 rosflight.xml
2121

2222
# If you are in the mavlink repo environment with rosflight.xml in the standard location:
23-
python3 -m pymavlink.tools.mavgen --lang=C --wire-protocol=1.0 --output=generated/include/mavlink/v1.0/generated message_definitions/v1.0/rosflight.xml
24-
# copy/paste generated into your rosflight_firmware/comms/mavlink folder
23+
python3 -m pymavlink.tools.mavgen --lang=C --wire-protocol=1.0 --output=generated/include/mavlink/v1.0 message_definitions/v1.0/rosflight.xml
24+
# copy/paste the v1.0 directory into your rosflight_firmware/comms/mavlink folder

comms/mavlink/rosflight.xml

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -7,23 +7,24 @@ git clone https://github.com/rosflight/mavlink.git
77
# Put the rosflight.xml file there if not already there
88

99
# Create the .c/h files from that directory
10-
# If python3 doesn't work install Python2.7 and run with python2.7 instead.
10+
# If python3 doesn't work try installing future (pip install future).
11+
# If that doesn't work install Python2.7 and run with python2.7 instead.
1112
# in windows:
1213
rmdir /s v1.0
13-
1414
set PYTHONPATH=%PYTHONPATH%;path\to\mavlink\repo && python3 -m pymavlink.tools.mavgen --lang=C --wire-protocol=1.0 --output=./v1.0 rosflight.xml
15+
1516
# e.g.,
1617
rmdir /s v1.0
17-
1818
set PYTHONPATH=%PYTHONPATH%;C:\Projects\mavlink && python3 -m pymavlink.tools.mavgen --lang=C --wire-protocol=1.0 --output=./v1.0 rosflight.xml
1919

20-
# in linux:
20+
# in Linux:
2121
sudo rm -r ./v1.0
2222
PYTHONPATH=$PYTHONPATH:/path/to/mavlink/repo python3 -m pymavlink.tools.mavgen --lang=C --wire-protocol=1.0 --output=./v1.0 rosflight.xml
2323

2424
# If you are in the mavlink repo environment with rosflight.xml in the standard location:
25-
python3 -m pymavlink.tools.mavgen --lang=C --wire-protocol=1.0 --output=generated/include/mavlink/v1.0/generated message_definitions/v1.0/rosflight.xml
26-
# copy/paste generated into your rosflight_firmware/comms/mavlink folder?>
25+
python3 -m pymavlink.tools.mavgen --lang=C --wire-protocol=1.0 --output=generated/include/mavlink/v1.0 message_definitions/v1.0/rosflight.xml
26+
# copy/paste the v1.0 directory into your rosflight_firmware/comms/mavlink folder
27+
?>
2728
<mavlink>
2829
<enums>
2930
<!-- ROSflight specific MAV_CMD_* commands -->

0 commit comments

Comments
 (0)