mirror of
https://github.com/silenty4ng/k5web
synced 2025-01-06 20:02:38 +00:00
update
This commit is contained in:
parent
d1c0f28009
commit
aaef212ddd
7 changed files with 37 additions and 24 deletions
BIN
public/gy.png
BIN
public/gy.png
Binary file not shown.
Before Width: | Height: | Size: 236 KiB After Width: | Height: | Size: 44 KiB |
|
@ -1,6 +1,6 @@
|
|||
<template>
|
||||
<a-layout-footer class="footer">
|
||||
<a href="https://github.com/silenty4ng/k5web" target="_blank">K5Web - V0.1.202405130020</a>
|
||||
<t-link href="https://github.com/silenty4ng/k5web" target="_blank">K5Web - V0.1.202406100220</t-link>
|
||||
</a-layout-footer>
|
||||
</template>
|
||||
|
||||
|
|
|
@ -155,6 +155,7 @@ export default {
|
|||
'cps.mdcid': 'MDC ID',
|
||||
'idea.diy': 'LOSEHU DIY',
|
||||
'diy.generate': 'Generate',
|
||||
'cps.dtmfid': 'DTMF ID',
|
||||
...localeSettings,
|
||||
...localeMessageBox,
|
||||
...localeLogin,
|
||||
|
|
|
@ -155,6 +155,7 @@ export default {
|
|||
'cps.mdcid': 'MDC ID',
|
||||
'idea.diy': '自定义萝卜固件',
|
||||
'diy.generate': '生成',
|
||||
'cps.dtmfid': 'DTMF ID',
|
||||
...localeSettings,
|
||||
...localeMessageBox,
|
||||
...localeLogin,
|
||||
|
|
|
@ -14,7 +14,15 @@
|
|||
</a-card>
|
||||
</a-space>
|
||||
<div>
|
||||
<img style="margin-bottom: 10px;" width="600px" src="/gy.png" />
|
||||
<a-typography-title :heading="5">说明:</a-typography-title>
|
||||
<a-typography-text>◆ 使用应第一时间<t-link theme="primary" href="/#/tool/backup">备份</t-link>配置及校准数据。</a-typography-text><br>
|
||||
<a-typography-text>◆ 除“固件升级”功能手台应处于刷机模式点击更新按钮选择设备更新,其余功能手台均需要在正常模式连接。</a-typography-text><br>
|
||||
<a-typography-text>◆ 萝卜(LOSEHU)固件相关问题请移步:<t-link theme="primary" href="https://github.com/losehu/uv-k5-firmware-custom" target="_blank">https://github.com/losehu/uv-k5-firmware-custom</t-link> 。</a-typography-text><br>
|
||||
<a-typography-text>◆ K5Web 使用视频教程(BG7QJV):<t-link theme="primary" href="https://www.douyin.com/video/7378314511419313458" target="_blank">https://www.douyin.com/video/7378314511419313458</t-link> 。</a-typography-text>
|
||||
</div>
|
||||
<div>
|
||||
<a-typography-title :heading="5">希望工程1+1助学行动:</a-typography-title>
|
||||
<img class="tencent" style="margin-bottom: 10px;" width="200px" src="/gy.png" />
|
||||
</div>
|
||||
</a-col>
|
||||
</template>
|
||||
|
@ -102,4 +110,10 @@
|
|||
:deep(.arco-icon-home) {
|
||||
margin-right: 6px;
|
||||
}
|
||||
|
||||
body[arco-theme='dark'] {
|
||||
.tencent {
|
||||
filter: invert(1) hue-rotate(180deg);
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<a-col :span="24">
|
||||
<a-card class="general-card" :title="$t('idea.diy')" :loading="loading">
|
||||
<t-space direction="vertical">
|
||||
<div>操作说明:<a href="https://github.com/losehu/uv-k5-firmware-custom?tab=readme-ov-file#%E6%93%8D%E4%BD%9C%E8%AF%B4%E6%98%8E%E5%BF%85%E8%AF%BB" target="_blank">https://github.com/losehu/uv-k5-firmware-custom</a></div>
|
||||
<div>操作说明:<t-link theme="primary" href="https://github.com/losehu/uv-k5-firmware-custom" target="_blank">https://github.com/losehu/uv-k5-firmware-custom</t-link></div>
|
||||
<a-radio-group v-for="item in state.showSort" v-model="state.flag[item]" type="button">
|
||||
<a-radio v-for="subItem in state.disMatrix[item]" :value="subItem[0]"
|
||||
:disabled="subItem[1]">{{ state.disName[item].get(subItem[0]) }}</a-radio>
|
||||
|
|
|
@ -21,16 +21,6 @@
|
|||
</a-button>
|
||||
</a-space>
|
||||
</a-col>
|
||||
<!-- <a-col :span="12" style="text-align: right;">
|
||||
<a-space>
|
||||
<a-button type="primary" @click="saveChannel">
|
||||
{{ $t('cps.save') }}
|
||||
</a-button>
|
||||
<a-button @click="restoreChannel">
|
||||
{{ $t('cps.load') }}
|
||||
</a-button>
|
||||
</a-space>
|
||||
</a-col> -->
|
||||
</a-row>
|
||||
<a-spin :loading="loading" style="width: 100%;">
|
||||
<a-form-item :label-col-style="{width: '25%'}" field="logo_line1" :label="$t('cps.line1')">
|
||||
|
@ -39,7 +29,10 @@
|
|||
<a-form-item :label-col-style="{width: '25%'}" field="logo_line2" :label="$t('cps.line2')">
|
||||
<a-input v-model="state.logo_line2" />
|
||||
</a-form-item>
|
||||
<a-form-item :label-col-style="{width: '25%'}" field="logo_line2" :label="$t('cps.mdclocplay')">
|
||||
<a-form-item :label-col-style="{width: '25%'}" field="dtmfid" :label="$t('cps.dtmfid')">
|
||||
<a-input v-model="state.dtmfid" />
|
||||
</a-form-item>
|
||||
<a-form-item :label-col-style="{width: '25%'}" field="mdclocplay" :label="$t('cps.mdclocplay')">
|
||||
<a-switch v-model="state.mdc_audio_local" type="round"/>
|
||||
</a-form-item>
|
||||
</a-spin>
|
||||
|
@ -61,7 +54,8 @@ const { loading, setLoading } = useLoading(false);
|
|||
const state = reactive({
|
||||
logo_line1: '',
|
||||
logo_line2: '',
|
||||
mdc_audio_local: true
|
||||
mdc_audio_local: true,
|
||||
dtmfid: ''
|
||||
})
|
||||
|
||||
const readChannel = async() => {
|
||||
|
@ -85,6 +79,9 @@ const readChannel = async() => {
|
|||
state.logo_line2 = uint8ArrayToString(logo.subarray(0x10, 0x20), appStore.configuration?.charset)
|
||||
}
|
||||
|
||||
const dtmfid = await eeprom_read(appStore.connectPort, 0xEE0, 0x03, appStore.configuration?.uart)
|
||||
state.dtmfid = uint8ArrayToString(dtmfid)
|
||||
|
||||
if(parseInt(await eeprom_read(appStore.connectPort, 0x01FFD, 0x01, appStore.configuration?.uart)) == 0){
|
||||
state.mdc_audio_local = false
|
||||
}else{
|
||||
|
@ -116,21 +113,21 @@ const writeChannel = async() => {
|
|||
logo.set(stringToUint8Array(state.logo_line2, appStore.configuration?.charset).subarray(0, 0x10), 0x10);
|
||||
await eeprom_write(appStore.connectPort, 0xEB0, logo, 0x20, appStore.configuration?.uart);
|
||||
}
|
||||
if(state.dtmfid == ''){
|
||||
await eeprom_write(appStore.connectPort, 0xEE0, new Uint8Array([0xff, 0xff, 0xff]), 0x03, appStore.configuration?.uart);
|
||||
}else{
|
||||
await eeprom_write(appStore.connectPort, 0xEE0, new Uint8Array([
|
||||
stringToUint8Array(state.dtmfid.padStart(3, '0').split('')[0]),
|
||||
stringToUint8Array(state.dtmfid.padStart(3, '0').split('')[1]),
|
||||
stringToUint8Array(state.dtmfid.padStart(3, '0').split('')[2])
|
||||
]), 0x03, appStore.configuration?.uart);
|
||||
}
|
||||
if(appStore.configuration?.localmdc){
|
||||
await eeprom_write(appStore.connectPort, 0x01FFD, new Uint8Array([state.mdc_audio_local ? 1 : 0]), 0x01, appStore.configuration?.uart);
|
||||
}
|
||||
await eeprom_reboot(appStore.connectPort);
|
||||
setLoading(false)
|
||||
}
|
||||
|
||||
const saveChannel = async() => {
|
||||
|
||||
}
|
||||
|
||||
const restoreChannel = async() => {
|
||||
|
||||
}
|
||||
|
||||
</script>
|
||||
|
||||
<script lang="ts">
|
||||
|
|
Loading…
Reference in a new issue