#@BigBobba flashed your m5 yaml its
1 messages · Page 1 of 1 (latest)
esphome:
name: m5stack-atom-echo-1
esp32:
board: m5stack-atom
framework:
type: esp-idf
logger:
api:
on_client_connected:
- delay: 100ms
- if:
condition:
switch.is_on: use_wake_word
then:
- voice_assistant.start_continuous:
- script.execute: reset_led
on_client_disconnected:
- if:
condition:
switch.is_on: use_wake_word
then:
- voice_assistant.stop:
- light.turn_off: led
ota:
wifi:
ssid: xxxxxxx
password: xxxxxxx
button:
- platform: factory_reset
id: factory_reset_btn
name: Factory reset
i2s_audio:
i2s_lrclk_pin: GPIO33
i2s_bclk_pin: GPIO19
microphone:
- platform: i2s_audio
id: echo_microphone
i2s_din_pin: GPIO23
adc_type: external
pdm: true
speaker:
- platform: i2s_audio
# id: echo_speaker
# i2s_dout_pin: GPIO22
# dac_type: external
# mode: mono
voice_assistant:
id: va
microphone: echo_microphone
speaker: echo_speaker
noise_suppression_level: 2
auto_gain: 31dBFS
volume_multiplier: 2.0
vad_threshold: 3
on_listening:
- light.turn_on:
id: led
blue: 100%
red: 0%
green: 0%
effect: "Slow Pulse"
on_stt_vad_start:
- light.turn_on:
id: led
blue: 0%
red: 100%
green: 0%
effect: "Fast Pulse"
on_stt_vad_end:
- light.turn_on:
id: led
blue: 100%
red: 0%
green: 0%
effect: "Fast Pulse"
on_tts_start:
- light.turn_on:
id: led
blue: 100%
red: 0%
green: 0%
brightness: 100%
effect: none
on_end:
- delay: 500ms
- script.execute: reset_led
on_error:
- light.turn_on:
id: led
red: 100%
green: 0%
blue: 0%
brightness: 100%
effect: none
- delay: 1s
- script.execute: reset_led
on_tts_end:
then:
- homeassistant.service:
service: media_player.play_media
data:
entity_id: media_player.ghost_s_echo_show
media_content_id: !lambda 'return x;'
media_content_type: music
binary_sensor:
To format your text as code, enter three backticks on the first line, press Enter for a new line, paste your code, press Enter again for another new line, and lastly three more backticks.
```yaml
example: here
```
Don't forget you can edit your post rather than repeatedly posting the same thing.
binary_sensor:
- platform: gpio
pin:
number: GPIO39
inverted: true
name: Button
disabled_by_default: true
entity_category: diagnostic
id: echo_button
on_multi_click:-
timing:
- ON for at least 250ms
- OFF for at least 50ms
then: - if:
condition:
switch.is_off: use_wake_word
then:
- if:
condition: voice_assistant.is_running
then:
- voice_assistant.stop:
- script.execute: reset_led
else:
- voice_assistant.start:
else:
- voice_assistant.stop
- delay: 1s
- script.execute: reset_led
- script.wait: reset_led
-
timing:
- ON for at least 10s
then: - button.press: factory_reset_btn
- ON for at least 10s
-
light:
- platform: esp32_rmt_led_strip
id: led
name: None
disabled_by_default: true
entity_category: config
pin: GPIO27
default_transition_length: 0s
chipset: SK6812
num_leds: 1
rgb_order: grb
rmt_channel: 0
effects:- pulse:
name: "Slow Pulse"
transition_length: 250ms
update_interval: 250ms
min_brightness: 50%
max_brightness: 100% - pulse:
name: "Fast Pulse"
transition_length: 100ms
update_interval: 100ms
min_brightness: 50%
max_brightness: 100%
script:
- pulse:
script:
- id: reset_led
then:- if:
condition:- switch.is_on: use_wake_word
- switch.is_on: use_listen_light
then: - light.turn_on:
id: led
red: 100%
green: 30%
blue: 100%
brightness: 60%
effect: none - voice_assistant.start_continuous:
else: - light.turn_off: led
- if:
switch:
- platform: template
name: Use wake word
id: use_wake_word
optimistic: true
restore_mode: RESTORE_DEFAULT_ON
entity_category: config
on_turn_on:- lambda: id(va).set_use_wake_word(true);
- if:
condition:
not:
- voice_assistant.is_running
then:
- voice_assistant.start_continuous - script.execute: reset_led
on_turn_off: - voice_assistant.stop
- lambda: id(va).set_use_wake_word(false);
- script.execute: reset_led
- platform: template
name: Use Listen Light
id: use_listen_light
optimistic: true
restore_mode: RESTORE_DEFAULT_ON
entity_category: config
on_turn_on:- script.execute: reset_led
on_turn_off: - script.execute: reset_led
- script.execute: reset_led
external_components:
- source: github://pr#5230
# components:
# - esp_adf
# refresh: 0s
esp_adf:
gonna recompile and try again
you need to comment out this
speaker:
platform: i2s_audio
id: echo_speaker
i2s_dout_pin: GPIO22
dac_type: external
mode: mono
if you use this method to pate in code
To format your text as code, enter three backticks on the first line, press Enter for a new line, paste your code, press Enter again for another new line, and lastly three more backticks.
```yaml
example: here
```
Don't forget you can edit your post rather than repeatedly posting the same thing.
it will be the same as in your config
its successful it actually works just the voice activation
im gonna check piper and stuff
seems like its always on
it was openwakeword
yes it will constantly stream 5 sec audio , due to the adf component not doing what it should currently.
works great no output though hmm
make sure in esphome integration in HA that the device is allowed to ,make service calls, click 'configure' next to device in list of esphome devices to enable it
ok done
ill unplug and plug in
not initializing with voice again
gonna restart openwake
if still no audio , if its an alexa device it may need additional config with that side of things, i'm affraid i'm not familiar with that side... but they should be able to help in the main voice=assistant channel. turning wakeword on and off can also kick it into action on first start up (the voice initializing)
sent to media player!
said to set tts set public url in integration
incase someone else asks you
You need to set your public URL in the Amazon Media Player integration. Click Settings >> Devices & services>>Alexa Media Player >> Configure . Enter the URL that allows you to access your Homeassistant instance from the outside, i.e. you Nabu Casa address (e.g https://[youruniqueidentifierhere].ui.nabu.casa/)
so all up and running ?
putting in that part rn
to send tts please set announce set = true music cannot be played this way
making progress diff message 🙂
I think I have to find announce flag in yaml?
reflashing