Bladeren bron

修改唤醒词为1个

corvin 5 jaren geleden
bovenliggende
commit
d812c25806

+ 1 - 2
catkin_ws/src/snowboy_wakeup/launch/snowboy_wakeup.launch

@@ -13,8 +13,7 @@
 
     <node pkg="snowboy_wakeup" type="hotword_detector_node" name="snowboy_wakeup" respawn="true">
         <param name="resource_filename" value="$(find snowboy_wakeup)/resources/common.res" />
-        <param name="model_filename" value="$(find snowboy_wakeup)/resources/snowboy.umdl,
-                                            $(find snowboy_wakeup)/resources/corvin.pmdl" />
+        <param name="model_filename" value="$(find snowboy_wakeup)/resources/snowboy.umdl $(find snowboy_wakeup)/resources/corvin.pmdl" />
 
         <param name="sensitivity_str" value="0.7" type="str" />
         <param name="audio_gain" value="1.0" />

+ 0 - 7
catkin_ws/src/snowboy_wakeup/src/hotword_detector_node.cpp

@@ -115,13 +115,6 @@ namespace snowboy_wakeup
                         hotword_pub_.publish(hotword_msg);
                         system("play -q --multi-threaded ~/Music/ding.wav");
                     }
-                    else if(result == 2)
-                    {
-                        ROS_INFO("Hotword 2 detected!");
-                        hotword_msg.data = result;
-                        hotword_pub_.publish(hotword_msg);
-                        system("play -q --multi-threaded ~/Music/dong.wav");
-                    }
                     else if (result == -3)
                     {
                         ROS_ERROR("Hotword detector not initialized");