device_satellites_info 设备卫星信息
POST /api/v1/gnss/device_satellites_info
描述
获取设备卫星信息接口,用于获取设备卫星详细信息。信息包括:当前定位情况,连接卫星数量,卫星类型,卫星数量。详细的卫星列表信息。
访问权限
具备以下权限:
gnss:device_satellites_info
JSON参数
请求参数如下:
{
"id": number
}
提示
- 这个id是卫星接收机的ID, 0表示第一个卫星接收机, 1表示第二个卫星接收机, 一般情况下 最多两个卫星接收机
- 这个API与device_status_list 设备状态列表的返回结果类似,但是device_status_list是获取设备状态列表信息是数组形式,而device_satellites_info是获取设备卫星详细信息,是对象形式,其中包含了卫星的详细信息
请求示例:
{
"id": 0
}
响应结果
请求返回的HTTP状态码为200
返回结果为JSON格式的数据,您可以通过解析JSON数据来获取API调用的结果信息。结构如下:
{
"success": true|false,
"data": {
"id": number,
"status": "working|standby|offline",
"position": {
"latitude": string,
"longitude": string,
"altitude": number,
"hdop": number,
"vdop": number,
"pdop": number,
},
"signal": [
{
"type": "gps|glonass|bds|galileo",
"active": number,
"count": number,
"satellites": [
{
"id": number,
"snr": number,
"elevation": number,
"azimuth": number,
"chn": number,
"used": true|false,
"healthStatus": 0|1|2,
},
{
"id": number,
"snr": number,
"elevation": number,
"azimuth": number,
"chn": number,
"used": true|false,
"healthStatus": 0|1|2,
},
...
]
},
{
"type": "gps|glonass|bds|galileo",
"active": number,
"count": number,
"satellites": [
{
"id": number,
"snr": number,
"elevation": number,
"azimuth": number,
"chn": number,
"used": true|false,
"healthStatus": 0|1|2,
},
{
"id": number,
"snr": number,
"elevation": number,
"azimuth": number,
"chn": number,
"used": true|false,
"healthStatus": 0|1|2,
},
...
]
},
...
]
},
"errorCode": "option string",
"errorMessage": "option string",
"showType": 0|1|2|4|9,
"traceId": "option string"
}
提示
- id表示卫星接收机的编号,status表示卫星接收机的状态,取值为working表示正在参与驯钟工作中,standby表示待机中,offline表示离线。
- position表示卫星接收机的位置信息,latitude表示纬度,longitude表示经度,altitude表示海拔高度。hdop表示水平精度因子,vdop表示垂直精度因子,pdop表示位置精度因子。
- signal表示卫星接收机的卫星信号信息
- type表示卫星类型,
- active表示当前连接卫星数量,
- count表示当前卫星数量,
- satellites表示卫星列表信息,
- id表示卫星编号,
- snr表示信噪比,
- elevation表示仰角,
- azimuth表示方位角,
- chn表示卫星信道号,当值为-1时表示未知信道号,界面将不显示信道号,
- used表示是否被使用。
- healthStatus表示卫星健康状态,取值为0表示不确定,1表示健康,2表示不健康。
信道号与频段对应关系
| 卫星类型 | 信道号 | 频段 |
|---|---|---|
| GPS | 1 | L1 C/A |
| GPS | 2 | L1 P(Y) |
| GPS | 3 | L1 M |
| GPS | 4 | L2 P(Y) |
| GPS | 5 | L2C-M |
| GPS | 6 | L2C-L |
| GPS | 7 | L5-I |
| GPS | 8 | L5-Q |
| GLONASS | 1 | G1 C/A |
| GLONASS | 2 | G1 P |
| GLONASS | 3 | G2 C/A |
| GLONASS | 4 | G2 P |
| BDS | 1 | B1I |
| BDS | 2 | B1Q |
| BDS | 3 | B1C |
| BDS | 4 | B1A |
| BDS | 5 | B2a |
| BDS | 6 | B2b |
| BDS | 7 | B2 a+b |
| BDS | 8 | B3I |
| BDS | 9 | B3Q |
| GALILEO | 1 | E5a |
| GALILEO | 2 | E5b |
| GALILEO | 3 | E5 a+b |
| GALILEO | 4 | E6-A |
| GALILEO | 5 | E6-BC |
| GALILEO | 6 | L1-A |
| GALILEO | 7 | L1-BC / E1 |
| XXX | -1 | 不显示 |
正确结果示例:
{
"success": true,
"data": {
"id": 0,
"status": "working",
"position": {
"latitude": "30.123456E",
"longitude": "120.123456N",
"altitude": 100,
"hdop": 1.0,
"vdop": 1.0,
"pdop": 1.0,
},
"signal": [
{
"type": "gps",
"active": 10,
"count": 12,
"satellites": [
{
"id": 1,
"snr": 40,
"elevation": 30,
"azimuth": 120,
"chn": 1,
"used": true,
},
{
"id": 2,
"snr": 40,
"elevation": 30,
"azimuth": 120,
"chn": 7,
"used": true
},
...
]
},
{
"type": "glonass",
"active": 10,
"count": 12,
"satellites": [
{
"id": 1,
"snr": 40,
"elevation": 30,
"azimuth": 120,
"chn": 1,
"used": true
},
{
"id": 2,
"snr": 40,
"elevation": 30,
"azimuth": 120,
"chn": 1,
"used": true
},
...
]
},
...
]
}
}
错误结果示例:
{
"success": false,
"errorCode": "40004",
"errorMessage": "device.not.exist",
"showType": 4
}
错误码
| 错误码 | 说明 | 错误信息 | 显示类型 |
|---|---|---|---|
| 40004 | 设备不存在 | device.not.exist | 4 |
提示
4 表示错误, 弹出错误提示框