diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 0e94df76..584450d9 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -7,7 +7,7 @@ on: workflow_dispatch: pull_request: schedule: - - cron: '0 5 * * 1' + - cron: "0 5 * * 1" concurrency: # yamllint disable-line rule:line-length @@ -38,6 +38,9 @@ jobs: device: pico-w - firmware: voice-assistant device: m5stack-atom-echo + - firmware: voice-assistant + device: esp32-s3-box + version: dev steps: - uses: actions/checkout@v4 @@ -86,7 +89,6 @@ jobs: name: ${{ matrix.project }} path: manifest.json - full-manifests: name: Create ${{ matrix.project }} manifest runs-on: ubuntu-latest diff --git a/voice-assistant/esp32-s3-box.yaml b/voice-assistant/esp32-s3-box.yaml new file mode 100644 index 00000000..cfb1986c --- /dev/null +++ b/voice-assistant/esp32-s3-box.yaml @@ -0,0 +1,117 @@ +esphome: + name: esp32-s3-box + friendly_name: ESP32 S3 Box + platformio_options: + board_build.flash_mode: dio + + on_boot: + - priority: -100 + then: + - wait_until: api.connected + - delay: 1s + - voice_assistant.start_continuous: + project: + name: esphome.esp32-s3-box-voice-assistant + version: "1.0" + min_version: "2023.9.0-dev" + +esp32: + board: esp32s3box + framework: + type: esp-idf + sdkconfig_options: + CONFIG_ESP32S3_DEFAULT_CPU_FREQ_240: "y" + CONFIG_ESP32S3_DATA_CACHE_64KB: "y" + CONFIG_ESP32S3_DATA_CACHE_LINE_64B: "y" + +wifi: + ap: + +api: +ota: +logger: + hardware_uart: USB_SERIAL_JTAG + +binary_sensor: + - platform: gpio + pin: + number: GPIO1 + inverted: true + name: "Mute" + + - platform: gpio + pin: + number: GPIO0 + mode: INPUT_PULLUP + inverted: true + name: Top Left Button + disabled_by_default: true + on_click: + - if: + condition: voice_assistant.is_running + then: + - voice_assistant.stop: + else: + - voice_assistant.start_continuous: + +output: + - platform: ledc + pin: GPIO45 + id: backlight_output + +light: + - platform: monochromatic + output: backlight_output + name: LCD Backlight + id: backlight + restore_mode: ALWAYS_OFF + disabled_by_default: true + default_transition_length: 0s + effects: + - pulse: + transition_length: 250ms + update_interval: 250ms + +microphone: + - platform: esp_adf + id: box_mic + +speaker: + - platform: esp_adf + id: box_speaker + +voice_assistant: + microphone: box_mic + use_wake_word: true + speaker: box_speaker + on_start: + - light.turn_on: + id: backlight + brightness: 100% + on_tts_end: + - light.turn_on: + id: backlight + brightness: 100% + on_end: + - delay: 100ms + - wait_until: + not: + speaker.is_playing: + - light.turn_off: backlight + on_error: + - light.turn_off: + id: backlight + +external_components: + - source: github://pr#5230 + components: esp_adf + refresh: 0s + - source: github://pr#5229 + components: + - voice_assistant + - api + refresh: 0s + +psram: + mode: octal + speed: 80MHz