UAVCAN for Hobbiests

@olliw42 thank you for your work on UC4H and sharing it. I have been working on a rangefinder implementation and have a lot of struggles. I have a running node using libcanard of a very simple rangefinder only transmitting the distance. I now want to look at integrating this with a Pixhawk 4 controller running ArduCopter 4.1.2. We will be setting up a Jetson Nano with a USB2CAN adapter as a node for our sensor. In other words the Jetson Nano will be seen as the rangefinder sensor by the pixhawk.

  1. It is unclear to me what UAVCAN datatype ArduCopter uses. Is it uavcan.equipment.range_sensor found here: 7. List of standard data types - UAVCAN

  2. You use a much simpler data type, but I don’t understand how ArduCopter knows what your data type is? On the YouTube video it shows you selecting RNGFND_TYPE = 83. That is not available on my setup. Is that because of an earlier version of ArduCopter or are there some parameters like a parameter file that can be changed to make it available.

Your help would be much appreciated.

@olliw42 I figured out most things. Got Yakut and UAVCAN GUI to read messages … but arducopter still does not read it. Presently working on CRC in range finder message as per the UAVCAN V0 specification.

@hbrenkman i think its a little bit outdated, take a look at
https://ardupilot.org/copter/docs/common-uavcan-setup-advanced.html#common-uavcan-setup-advanced

And the new development
https://ardupilot.org/dev/docs/ap-peripheral-landing-page.html

Thanks @ppoirier I will check these out once the site is up and running. I do see my node using Mission Planner’s SLCAN tool. I made some changes, but still getting the message Rangefinder1 not detected.

This image shows my node, 111.

It does not show the range sensor reading. I can see the range sensor reading with UAVCAN GUI tool. All parameters show correct.

what about the inspector ? does it shows signal ?

So I just noticed that using SLCAN in Mission Planner it reads my measurement also, but still says range finder 1 not detected:

I send i screen shot showing what the inspector shows. These are the settings for RNGFND1:

image

image

I restarted everything and now it reads the rangefinder … so i don’t know what was wrong, so here is a screenshot from QGroundControl:

1 Like