找回密码
 立即注册

使用微信账号登录

只需一步,快速开始

qcc30xx qcc51xx sink工程自定义语音提示(直接命令操作)

2021-11-14 11:09| 发布者: 213465982| 查看: 2255| 评论: 1

摘要: 有些时候配置工具无法使用,比如开发时用的trb,量产没有预留trb,只预留了usb,无法在线连接配置工具,这里的方法是离线生成自定义语音提示文件。1. 先熟悉下工具,使用voice_prompt_tool.exe工具,可以先看看帮助 ...
有些时候配置工具无法使用,比如开发时用的trb,量产没有预留trb,只预留了usb,无法在线连接配置工具,这里的方法是离线生成自定义语音提示文件。

1. 先熟悉下工具,使用voice_prompt_tool.exe工具,可以先看看帮助文档,图片显示了目录和帮助文档

2. 按照图片格式准备文本文件,格式是根据帮助文档整理。

注意:根据自己的语音源文件选择合适的格式和采样率

compression=PCM,rate=44100,channels=stereo,file="d:\Users\Administrator\Desktop\wav\poweron.wav"
compression=PCM,rate=44100,channels=stereo,file="d:\Users\Administrator\Desktop\wav\poweroff.wav"
compression=PCM,rate=44100,channels=stereo,file="d:\Users\Administrator\Desktop\wav\connected.wav"
compression=PCM,rate=44100,channels=stereo,file="d:\Users\Administrator\Desktop\wav\twsmaster.wav"
compression=PCM,rate=44100,channels=stereo,file="d:\Users\Administrator\Desktop\wav\twsslave.wav"
compression=PCM,rate=44100,channels=stereo,file="d:\Users\Administrator\Desktop\wav\twsclose.wav"

3. 输入转换命令,将wav语音转换为工程需要的格式

voice_prompt_tool -i d:\Users\Administrator\Desktop\wav\ -c d:\Users\Administrator\Desktop\wav\voice.txt

4. 将头文件和语音文件替换sink工程里面对应的文件。

注意:根据语音采样率不同,对应的文件夹名称不同

5. 配置工具添加对应的语音激活事件,然后配置工具保存到工程里面,编译运行即可。


2

路过

雷人

握手

鲜花

鸡蛋

刚表态过的朋友 (2 人)

相关阅读

发表评论

最新评论

引用 nguyentrung2202 2023-5-3 19:00
fail_content: Cannot read wav file, line number:1, line: compression=PCM,rate=44100,channels=stereo,file="C:\Users\Trung\Desktop\wav\connected.wav"

Traceback (most recent call last):
  File "voice_prompt_tool.py", line 308, in <module>


  File "voice_prompt_tool.py", line 30, in exit
KeyError: 'fail_content'
Failed to execute script voice_prompt_tool

i got an error

查看全部评论(1)

小黑屋|手机版|我爱蓝牙网 - 52Bluetooth

GMT+8, 2024-4-25 02:14 , Processed in 0.094424 second(s), 17 queries , Gzip On, MemCached On.

Powered by Discuz! X3.5

© 2001-2024 Discuz! Team.

返回顶部