libvoice-airoha/uci-defaults: add DECT default settings for E755

Following default settings added to dect config:
  - dect.global.pcm_fsync='SHORT_LF'
  - dect.global.pcm_slot_start='8'
  - dect.global.dect_channel_start='3'
This commit is contained in:
George Yang 2025-04-30 16:12:04 +02:00
parent e71ee20840
commit 31c7500042

View file

@ -1,16 +1,25 @@
#!/bin/sh
hasVoice=$(db -q get hw.board.hasVoice)
[ "$hasVoice" = "1" ] || exit 0
SLIC=`cat /proc/device-tree/airoha-voice/slic-type`
[ "${SLIC#pef}" != "${SLIC}" ] || exit 0
SLIC=$(cat /proc/device-tree/airoha-voice/slic-type)
[ "${SLIC#pef}" != "${SLIC}" ] && {
echo Configure TxGain and RxGain for MXL SLIC $SLIC
echo Configure TxGain and RxGain for MXL SLIC $SLIC
ports=$(db -q get hw.board.VoicePorts)
for p in $(seq 0 $((ports-1))); do
ports=$(db -q get hw.board.VoicePorts)
for p in $(seq 0 $((ports-1))); do
uci set asterisk.extension${p}.txgain='10'
uci set asterisk.extension${p}.rxgain='-15'
done
done
}
hasDect=$(db -q get hw.board.hasDect)
[ "$hasDect" = "1" ] || exit 0
# configure the PCM for DECT/DCX81
[ -f "/proc/device-tree/aliases/dcx81-uart" ] && {
uci set dect.global.pcm_fsync='SHORT_LF'
uci set dect.global.pcm_slot_start='8'
uci set dect.global.dect_channel_start='3'
}