SITL with Companion Computer under ROS

Hello,

I would like to use a companion computer (nvidia jetson xavier nx) to perform SLAM / obstacle avoidance with a lidar on a UAV.
I have installed ROS under ubuntu 19.04 on the CC with mavros to communicate with the autopilot. Before realising flight tests I would like to use SITL to simulate simple avoidance object. I have installed SITL on Windows to connect with MissionPlanner easily. I can run it, using joystick and visualizing data on MP.
For now, I would set up the communication between my companion computer (under ROS on ubuntu) and SITL (on Windows) to send OBSTACLE_DISTANCE messages but I am having some trouble with the link.
I am connected using an UART to USB adapter, on my jetson, I have configured mavros to send over the /dev/ttyTHS0 at 921600 bd/s and I would receive it throught the COM15 on SITL.
I have followed this tutorial : https://ardupilot.org/dev/docs/sitl-native-on-windows.html

I tried adding a link on the SITL console, but it prints “link 2 down”.
I tried adding args : -A “uartC=uart:/dev/ttyS14” (the com port associated to the UART-USB on cygwin), adding SERIAL2_BAUD=921 and SERIAL2_PROTOCOL=1 in ardupilot/Tools/autotest/default-params/copter.parm

Nothing have worked and I have no idea to continue, can anyone help me ?
Thank you in advance.

1 Like