语音合成模块 =================== .. figure:: /_static/products/ledong-module/static/图片/语音合成传感器.png :width: 55% :align: center 概述 -------------------- 用于进行离线语音合成,将文字进行语音播放,带腔体式喇叭。 技术参数 ------------------- 工作电压: VCC 3.3V -5V 模块尺寸:24*48mm 固定安装:2个兼容塑料积木通孔 通讯方式:串口,波特率9600 输出:语音合成结果 引脚定义 ------------------- ===== ======== 引脚 定义 ===== ======== GND 地 VCC 电源 TX 串口发送 RX 串口接收 ===== ======== 示例程序 ------------------- **图形化代码** .. code-block:: python from mpython import * from bluebit import SpeechSynthesis speech_synthesis = SpeechSynthesis(uart_num=1,pin_tx=Pin.P16,pin_rx=Pin.P15) speech_synthesis.play('行路难(其一)【唐】 李白 金樽清酒斗十千,玉盘珍羞直万钱。停杯投箸不能 # note: truncated at right edge of screenshot; tail of last code line not recoverable speech_synthesis.release() .. figure:: /_static/products/ledong-module/static/examples/语音合成.png :width: 100% :align: center