add hold to talk test

This commit is contained in:
Terrence
2024-11-25 04:44:27 +08:00
parent e4382faee3
commit ff28586c35

View File

@@ -118,8 +118,15 @@ private:
} }
void InitializeButtons() { void InitializeButtons() {
boot_button_.OnClick([this]() { // 测试按住说话
Application::GetInstance().ToggleChatState(); // boot_button_.OnClick([this]() {
// Application::GetInstance().ToggleChatState();
// });
boot_button_.OnPressDown([this]() {
Application::GetInstance().StartListening();
});
boot_button_.OnPressUp([this]() {
Application::GetInstance().StopListening();
}); });
volume_up_button_.OnClick([this]() { volume_up_button_.OnClick([this]() {