It is recommended to use Cyphal communicator in new designs.
DroneCAN communicator converts DroneCAN messages to ROS and vice versa.
It covers a minimal set of sensors required for such applications as Ardupilot/PX4 DroneCAN HITL simulation. This communicator can be used for other purposes as well.
The tables below represent the supported conversions:
DroneCAN->ROS
№ | Brige name | ROS msg | DroneCAN msg |
---|---|---|---|
1 | RawCommandUavcanToRos | sensor_msgs/Joy | esc::RawCommand |
2 | ArrayCommandUavcanToRos | sensor_msgs/Joy | actuator::ArrayCommand |
3 | ArmUavcanToRos | std_msgs::Bool | safety::ArmingStatus |
4 | AhrsSolutionUavcanToRos | sensor_msgs::Imu | ahrs::AhrsSolution |
5 | EscStatusUavcanToRos | mavros_msgs::ESCTelemetryItem | esc::Status |
6 | CircuitStatusUavcanToRos | mavros_msgs::BatteryStatus | power::CircuitStatus |
ROS->DroneCAN
№ | Brige name | ROS msg | DroneCAN msg |
---|---|---|---|
1 | BaroStaticTemperatureRosToUavcan | std_msgs/Float32 | air_data::StaticTemperature |
2 | BaroStaticPressureRosToUavcan | std_msgs/Float32 | air_data::StaticPressure |
3 | DiffPressureRosToUavcan | std_msgs/Float32 | air_data::RawAirData |
4 | GpsRosToUavcan | sensor_msgs/NavSatFix | gnss::Fix2 |
geometry_msgs/Twist | gnss::Fix2 | ||
5 | ImuRosToUavcan | sensor_msgs/Imu | ahrs::RawIMU |
6 | MagnetometerRosToUavcan | sensor_msgs/MagneticField | ahrs::MagneticFieldStrength |
7 | EscStatusRosToUavcan | mavros_msgs::ESCTelemetryItem | esc::Status |
8 | IceReciprocatingStatusRosToUavcan | mavros_msgs::ESCStatusItem | ice::reciprocating::Status |
9 | IceFuelTankStatusRosToUavcan | std_msgs/UInt8 | ice::FuelTankStatus |
10 | BatteryInfoRosToUavcan | sensor_msgs/BatteryState | power::BatteryInfo |
You need to perform the following steps to use this package:
- Clone this repository using recursive. Update submodules every time you pull this repo
- Install required packages using
install_requirements.sh
script - Build libuavcan v0.1 as a static library and install it on the system globally
- (optionally) Build DSDL if you want to use custom messages
cd catkin_ws/src
git clone --recursive git@github.com:RaccoonlabDev/uavcan_communicator.git
cd uavcan_communicator
git submodule update --init --recursive
./scripts/install.sh
- At first, you need to create a virtual can port
- Then specify in
config/params.yaml
which conversions do you need to use - Then launch communicator typing:
Example:
roslaunch uavcan_communicator example_communicator.launch
Below you can see an example of using the uavcan_communicator in conjunction with a VTOL dynamics simulator.