diff --git a/ESPHome/TX-Ultimate-Easy-ESPHome_core_common.yaml b/ESPHome/TX-Ultimate-Easy-ESPHome_core_common.yaml index 85c9313..a254e28 100644 --- a/ESPHome/TX-Ultimate-Easy-ESPHome_core_common.yaml +++ b/ESPHome/TX-Ultimate-Easy-ESPHome_core_common.yaml @@ -29,7 +29,6 @@ substitutions: DUMP_CONFIG_CALLER_DELAY: 10s # Delay to dump config after requested - api: id: api_server on_client_connected: @@ -101,11 +100,6 @@ globals: restore_value: true initial_value: '0' - - id: gang_count_plural_suffix - type: std::string - restore_value: true - max_restore_data_length: 3 - logger: level: DEBUG @@ -157,7 +151,6 @@ script: if (id(gang_count) < 1 || id(gang_count) > 4) { ESP_LOGE("core_hw_leds", "Invalid number of gangs: %" PRIu8, id(gang_count)); } - id(gang_count_plural_suffix) = id(gang_count) > 1 ? "s" : ""; - id: boot_sequence mode: restart @@ -193,7 +186,7 @@ script: ESP_LOGCONFIG("core", "Model format (selected): %s", sl_tx_model_format->state.c_str()); ESP_LOGCONFIG("core", "Model format (detected): %s", id(is_us_model) ? "US" : "EU"); ESP_LOGCONFIG("core", "Gangs (selected): %s", sl_tx_model_gang->state.c_str()); - ESP_LOGCONFIG("core", "Gangs (detected): %" PRIu8 "-Gang%s", id(gang_count), id(gang_count_plural_suffix).c_str()); + ESP_LOGCONFIG("core", "Gangs (detected): %" PRIu8 "-Gang%s", id(gang_count), id(gang_count) > 1 ? "s" : ""); // System state if (bs_pending_restart->state) diff --git a/ESPHome/TX-Ultimate-Easy-ESPHome_standard_hw_audio.yaml b/ESPHome/TX-Ultimate-Easy-ESPHome_standard_hw_audio.yaml index 6491d84..0894e3a 100644 --- a/ESPHome/TX-Ultimate-Easy-ESPHome_standard_hw_audio.yaml +++ b/ESPHome/TX-Ultimate-Easy-ESPHome_standard_hw_audio.yaml @@ -11,6 +11,9 @@ ##### - For normal system use, modifications to this file are NOT required. ##### #################################################################################################### --- +substitutions: + SWITCH_AUDIO_AMPLIFIER_RESTORE_MODE: RESTORE_DEFAULT_ON + esphome: platformio_options: build_flags: @@ -35,13 +38,13 @@ script: ESP_LOGCONFIG(ESPHOME_PROJECT_NAME, " - Standard - Hardware - Audio"); switch: - - id: sw_enable_audio - name: Enable Audio + - id: sw_audio_amplifier + name: Audio Amplifier platform: gpio pin: number: GPIO26 - inverted: true - restore_mode: RESTORE_DEFAULT_ON + inverted: false + restore_mode: ${SWITCH_AUDIO_AMPLIFIER_RESTORE_MODE} internal: true entity_category: config ... diff --git a/ESPHome/TX-Ultimate-Easy-ESPHome_standard_hw_speaker.yaml b/ESPHome/TX-Ultimate-Easy-ESPHome_standard_hw_speaker.yaml index 9f2220f..e84a8a1 100644 --- a/ESPHome/TX-Ultimate-Easy-ESPHome_standard_hw_speaker.yaml +++ b/ESPHome/TX-Ultimate-Easy-ESPHome_standard_hw_speaker.yaml @@ -178,7 +178,7 @@ speaker: i2s_dout_pin: GPIO15 i2s_audio_id: if_i2s_audio i2s_comm_fmt: stand_msb - channel: stereo + channel: mono timeout: never bits_per_sample: 16bit sample_rate: 48000