Checking for error status of robot system with URScript

Hello,

I would like to set a standard digital output when the robot programm is stopped due to an error.
A lamp that is connected to this output should inform the operator in case things are not running
correctly e.g. the robor was stopped because of a collision.
Is there way, that a URScript thread can check for the status of the robot controller?

Best regards
Achim

You can setup a digital output to go low on an unscheduled stop through the “IO Setup” in the Installation node. Would something like this be what you are looking to do?

Hello nrivas
thanks for your reply. basicly your advice will work, but i should have been more specific in my
question. I need this information about an unscheduled stop in my URScript programm, because
I would like to send this information via modbus to a signal lamp with multiple segments
and flashing modes (selfmade with arduino nano).
Your advice is still valuable, because I can check the status of an output in URScript. But it is some
kind of workaround.
Other robot controllers have a system variable, where you can read the current error code. I’m
looking for something like that.

If you are doing modbus communication, there is a script command “modbus_set_runstate_dependent_choice” which may be what you are looking for then. It will set a modbus signal to certain states similar to the function I described for the Digital Output above. You can find this in the script manual for more information on setting it up.