The etsi_its_conversion
package converts etsi_its_msgs
ROS messages to and from UPER-encoded udp_msgs/msg/UdpPacket
payloads. This allows to build simple ROS drivers for common V2X OBUs and RSUs. This page contains instructions to connect common V2X hardware to ROS.
Tested V2X Hardware
- Run an application on the MK5/MK6 that forwards raw V2X message payloads to a UDP port on a host computer.
- Bridge the UDP packets to ROS messages.
- Run the
etsi_its_conversion
node to convert the UDP packets to and frometsi_its_msgs
ROS messages.
- To follow the documentation links, access to the Cohda Wireless support portal is required.
- The MK5/MK6 is connected to a host computer and IP addresses of both devices are known.
- The following was tested successfully with MK5 firmware
mk5-19.Release.139237-RSUETSI-typical
and a stock MK6 firmware. - The following only describes the setup for bridging received V2X messages to ROS. The other way, sending V2X messages from ROS via ITS-G5, should work similarly.
- Install the
exampleETSI
application to/mnt/rw
. [Documentation] You may also install and configure any other (custom) application that supports forwarding V2X messages via UDP. - Configure forwarding of BTP packets to the host computer via UDP in
/mnt/rw/exampleETSI/obu.conf
or/mnt/rw/exampleETSI/rsu.conf
. [Documentation]ItsFacilitiesShellEnabled = 1; 0, 1 # Enables / Disables support Facilities Shell interface ItsUdpBtpIfHostName = 192.168.140.12 # hostname for sending BTP Data Ind to Shell ItsUdpBtpIfIndPort = 4400; 1,65535 # port number for sending BTP Data Ind to Shell ItsUdpBtpIfReqPort = 4401; 1,65535 # port number for receiving BTP Data Req from Shell ItsBtpShellDestPort = 65535; 0,65535
- (optional) Reduce GeoNetworking security strictness in the same file.
ItsGnSnDecapResultHandling = 1; 0,1 # GN security strictness - STRICT (0), NON-STRICT (1)
- Start the application or enable auto-start. [Documentation]
# root@MK5:/mnt/rw/exampleETSI# rc.exampleETSI start obu # or rsu
- Install the
udp_driver
andetsi_its_conversion
ROS packages.sudo apt install \ ros-$ROS_DISTRO-transport-drivers \ ros-$ROS_DISTRO-etsi-its-conversion
- Configure the
udp_driver
node responsible for bridging the UDP packets received from the MK5/MK6 toudp_msgs/msg/UdpPacket
ROS messages.# config.udp_driver.yml /**/*: ros__parameters: ip: "192.168.140.12" # same as ItsUdpBtpIfIndHostName port: 4400 # same as ItsUdpBtpIfIndPort
- Configure the
etsi_its_conversion
node responsible for converting the UPER-encodedudp_msgs/msg/UdpPacket
payloads toetsi_its_msgs
.# config.etsi_its_conversion.yml /**/*: ros__parameters: has_btp_destination_port: true btp_destination_port_offset: 8 etsi_message_payload_offset: 78 ros2udp_etsi_types: - cam - cam_ts - cpm_ts - denm - mapem_ts - spatem_ts - vam_ts udp2ros_etsi_types: - cam - cpm_ts - denm - mapem_ts - spatem_ts - vam_ts
- Launch the
udp_driver
node.ros2 run udp_driver udp_receiver_node_exe --ros-args --params-file ./config.udp_driver.yml -r /udp_read:=/converter/udp/in ros2 lifecycle set /udp_receiver_node 1 ros2 lifecycle set /udp_receiver_node 3
- Receive, e.g., encoded CAMs on
/converter/udp/in
.ros2 topic echo /converter/udp/in
- Launch the
etsi_its_conversion
node.ros2 run etsi_its_conversion etsi_its_conversion_node --ros-args --params-file ./config.etsi_its_conversion.yml
- Receive, e.g., CAMs on
/converter/cam/out
.ros2 topic echo /converter/cam/out
- The cube:evk natively supports
etsi_its_msgs
ROS 2 messages. - Launch the cube-its ROS 2 framework on the cube:evk to directly receive and send messages from ROS.
- The cube:evk is connected to a host computer and IP addresses of both devices are known.
- Launch the cube-its ROS 2 framework.
start-its --remote
- Install the
etsi_its_msgs
ROS packages.sudo apt install \ ros-$ROS_DISTRO-etsi-its-msgs
- Configure the ROS 2 domain to receive ROS messages remotely from the cube:evk.
export ROS_DOMAIN_ID=42 export ROS_LOCALHOST_ONLY=0
- Receive, e.g., CAMs on
/its/cam_received
.ros2 topic echo /its/cam_received
- Send, e.g., CAMs by publishing to
/its/cam_provided
ros2 topic pub /its/cam_provided etsi_its_cam_msgs/msg/CAM "{}"