Range
Function
This API is used to get Access Control > RS-485 parameter range.
Request Message
Parameter Description
Table 1
| Parameter | Range | Type | Description |
|---|---|---|---|
| channel | "CH1"…"CHx" | string array | The channels supported by the device. |
Sample:
POST /API/AccessControl/RS485/Range HTTP/1.1
{
"version": "1.0",
"data": {}
}
Response Message
Parameter Description
Table 2
| Parameter | Range | Type | Description |
|---|---|---|---|
| channel_info | object | Total channel information see Table 3. | |
| channel_max | int | The maximum number of channels. |
Table 3
| Parameter | Range | Type | Description |
|---|---|---|---|
| CH1…CHx | object | See Table 4 |
Table 4
| Parameter | Range | Type | Description |
|---|---|---|---|
| enable | bool | Enable | |
| protocol | "Protocol-D""Protocol-P" | string | Protocol |
| baudrate | "9600" | string | Baudrate |
| data_bit | "8" | string | Data Bit |
| stop_bit | "1" | string | Stop Bit |
| parity | "None" | string | Parity |
| address | "1" | string | Address Code |
Sample:
HTTP/1.1 200 OK
Content-Type: application/json
{
"result": "success",
"data": {
"channel_max": 1,
"channel_info": {
"type": "object",
"items": {"CH1": {
"type": "object",
"items": {
"enable": {"type": "bool"},
"protocol": {
"type": "string",
"items": [
"Protocol-D",
"Protocol-P"
]
},
"baudrate": {
"type": "string",
"items": ["9600"]
},
"data_bit": {
"type": "string",
"items": ["8"]
},
"stop_bit": {
"type": "string",
"items": ["1"]
},
"parity": {
"type": "string",
"items": ["None"]
},
"address": {
"type": "string",
"items": ["1"]
}
}
}}
}
}
}
Error Code
See Response Messages Body and Common error_code for more information.