Remote E-Stop Button Status in ROS

Hello,

I would like to know in ROS if an E-Stop button is pushed on the unit (either the remote button or on the cabinet). Is there a way to see this information in a topic? Or could it be easily added with HAL?

Note that I am not using pathpilot. I am using the raw ROS system on the za6 because I already have a large ecosystem of ROS code.

Currently, if a user tries to start a move when the e-stop is pressed, the trajectory execution fails with PATH_TOLERANCE_VIOLATED, and I am hoping to give a more user friendly explanation as to why the move was not performed, so knowing if an E-Stop is pressed would be very helpful.

Thanks