ros2_control publish/subscribe topic & action? good or bad?
Situation:
I implemented a ros2_control hardware interface and custom controller for my mecanum wheeled robot. This all works fine for driving the wheeled robot, but what would be best practice for implementing "actions" like emergency brake or sending sensor information like bumpers state? In case the robot hit something, the read() method will get the information from the board and can have internal state to make the robot stop. Still i want this information available in other nodes as well. Also other nodes might have a reason as well to make sure the robot stops imideatly.
Is it a good or bad idea to publish & subscribe directly inside the hardware interface or should i try to get this information trough joints and handle it in the custom controller?
Kind regards,