Page 58
M4220170607EN
UI Robot Technology Co. Ltd.
UIM2842
11.0
INSTRUCTION
This chapter describes the detail of the instructions mentioned in this document.
Please note, in this user manual, unless otherwise specified, all messages are based on
structure, form and parsing method of RS232 character string messages. For structure,
form and parsing method of CAN message based on UI SimpleCAN, please refer to UI
SimpleCAN programming manual.
11.1 Instruction Structure
An instruction is a message sent from the user device to motion controller to command
certain operatio. Instructions of UIM2842 follow the rules listed below:
1. Length of an instruction (including the ending semicolon “;”) should be within 20
characters
2. Coded with standard 7 bits ASCII code (1-127). Expended ASCII code is NOT
accepted.
3. Instruction structure is as follow:
INS
η
;
or
INSx
η
;
or
INS
;
Where,
INS
Instruction
Symbol
Comprises three letters with no space between them, and is not
case sensitive.
If there is an x (INSx), then it means the value is hexadecimal.
Please note, if
η is hexadecimal, then the data must have an
even number of digits, such as 00, 01, 0A. A data has an odd
number of digits will cause erroes, for example, 001, 10A are
illegal input.
η
Value
Comprises set of numbers, with no other characters between them.
Some instruction have no value, such as “SPD;” “STP;” etc.
;
Terminator
Each instruction must end with semicolon (;)
Note: Instruction without terminator will cause unpredictable
results.
11.2 Feedback Message Structure
Feedback Message is the message sent to user device from motion controller. The length
of feedback message is not regular, maximum length is 13 bytes.
Structure of feedback message from UIM242XX (through UIM2501) is as follow:
[Header] [Controller ID] [Message ID] [Data] [Terminator]