Home Position
Overview
The host computer and controller communicate through the home position protocol for setting and querying robot home position, home IO parameters, safety position, and other related configurations.
1. Host Sets Home Position
Command Word: 0x3660
Request Parameters
| Parameter | Type | Length | Description |
|---|---|---|---|
| pos | double[] | 7 | Robot home position list |
| posSync | double[] | 5 | Robot external axis home position list |
| robot | int | 1 | Current robot number, range [1,4] |
Request Example
json
{
"pos": [10.20, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0],
"posSync": [0.0, 0.0, 0.0, 0.0, 0.0],
"robot": 1
}2. Host Queries Home Position
Command Word: 0x3661
Request Parameters
| Parameter | Type | Description |
|---|---|---|
| robot | int | Current robot number, range [1,4] |
Request Example
json
{
"robot": 1
}3. Controller Replies Home Position to Host
Command Word: 0x3662
Response Parameters
| Parameter | Type | Length | Description |
|---|---|---|---|
| deviation | double[] | 7 | Robot each axis safety range, range [0,10] |
| deviationSync | double[] | 5 | Robot external axis each axis safety range, range [0,10] |
| inPort | int | 1 | Start DIN |
| inValue | int | 1 | Start DIN parameter, range [0,1] |
| outPort | int | 1 | End DOUT |
| pos | double[] | 7 | Robot home position list |
| posSync | double[] | 5 | External axis home position list |
| returnWay | int | 1 | Interpolation method: 0-Joint interpolation, 1-Linear interpolation |
| robot | int | 1 | Current robot number, range [1,4] |
| safeEnable | bool | 1 | Safety enable: when safety enable is active, the robot must be manually returned to the safety position before it can run again |
| selectPiontOrFile | int | 1 | Robot home mode: 0-Home position, 1-Home program |
Response Example
json
{
"deviation": [1.0, 1.0, 1.0, 1.0, 1.0, 1.0, 1.0],
"deviationSync": [1.0, 1.0, 1.0, 1.0, 1.0],
"inPort": 0,
"inValue": 1,
"outPort": 0,
"pos": [10.2, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0],
"posSync": [0.0, 0.0, 0.0, 0.0, 0.0],
"returnWay": 0,
"robot": 1,
"safeEnable": false,
"selectPiontOrFile": 0
}4. Host Sets Home IO Parameters
Command Word: 0x3663
Request Parameters
| Parameter | Type | Description |
|---|---|---|
| inPort | int | Start DIN |
| inValue | int | Start DIN parameter, range [0,1] |
| outPort | int | End DOUT |
| returnWay | int | Interpolation method: 0-Joint interpolation, 1-Linear interpolation |
| robot | int | Current robot number, range [1,4] |
| safeEnable | bool | Safety enable: when safety enable is active, the robot must be manually returned to the safety position before it can run again |
| selectPiontOrFile | int | Robot home mode: 0-Home position, 1-Home program |
Request Example
json
{
"inPort": 0,
"inValue": 1,
"outPort": 0,
"returnWay": 0,
"robot": 1,
"safeEnable": false,
"selectPiontOrFile": 0
}5. Host Sets Home Position Safety Position
Command Word: 0x3664
Request Parameters
| Parameter | Type | Length | Description |
|---|---|---|---|
| deviation | double[] | 7 | Robot each axis safety range, range [0,10] |
| deviationSync | double[] | 5 | Robot external axis each axis safety range, range [0,10] |
| robot | int | 1 | Current robot number, range [1,4] |
Request Example
json
{
"deviation": [1.0, 1.0, 1.0, 1.0, 1.0, 1.0, 1.0],
"deviationSync": [1.0, 1.0, 1.0, 1.0, 1.0],
"robot": 1
}6. Controller Replies Host That Current Position Is Not at Safety Position
Command Word: 0x3665
Response Parameters
| Parameter | Type | Length | Description |
|---|---|---|---|
| currentPos | double[] | 6 | Current robot position list, length is the number of axes of the current robot |
| isSync | bool | 1 | Whether it is an external axis |
| robot | int | 1 | Current robot number, range [1,4] |
| safePos | double[] | 6 | Home position list |
Response Example
json
{
"currentPos": [0.0, 0.0, 0.0, 0.0, 0.0, 0.0],
"isSync": false,
"robot": 1,
"safePos": [10.2, 0.0, 0.0, 0.0, 0.0, 0.0]
}Home Position Safety Position (Supplementary returnway Field Description)
In home position settings, the returnway field represents the robot home mode:
- 0: Home position
- 1: Home program