|
|
|
@ -1,6 +1,14 @@
|
|
|
|
|
<template>
|
|
|
|
|
<div class="airport-information">
|
|
|
|
|
<div class="title">无人机信息:<span>未连接</span></div>
|
|
|
|
|
<div class="title"
|
|
|
|
|
>无人机信息:<span>
|
|
|
|
|
<template
|
|
|
|
|
v-if="uavInformation.sub_device && uavInformation.sub_device.device_online_status == 1"
|
|
|
|
|
>开机</template
|
|
|
|
|
>
|
|
|
|
|
<template v-else>关机</template>
|
|
|
|
|
</span></div
|
|
|
|
|
>
|
|
|
|
|
<div class="content">
|
|
|
|
|
<div class="content-title">
|
|
|
|
|
{{ time }}
|
|
|
|
@ -9,45 +17,65 @@
|
|
|
|
|
<div class="content-item">
|
|
|
|
|
<div class="item-div">
|
|
|
|
|
<img src="@/assets/images/flightoperation/project.png" alt="" />
|
|
|
|
|
1
|
|
|
|
|
{{ uavInformation.wireless_link ? uavInformation.wireless_link.dongle_number : 0 }}
|
|
|
|
|
</div>
|
|
|
|
|
<a-divider type="vertical" style="border-color: #4e5778" />
|
|
|
|
|
<div class="item-div">
|
|
|
|
|
<!-- <div class="item-div">
|
|
|
|
|
<img src="@/assets/images/flightoperation/arrow.png" alt="" />
|
|
|
|
|
0%
|
|
|
|
|
</div> -->
|
|
|
|
|
<div class="item-div">
|
|
|
|
|
<img src="@/assets/images/flightoperation/electricity.png" alt="" />
|
|
|
|
|
{{
|
|
|
|
|
uavInformation.drone_battery_maintenance_info
|
|
|
|
|
? uavInformation.drone_battery_maintenance_info.capacity_percent
|
|
|
|
|
: 0
|
|
|
|
|
}}
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="content-item">
|
|
|
|
|
<div class="item-div">
|
|
|
|
|
<img src="@/assets/images/flightoperation/rtk.png" alt="" />
|
|
|
|
|
0
|
|
|
|
|
<img src="@/assets/images/flightoperation/sdr.png" alt="" />
|
|
|
|
|
<!-- sdr_link_state -->
|
|
|
|
|
<template
|
|
|
|
|
v-if="uavInformation.wireless_link && uavInformation.wireless_link.sdr_link_state == 1"
|
|
|
|
|
>连接</template
|
|
|
|
|
>
|
|
|
|
|
<template v-else>断开</template>
|
|
|
|
|
</div>
|
|
|
|
|
<a-divider type="vertical" style="border-color: #4e5778" />
|
|
|
|
|
<div class="item-div">
|
|
|
|
|
<img src="@/assets/images/flightoperation/electricity.png" alt="" />
|
|
|
|
|
89%(空闲中)
|
|
|
|
|
<img src="@/assets/images/flightoperation/4g.png" alt="" />
|
|
|
|
|
<template
|
|
|
|
|
v-if="
|
|
|
|
|
uavInformation.wireless_link && uavInformation.wireless_link['4g_link_state'] == 1
|
|
|
|
|
"
|
|
|
|
|
>连接</template
|
|
|
|
|
>
|
|
|
|
|
<template v-else>断开</template>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<!-- sdr_freq_band sdr_quality 4g_freq_band 4g_quality -->
|
|
|
|
|
<div class="content-item">
|
|
|
|
|
<div class="item-div">
|
|
|
|
|
<img src="@/assets/images/flightoperation/agl.png" alt="" />
|
|
|
|
|
0M
|
|
|
|
|
<img src="@/assets/images/flightoperation/sdr.png" alt="" />
|
|
|
|
|
{{ uavInformation.wireless_link ? uavInformation.wireless_link.sdr_quality : 0 }}
|
|
|
|
|
</div>
|
|
|
|
|
<a-divider type="vertical" style="border-color: #4e5778" />
|
|
|
|
|
<div class="item-div">
|
|
|
|
|
<img src="@/assets/images/flightoperation/agl.png" alt="" />
|
|
|
|
|
0M
|
|
|
|
|
<img src="@/assets/images/flightoperation/4g.png" alt="" />
|
|
|
|
|
{{ uavInformation.wireless_link ? uavInformation.wireless_link['4g_quality'] : 0 }}
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="content-item">
|
|
|
|
|
<div class="item-div">
|
|
|
|
|
<img src="@/assets/images/flightoperation/hs.png" alt="" />
|
|
|
|
|
0m/s
|
|
|
|
|
<img src="@/assets/images/flightoperation/sdr.png" alt="" />
|
|
|
|
|
{{ uavInformation.wireless_link ? uavInformation.wireless_link.sdr_freq_band : 0 }}
|
|
|
|
|
</div>
|
|
|
|
|
<a-divider type="vertical" style="border-color: #4e5778" />
|
|
|
|
|
<div class="item-div">
|
|
|
|
|
<img src="@/assets/images/flightoperation/h.png" alt="" />
|
|
|
|
|
0M
|
|
|
|
|
<img src="@/assets/images/flightoperation/4g.png" alt="" />
|
|
|
|
|
{{ uavInformation.wireless_link ? uavInformation.wireless_link['4g_freq_band'] : 0 }}
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="content-edit">
|
|
|
|
@ -89,7 +117,7 @@
|
|
|
|
|
>飞行控制</a-button
|
|
|
|
|
>
|
|
|
|
|
<a-button type="primary" style="background: #0a99eb" @click="emits('changeLoadControl')"
|
|
|
|
|
>负载控制</a-button
|
|
|
|
|
>云台相机控制</a-button
|
|
|
|
|
>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="content-button">
|
|
|
|
@ -104,7 +132,6 @@
|
|
|
|
|
import { reactive, ref, watch } from 'vue';
|
|
|
|
|
import { CopyOutlined, EditOutlined } from '@ant-design/icons-vue';
|
|
|
|
|
import { timestampToFormattedDate } from '@/utils/index';
|
|
|
|
|
import { getClient, createConnection, clientPublish, clientSubscribe } from '@/utils/mqtt';
|
|
|
|
|
import { buildGUID } from '@/utils/uuid';
|
|
|
|
|
import { servicesTopic, services_replyTopic } from '@/utils/debugging/remote';
|
|
|
|
|
|
|
|
|
@ -138,13 +165,41 @@
|
|
|
|
|
limitedRange: '500m',
|
|
|
|
|
obstacleAvoidance: '500m',
|
|
|
|
|
});
|
|
|
|
|
const uavInformation = ref({
|
|
|
|
|
sub_device: {
|
|
|
|
|
// 飞行器状态
|
|
|
|
|
device_online_status: 0,
|
|
|
|
|
},
|
|
|
|
|
drone_battery_maintenance_info: {
|
|
|
|
|
// 电池剩余电量
|
|
|
|
|
capacity_percent: 0,
|
|
|
|
|
},
|
|
|
|
|
wireless_link: {
|
|
|
|
|
// 飞行器上 Dongle 数量
|
|
|
|
|
dongle_number: 0,
|
|
|
|
|
sdr_quality: 0,
|
|
|
|
|
'4g_quality': 0,
|
|
|
|
|
'4g_uav_quality': 0,
|
|
|
|
|
'4g_gnd_quality': 0,
|
|
|
|
|
remain_upload: 0,
|
|
|
|
|
sdr_link_state: 0,
|
|
|
|
|
sdr_freq_band: 0,
|
|
|
|
|
},
|
|
|
|
|
});
|
|
|
|
|
const time = ref(timestampToFormattedDate(new Date().getTime()));
|
|
|
|
|
watch(
|
|
|
|
|
() => props.msgData,
|
|
|
|
|
(val) => {
|
|
|
|
|
if (val.topic == 'thing/product/8UUXN5400A079H/osd') {
|
|
|
|
|
// console.log(val);
|
|
|
|
|
time.value = timestampToFormattedDate(val.message.timestamp);
|
|
|
|
|
if (
|
|
|
|
|
val.message.data.sub_device ||
|
|
|
|
|
val.message.data.drone_battery_maintenance_info ||
|
|
|
|
|
val.message.data.wireless_link
|
|
|
|
|
) {
|
|
|
|
|
// console.log(val);
|
|
|
|
|
uavInformation.value = val.message.data;
|
|
|
|
|
time.value = timestampToFormattedDate(val.message.timestamp);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
);
|
|
|
|
@ -152,7 +207,7 @@
|
|
|
|
|
<style lang="less" scoped>
|
|
|
|
|
.airport-information {
|
|
|
|
|
position: absolute;
|
|
|
|
|
top: 360px;
|
|
|
|
|
top: 320px;
|
|
|
|
|
left: 0;
|
|
|
|
|
z-index: 999;
|
|
|
|
|
width: 260px;
|
|
|
|
|