Robot Software 5.10
Message formatting
Messages sent to primary and secondary clients
Messages not documented in this manual are only used internally by UR software and are not backwards compatible
Robot State Message
| int messageSize |
Length of overall package: total length of package including this field |
| unsigned char messageType = MESSAGE_TYPE_ROBOT_STATE = 16 |
|
| Sub packages |
Each sub package that follows contains size, type, and package specific data |
Robot mode data (Sub Package of Robot State Message)
| int packageSize |
Length of Sub Package: total length of subpackage including this field |
| unsigned char packageType = ROBOT_STATE_PACKAGE_TYPE_ROBOT_MODE_DATA = 0 |
|
| uint64_t timestamp |
|
| bool isRealRobotConnected |
|
| bool isRealRobotEnabled |
|
| bool isRobotPowerOn |
|
| bool isEmergencyStopped |
|
| bool isProtectiveStopped |
|
| bool isProgramRunning |
|
| bool isProgramPaused |
|
| unsigned char robotMode |
Robot Modes
|
| unsigned char controlMode |
Control Modes
|
| double targetSpeedFraction |
|
| double speedScaling |
|
| double targetSpeedFractionLimit |
|
| unsigned char reserved |
|
Joint data (Sub Package of Robot State Message)
| int packageSize |
|
| unsigned char packageType = ROBOT_STATE_PACKAGE_TYPE_JOINT_DATA = 1 |
|
| for each joint: |
|
| double q_actual |
|
| double q_target |
|
| double qd_actual |
|
| float I_actual |
|
| float V_actual |
|
| float T_motor |
|
| float T_micro |
Deprecated - ignore |
| uint8_t jointMode |
Joint Modes
|
| end |
|
The "jointMode" field is a code for the joint status (shown on the initialisation screen):
Tool data (Sub Package of Robot State Message)
| int packageSize |
Length of Sub Package: total length of subpackage including this field |
| unsigned char packageType = ROBOT_STATE_PACKAGE_TYPE_TOOL_DATA = 2 |
|
| unsigned char analogInputRange0 |
|
| unsigned char analogInputRange1 |
|
| double analogInput0 |
|
| double analogInput1 |
|
| float toolVoltage48V |
|
| unsigned char toolOutputVoltage |
|
| float toolCurrent |
|
| float toolTemperature |
|
| uint8_t toolMode |
Tool Modes
|
The "toolMode" field is a code for the joint status (shown on the initialisation screen):
Masterboard data (Sub Package of Robot State Message)
| int packageSize |
Length of Sub Package: total length of subpackage including this field |
| unsigned char packageType = ROBOT_STATE_PACKAGE_TYPE_MASTERBOARD_DATA = 3 |
|
| int digitalInputBits |
|
| int digitalOutputBits |
|
| unsigned char analogInputRange0 |
|
| unsigned char analogInputRange1 |
|
| double analogInput0 |
|
| double analogInput1 |
|
| char analogOutputDomain0 |
|
| char analogOutputDomain1 |
|
| double analogOutput0 |
|
| double analogOutput1 |
|
| float masterBoardTemperature |
|
| float robotVoltage48V |
|
| float robotCurrent |
|
| float masterIOCurrent |
|
| unsigned char safetyMode |
Safety Modes
|
| uint8_t InReducedMode |
|
| char euromap67InterfaceInstalled |
|
| if euromap67 interface is installed, also the following: |
|
| uint32_t euromapInputBits |
|
| uint32_t euromapOutputBits |
|
| float euromapVoltage24V |
|
| float euromapCurrent |
|
| end |
|
| uint32_t (Used by Universal Robots software only) |
|
| uint8_t operationalModeSelectorInput |
|
| uint8_t threePositionEnablingDeviceInput |
|
| unsigned char (Used by Universal Robots software only) |
|
Cartesian info (Sub Package of Robot State Message)
| int packageSize |
Length of Sub Package: total length of subpackage including this field |
| unsigned char packageType = ROBOT_STATE_PACKAGE_TYPE_CARTESIAN_INFO = 4 |
|
| double X |
|
| double Y |
|
| double Z |
|
| double Rx |
|
| double Ry |
|
| double Rz |
|
| double TCPOffsetX |
|
| double TCPOffsetY |
|
| double TCPOffsetZ |
|
| double TCPOffsetRx |
|
| double TCPOffsetRy |
|
| double TCPOffsetRz |
|
Kinematics info (Sub Package of Robot State Message)
| int packageSize |
Length of Sub Package: total length of subpackage including this field |
| unsigned char packageType = ROBOT_STATE_PACKAGE_TYPE_KINEMATICS_INFO = 5 |
|
| for each joint: |
|
| uint32_t cheksum |
|
| for each joint: |
|
| double DHtheta |
|
| for each joint: |
|
| double DHa |
|
| for each joint: |
|
| double Dhd |
|
| for each joint: |
|
| double Dhalpha |
|
| uint32_t calibration_status |
|
This information is sent when leaving initializing mode and/or if the kinematics configuration is changed.
Configuration data (Sub Package of Robot State Message)
| int packageSize |
Length of Sub Package: total length of subpackage including this field |
| unsigned char packageType = ROBOT_STATE_PACKAGE_TYPE_CONFIGURATION_DATA = 6 |
|
| for each joint: |
|
| double jointMinLimit |
|
| double jointMaxLimitt |
|
| end |
|
| for each joint: |
|
| double jointMaxSpeed |
|
| double jointMaxAcceleration |
|
| end |
|
| double vJointDefault |
|
| double aJointDefault |
|
| double vToolDefault |
|
| double aToolDefault |
|
| double eqRadius |
|
| for each joint: |
|
| double DHa |
|
| for each joint: |
|
| double Dhd |
|
| for each joint: |
|
| double DHalpha |
|
| for each joint: |
|
| double DHtheta |
|
| int32_t masterboardVersion |
|
| int32_t controllerBoxType |
|
| int32_t robotType |
|
| int32_t robotSubType |
|
This information is sent when leaving initializing mode and/or if the kinematics configuration is changed.
Force mode data (Sub Package of Robot State Message)
| int packageSize |
Length of Sub Package: total length of subpackage including this field |
| unsigned char packageType = ROBOT_STATE_PACKAGE_TYPE_FORCE_MODE_DATA = 7 |
|
| double Fx |
This double is no longer valid
Always contain value 0.0
|
| double Fy |
This double is no longer valid
Always contain value 0.0
|
| double Fz |
This double is no longer valid
Always contain value 0.0
|
| double Frx |
This double is no longer valid
Always contain value 0.0
|
| double Fry |
This double is no longer valid
Always contain value 0.0
|
| double Frz |
This double is no longer valid
Always contain value 0.0
|
| double robotDexterity |
|
Additional info (Sub Package of Robot State Message)
| int packageSize |
|
| unsigned char packageType = ROBOT_STATE_PACKAGE_TYPE_ADDITIONAL_INFO = 8 |
|
| unsigned char tpButtonState |
|
| bool freedriveButtonEnabled |
|
| bool IOEnabledFreedrive |
|
| unsigned char reserved |
|
Calibration data (Sub Package of Robot State Message, Internally used only)
| int packageSize |
Length of Sub Package: total length of subpackage including this field |
| unsigned char packageType = ROBOT_STATE_PACKAGE_TYPE_NEEDED_FOR_CALIB_DATA = 9 |
|
| double Fx |
|
| double Fy |
|
| double Fz |
|
| double Frx |
|
| double Fry |
|
| double Frz |
|
This package is used internally by Universal Robots software only and should be skipped.
Safety Data (Sub Package of Robot State Message)
| int packageSize |
|
| unsigned char packageType = 10 |
|
| safety data |
|
It is used internally by Universal Robots software only and should be skipped.
Tool Communication Info (Sub Package of Robot State Message)
| int packageSize |
Length of Sub Package: total length of subpackage including this field |
| unsigned char packageType = ROBOT_STATE_PACKAGE_TYPE_TOOL_COMM_INFO = 11 |
|
| bool toolCommunicationIsEnabled |
|
| int32_t baudRate |
|
| int32_t parity |
|
| int32_t stopBits |
|
| float RxIdleChars |
|
| float TxIdleChars |
|
Tool Mode Info (Sub Package of Robot State Message)
| int packageSize |
|
| unsigned char packageType = ROBOT_STATE_PACKAGE_TYPE_TOOL_MODE_INFO = 12 |
|
| uint8_t output mode |
|
| uint8_t digtal output mode output 0 |
|
| uint8_t digtal output mode output 1 |
|
Singularity Info (Sub Package of Robot State Message)
| int packageSize |
|
| unsigned char packageType = ROBOT_STATE_PACKAGE_TYPE_SINGULARITY_INFO = 13 |
|
| uint8_t singularitySeverity |
|
| uint8_t singularityType |
|
| It is used internally by Universal Robots software only and should be skipped. |
|
Version Message (sent only once)
This is the first package sent on both the primary and secondary client interfaces. This package it is not part of the robot state message.
| int messageSize |
|
| unsigned char messageType = MESSAGE_TYPE_ROBOT_MESSAGE = 20 |
|
| uint64_t timestamp |
|
| char source |
Message Sources
|
| char robotMessageType = ROBOT_MESSAGE_TYPE_VERSION = 3 |
|
| char projectNameSize |
|
| charArray projectName |
|
| unsigned char majorVersion |
|
| unsigned char minorVersion |
|
| int bugfixVersion |
|
| int buildNumber |
|
| charArray buildDate |
|
Messages sent to primary clients ONLY
Robot Message - Safety Mode Message
| int messageSize |
|
| unsigned char messageType = MESSAGE_TYPE_ROBOT_MESSAGE = 20 |
|
| uint64_t timestamp |
|
| char source |
Message Sources
|
| char robotMessageType = ROBOT_MESSAGE_TYPE_SAFETY_MODE = 5 |
|
| int robotMessageCode |
|
| int robotMessageArgument |
|
| unsigned char safetyModeType |
Safety Mode Types
|
| uint32_t reportDataType |
|
Remaining part of message depends on data type.
Data types:
- 32 bit unsigned integer = 0 or 1
- 32 bit integer = 2
- 32 bit floating point number = 3
- 32 bit unsigned integer (should be displayed in hexadecimal format) = 4
| (uint32_t|int32_t|float) reportData |
|
Robot Message - Robot Comm Message
| int messageSize |
|
| unsigned char messageType = MESSAGE_TYPE_ROBOT_MESSAGE = 20 |
|
| uint64_t timestamp |
|
| char source |
Message Sources
|
| char robotMessageType = ROBOT_MESSAGE_TYPE_ERROR_CODE = 6 |
|
| int robotMessageCode |
|
| int robotMessageArgument |
|
| int robotMessageReportLevel |
Report Levels
|
| uint32_t dataType |
|
Remaining part of message depends on data type.
Data types:
- 32 bit unsigned integer = 0 or 1
- 32 bit integer = 2
- 32 bit floating point number = 3
- 32 bit unsigned integer (should be displayed in hexadecimal format) = 4
| (uint32_t|int32_t|float) messageData |
|
Data type: String = 5
| uint16_t textLength |
|
| charArray textMessage |
|
Robot Message - Key Message
| int messageSize |
|
| unsigned char messageType = MESSAGE_TYPE_ROBOT_MESSAGE = 20 |
|
| uint64_t timestamp |
|
| char source |
Message Sources
|
| char robotMessageType = ROBOT_MESSAGE_TYPE_KEY = 7 |
|
| int robotMessageCode |
|
| int robotMessageArgument |
|
| uint8_t robotMessageTitleSize |
|
| charArray robotMessageTitle |
|
| charArray keyTextMessage |
|
Robot Message - Program Threads Message
| int messageSize |
|
| unsigned char messageType = MESSAGE_TYPE_ROBOT_MESSAGE = 20 |
|
| uint64_t timestamp |
|
| char source |
Message Sources
|
| char robotMessageType = ROBOT_MESSAGE_TYPE_PROGRAM_LABEL_THREADS = 14 |
|
| following structure repeats for each running program thread |
|
| int labelId (line number) |
|
| int labelNameLength |
|
| charArray labelName |
|
| int threadNameLength |
|
| charArray threadName |
|
Robot Message - Popup Message
| int messageSize |
|
| unsigned char messageType = MESSAGE_TYPE_ROBOT_MESSAGE = 20 |
|
| uint64_t timestamp |
|
| char source |
Message Sources
|
| char robotMessageType = ROBOT_MESSAGE_TYPE_POPUP = 2 |
|
| unsigned int requestId |
|
| unsigned int requestedType |
Requested Types
|
| bool warning |
|
| bool error |
|
| bool blocking |
|
| uint8_t popupMessageTitleSize |
|
| charArray popupMessageTitle |
|
| charArray popupTextMessage |
|
| |
|
Robot Message - Request Value Message
| int messageSize |
|
| unsigned char messageType = MESSAGE_TYPE_ROBOT_MESSAGE = 20 |
|
| uint64_t timestamp |
|
| char source |
Message Sources
|
| char robotMessageType = ROBOT_MESSAGE_TYPE_REQUEST_VALUE = 9 |
|
| unsigned int requestId |
|
| unsigned int requestedType |
Requested Types
|
| char array requestTextMessage |
|
Robot Message - Text Message
| |
|
| int messageSize |
|
| unsigned char messageType = MESSAGE_TYPE_ROBOT_MESSAGE = 20 |
|
| uint64_t timestamp |
|
| char source |
Message Sources
|
| char robotMessageType = ROBOT_MESSAGE_TYPE_TEXT = 0 |
|
| charArray textTextMessage |
|
Robot Message - Runtime Exception Message
| |
|
| int messageSize |
|
| unsigned char messageType = MESSAGE_TYPE_ROBOT_MESSAGE = 20 |
|
| uint64_t timestamp |
|
| char source |
Message Sources
|
| char robotMessageType = ROBOT_MESSAGE_TYPE_RUNTIME_EXCEPTION = 10 |
|
| int scriptLineNumber |
|
| int scriptColumnNumber |
|
| charArray runtimeExceptionTextMessage |
|
Global Variables Setup Message
| int messageSize |
|
| unsigned char messageType = MESSAGE_TYPE_PROGRAM_STATE_MESSAGE = 25 |
|
| uint64_t timestamp |
|
| char robotMessageType = PROGRAM_STATE_MESSAGE_TYPE_GLOBAL_VARIABLES_SETUP = 0 |
|
| uint16_t startIndex |
|
| charArray variableNames |
List of names separated by new line character ('\n' character). Example: var_1\nvar_2\n |
Global Variables Update Message
| int messageSize |
|
| unsigned char messageType = MESSAGE_TYPE_PROGRAM_STATE_MESSAGE = 25 |
|
| uint64_t timestamp |
|
| char robotMessageType = PROGRAM_STATE_MESSAGE_TYPE_GLOBAL_VARIABLES_UPDATE = 1 |
|
| uint16_t startIndex |
|
| unsigned char variableValues |
Value Types
|
Each variable value contains type byte, data, and terminating new line character (\n character). Example - two variables of type BOOL(True), and STRING("aaaa"): 0c 01 0a03 00 04 61 61 61 61 0a