Difference between revisions of "Explorer/RaspberryPi/Autopilot/Proxy"
Jump to navigation
Jump to search
Line 11: | Line 11: | ||
export PPRZ_LINK_IN=4242 | export PPRZ_LINK_IN=4242 | ||
export PPRZ_LINK_OUT=4243 | export PPRZ_LINK_OUT=4243 | ||
# | PPRZ_LINK_IP:PPRZ_LINK_IN | # | PPRZ_LINK_IP:PPRZ_LINK_IN | ||
# /dev/tty -> | | # /dev/tty -> | |
Revision as of 10:05, 9 July 2020
Dowload pprzlink from https://github.com/paparazzi/pprzlink
(keep the name "pprzlink" for the repository)
cd /home/pi/pprzlink
./tools/generator/gen_messages.py --protocol 2.0 --lang C_standalone -o build/pprzlink/datalink_msg.h message_definitions/v1.0/messages.xml datalink --opt SETTING,GUIDED_SETPOINT_NED
./tools/generator/gen_messages.py --protocol 2.0 --lang C_standalone -o build/pprzlink/telemetry_msg.h message_definitions/v1.0/messages.xml telemetry --opt ROTORCRAFT_FP
#!/bin/bash export PPRZ_LINK_IP=192.168.1.46 export PPRZ_LINK_IN=4242 export PPRZ_LINK_OUT=4243 # | PPRZ_LINK_IP:PPRZ_LINK_IN # /dev/tty -> | # | 4246 -> | # | uplink -> | # | 4245 -> | | 4244 -> /dev/tty # PPRZ_LINK_OUT -> | -> | /home/pi/muxer/exe/uplink 4244 4245 4246 & socat -u udp-listen:4244,reuseaddr,fork /dev/ttyAMA0,raw,echo=0,b115200 & socat - /dev/ttyAMA0,raw,echo=0,b115200 | tee >(socat - udp-sendto:127.0.0.1:4246) >(socat - udp-sendto:$PPRZ_LINK_IP:$PPRZ_LINK_IN) > /dev/null & socat - udp-listen:4243 | tee >(socat - udp-sendto:127.0.0.1:4244) >(socat - udp-sendto:127.0.0.1:4245) > /dev/null &