Skip to content

Commit

Permalink
audio: add support for new wake words
Browse files Browse the repository at this point in the history
Closes: #207
  • Loading branch information
stintel committed Dec 28, 2023
1 parent c20adbf commit f64b28c
Showing 1 changed file with 13 additions and 1 deletion.
14 changes: 13 additions & 1 deletion main/audio.c
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@
#define HTTP_STREAM_TIMEOUT_MS_POST_REQUEST 10 * 1000

#define MULTINET_TWDT 30
#define STR_WAKE_LEN 25
#define STR_WAKE_LEN 32
#define WIS_URL_TTS_ARG "?format=WAV&speaker=CLB&text="

typedef enum willow_http_stream {
Expand Down Expand Up @@ -978,6 +978,18 @@ void init_audio(void)
} else if (strcmp(wake_word, "hilexin") == 0) {
#if defined(CONFIG_SR_WN_WN9_HILEXIN) || defined(CONFIG_SR_WN_WN9_HILEXIN_MULTI)
strncpy(wake_help, "Say 'Hi Lexin' to start!", STR_WAKE_LEN);
#endif
} else if (strcmp(wake_word, "computer") == 0) {
#if defined(CONFIG_SR_WN_WN9_COMPUTER_TTS) || defined(CONFIG_SR_WN_WN9_COMPUTER_TTS_MULTI)
strncpy(wake_help, "Say 'Computer' to start!", STR_WAKE_LEN);
#endif
} else if (strcmp(wake_word, "heywillow") == 0) {
#if defined(CONFIG_SR_WN_WN9_HEYWILLOW_TTS) || defined(CONFIG_SR_WN_WN9_HEYWILLOW_TTS_MULTI)
strncpy(wake_help, "Say 'Hey Willow' to start!", STR_WAKE_LEN);
#endif
} else if (strcmp(wake_word, "jarvis") == 0) {
#if defined(CONFIG_SR_WN_WN9_JARVIS_TTS) || defined(CONFIG_SR_WN_WN9_JARVIS_TTS_MULTI)
strncpy(wake_help, "Say 'Jarvis' to start!", STR_WAKE_LEN);
#endif
}

Expand Down

0 comments on commit f64b28c

Please sign in to comment.