ROS2 Publisher Safety Level

This block reads the safety level id and packs it into a ROS message of type std_msgs::msg::String. Each time the block is run by its time domain, this message is published under a given topic name.

  RosPublisherSafetyLevel pubSL(node, "myTopic"); // create publisher block

This block must have a reference to the safety system in order to read the actual safety level. Please set the reference by calling:

  controlSystem.pubSL.setSafetySystem(safetySystem);