Browse Source

重复10次2

TitanWong 1 year ago
parent
commit
0ce9f33e13

+ 1 - 1
src/main/java/com/zhili/stationcontrol/tts/controller/TtsController.java

@@ -54,7 +54,7 @@ public class TtsController {
 
     @GetMapping("/startMusic/{vol}")
     public String startMusic(@PathVariable Integer vol) {
-        vol = vol > 100 ? 100 : vol;
+        vol = vol > 1000 ? 1000 : vol;
         vol = vol < 0 ? 0 : vol;
         log.info("start music with vol:{}", vol);
         Integer start = musicService.start(playPath, vol);

+ 6 - 4
src/main/resources/application-test.yml

@@ -3,13 +3,15 @@ server:
 
 spring:
   redis:
-    host: 192.168.0.134
+    host: 192.167.3.106
     port: 6379
 
 
 xunfei_tts:
   login_params: "appid = 9f2ce539, work_dir = ."
-  session_begin_params: "engine_type = local, voice_name = xiaoyan, text_encoding = UTF8, tts_res_path = fo|/home/ruili/lib/xiaoyan.jet;fo|/home/ruili/lib/common.jet, sample_rate = 16000, speed = 50, volume = 50, pitch = 50, rdn = 2"
-  filename: "/home/ruili/tts.wav"
+  session_begin_params: "engine_type = local, voice_name = xiaoyan, text_encoding = UTF8, tts_res_path = fo|/home/lib/xiaoyan.jet;fo|/home/lib/common.jet, sample_rate = 16000, speed = 50, volume = 50, pitch = 50, rdn = 2"
+  filename: "/home/tts.wav"
   link_file: "libmsc.so"
-  play_way: java
+  play_way: sox
+
+play_path: /home/music/music.mp3