From 3e2dbb74e8485626162cf52409df195b31044d09 Mon Sep 17 00:00:00 2001 From: Keith Burzinski Date: Tue, 12 Aug 2025 20:57:21 -0500 Subject: [PATCH 01/27] Update for ESPHome 2025.8.0 release --- Integrations/ESPHome/Core.yaml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/Integrations/ESPHome/Core.yaml b/Integrations/ESPHome/Core.yaml index 18ef8c6..f6adc1c 100644 --- a/Integrations/ESPHome/Core.yaml +++ b/Integrations/ESPHome/Core.yaml @@ -376,6 +376,7 @@ sensor: name: Radar Moving Distance id: moving_distance filters: + - throttle_with_priority: 1000ms - lambda: |- static float last_reported_value = 0.0; float current_value = x; @@ -404,6 +405,7 @@ sensor: name: Radar Still Distance id: still_distance filters: + - throttle_with_priority: 1000ms - lambda: |- static float last_reported_value = 0.0; float current_value = x; @@ -432,6 +434,7 @@ sensor: name: Radar Move Energy id: radar_moving_energy filters: + - throttle_with_priority: 1000ms - lambda: |- if (id(reduce_db_reporting).state) return {}; return x; @@ -439,6 +442,7 @@ sensor: name: Radar Still Energy id: radar_still_energy filters: + - throttle_with_priority: 1000ms - lambda: |- if (id(reduce_db_reporting).state) return {}; return x; @@ -446,6 +450,7 @@ sensor: name: Radar Detection Distance id: radar_detection_distance filters: + - throttle_with_priority: 1000ms - lambda: |- static float last_reported_value = 0.0; float current_value = x; From d4ffac9b60374d5a5766530ce6feae7924d1589e Mon Sep 17 00:00:00 2001 From: Keith Burzinski Date: Tue, 12 Aug 2025 20:58:04 -0500 Subject: [PATCH 02/27] Update version --- Integrations/ESPHome/Core.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Integrations/ESPHome/Core.yaml b/Integrations/ESPHome/Core.yaml index f6adc1c..30040af 100644 --- a/Integrations/ESPHome/Core.yaml +++ b/Integrations/ESPHome/Core.yaml @@ -1,6 +1,6 @@ substitutions: name: apollo-msr-2 - version: "25.8.6.1" + version: "25.8.12.1" device_description: ${name} made by Apollo Automation - version ${version}. esp32: From bcb98f3c7b19e4cb72faa9a6994b03d263fb2a30 Mon Sep 17 00:00:00 2001 From: Benjamin Fedorka Date: Sun, 28 Sep 2025 22:23:57 -0400 Subject: [PATCH 03/27] Fix reporting of initial values when reduce_db_reporting=true --- Integrations/ESPHome/Core.yaml | 42 +++++++++++++++++----------------- 1 file changed, 21 insertions(+), 21 deletions(-) diff --git a/Integrations/ESPHome/Core.yaml b/Integrations/ESPHome/Core.yaml index 18ef8c6..e0d7964 100644 --- a/Integrations/ESPHome/Core.yaml +++ b/Integrations/ESPHome/Core.yaml @@ -329,17 +329,17 @@ sensor: id: sys_esp_temperature filters: - lambda: |- - static float last_reported_value = 0.0; + static float last_reported_value = -6.0; float current_value = x; // Check if the reduce_db_reporting switch is on if (id(reduce_db_reporting).state) { - // Apply delta filter: only report if the value has changed by 2 or more + // Apply delta filter: only report if the value has changed by 5 or more if (abs(current_value - last_reported_value) >= 5.0) { last_reported_value = current_value; // Update the last reported value return current_value; } else { - // Return the last reported value without updating if change is less than 2 + // Return the last reported value without updating if change is less than 5 return {}; // Discard the update } } else { @@ -377,7 +377,7 @@ sensor: id: moving_distance filters: - lambda: |- - static float last_reported_value = 0.0; + static float last_reported_value = -6.0; float current_value = x; // Check if the radar_has_moving_target sensor is off @@ -387,12 +387,12 @@ sensor: // Check if the reduce_db_reporting switch is on if (id(reduce_db_reporting).state) { - // Apply delta filter: only report if the value has changed by 2 or more + // Apply delta filter: only report if the value has changed by 5 or more if (abs(current_value - last_reported_value) >= 5.0) { last_reported_value = current_value; // Update the last reported value return current_value; } else { - // Return the last reported value without updating if change is less than 2 + // Return the last reported value without updating if change is less than 5 return {}; // Discard the update } } else { @@ -405,7 +405,7 @@ sensor: id: still_distance filters: - lambda: |- - static float last_reported_value = 0.0; + static float last_reported_value = -6.0; float current_value = x; // Check if the radar_has_still_target sensor is off @@ -415,12 +415,12 @@ sensor: // Check if the reduce_db_reporting switch is on if (id(reduce_db_reporting).state) { - // Apply delta filter: only report if the value has changed by 2 or more + // Apply delta filter: only report if the value has changed by 5 or more if (abs(current_value - last_reported_value) >= 5.0) { last_reported_value = current_value; // Update the last reported value return current_value; } else { - // Return the last reported value without updating if change is less than 2 + // Return the last reported value without updating if change is less than 5 return {}; // Discard the update } } else { @@ -447,7 +447,7 @@ sensor: id: radar_detection_distance filters: - lambda: |- - static float last_reported_value = 0.0; + static float last_reported_value = -6.0; float current_value = x; // Check if the radar_has_target sensor is off @@ -457,12 +457,12 @@ sensor: // Check if the reduce_db_reporting switch is on if (id(reduce_db_reporting).state) { - // Apply delta filter: only report if the value has changed by 2 or more + // Apply delta filter: only report if the value has changed by 5 or more if (abs(current_value - last_reported_value) >= 5.0) { last_reported_value = current_value; // Update the last reported value return current_value; } else { - // Return the last reported value without updating if change is less than 2 + // Return the last reported value without updating if change is less than 5 return {}; // Discard the update } } else { @@ -541,17 +541,17 @@ sensor: id: ltr390light filters: - lambda: |- - static float last_reported_value = 0.0; + static float last_reported_value = -21.0; float current_value = x; // Check if the reduce_db_reporting switch is on if (id(reduce_db_reporting).state) { - // Apply delta filter: only report if the value has changed by 2 or more + // Apply delta filter: only report if the value has changed by 20 or more if (abs(current_value - last_reported_value) >= 20.0) { last_reported_value = current_value; // Update the last reported value return current_value; } else { - // Return the last reported value without updating if change is less than 2 + // Return the last reported value without updating if change is less than 20 return {}; // Discard the update } } else { @@ -564,17 +564,17 @@ sensor: id: ltr390uvindex filters: - lambda: |- - static float last_reported_value = 0.0; + static float last_reported_value = -21.0; float current_value = x; // Check if the reduce_db_reporting switch is on if (id(reduce_db_reporting).state) { - // Apply delta filter: only report if the value has changed by 2 or more + // Apply delta filter: only report if the value has changed by 20 or more if (abs(current_value - last_reported_value) >= 20.0) { last_reported_value = current_value; // Update the last reported value return current_value; } else { - // Return the last reported value without updating if change is less than 2 + // Return the last reported value without updating if change is less than 20 return {}; // Discard the update } } else { @@ -590,17 +590,17 @@ sensor: id: dps310pressure filters: - lambda: |- - static float last_reported_value = 0.0; + static float last_reported_value = -6.0; float current_value = x; // Check if the reduce_db_reporting switch is on if (id(reduce_db_reporting).state) { - // Apply delta filter: only report if the value has changed by 2 or more + // Apply delta filter: only report if the value has changed by 5 or more if (abs(current_value - last_reported_value) >= 5.0) { last_reported_value = current_value; // Update the last reported value return current_value; } else { - // Return the last reported value without updating if change is less than 2 + // Return the last reported value without updating if change is less than 5 return {}; // Discard the update } } else { From 23d658b7a4b0846b5b717f9bc2690828c21c58be Mon Sep 17 00:00:00 2001 From: Benjamin Fedorka Date: Mon, 29 Sep 2025 20:48:42 -0400 Subject: [PATCH 04/27] Increase reporting for lux and UV index --- Integrations/ESPHome/Core.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Integrations/ESPHome/Core.yaml b/Integrations/ESPHome/Core.yaml index 18ef8c6..944f612 100644 --- a/Integrations/ESPHome/Core.yaml +++ b/Integrations/ESPHome/Core.yaml @@ -547,7 +547,7 @@ sensor: // Check if the reduce_db_reporting switch is on if (id(reduce_db_reporting).state) { // Apply delta filter: only report if the value has changed by 2 or more - if (abs(current_value - last_reported_value) >= 20.0) { + if (abs(current_value - last_reported_value) >= 5.0) { last_reported_value = current_value; // Update the last reported value return current_value; } else { @@ -570,7 +570,7 @@ sensor: // Check if the reduce_db_reporting switch is on if (id(reduce_db_reporting).state) { // Apply delta filter: only report if the value has changed by 2 or more - if (abs(current_value - last_reported_value) >= 20.0) { + if (abs(current_value - last_reported_value) >= 1.0) { last_reported_value = current_value; // Update the last reported value return current_value; } else { From 746e182896de3b9c754d9d9074af837910f02e24 Mon Sep 17 00:00:00 2001 From: Brandon Harvey <8107750+bharvey88@users.noreply.github.com> Date: Sat, 25 Oct 2025 11:39:52 -0500 Subject: [PATCH 05/27] Add logger configuration to MSR-2.yaml add logger to MSR-2.yaml for better troubleshooting --- Integrations/ESPHome/MSR-2.yaml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Integrations/ESPHome/MSR-2.yaml b/Integrations/ESPHome/MSR-2.yaml index 7f443c4..6c46650 100644 --- a/Integrations/ESPHome/MSR-2.yaml +++ b/Integrations/ESPHome/MSR-2.yaml @@ -29,6 +29,8 @@ dashboard_import: package_import_url: github://ApolloAutomation/MSR-2/Integrations/ESPHome/MSR-2.yaml import_full_config: false +logger: + ota: - platform: esphome id: ota_default From b6ed5840ea639cf3ad81b5b59c193ecba418de02 Mon Sep 17 00:00:00 2001 From: Jeff Sandberg Date: Thu, 20 Nov 2025 13:35:49 -0700 Subject: [PATCH 06/27] Add general occupancy sensor Adds a general occupancy sensor that serves as a union of all three zone sensors --- Integrations/ESPHome/Core.yaml | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/Integrations/ESPHome/Core.yaml b/Integrations/ESPHome/Core.yaml index 18ef8c6..bdccacf 100644 --- a/Integrations/ESPHome/Core.yaml +++ b/Integrations/ESPHome/Core.yaml @@ -320,6 +320,17 @@ binary_sensor: id(testScript).execute(); } + - platform: template + name: "Occupancy" + id: "general_occupancy" + device_class: occupancy + icon: mdi:motion-sensor + lambda: |- + bool zone1 = id(radar_zone_1_occupancy).state; + bool zone2 = id(radar_zone_2_occupancy).state; + bool zone3 = id(radar_zone_3_occupancy).state; + return zone1 || zone2 || zone3; + ld2410: id: ld2410_radar From 2aa81eec8b44d1f119f490e09c65b72bfd93ee49 Mon Sep 17 00:00:00 2001 From: Jeff Sandberg Date: Sat, 6 Dec 2025 19:58:36 -0700 Subject: [PATCH 07/27] Rename general occupancy sensor based on discussion in discord --- Integrations/ESPHome/Core.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Integrations/ESPHome/Core.yaml b/Integrations/ESPHome/Core.yaml index bdccacf..bb3c6f9 100644 --- a/Integrations/ESPHome/Core.yaml +++ b/Integrations/ESPHome/Core.yaml @@ -321,8 +321,8 @@ binary_sensor: } - platform: template - name: "Occupancy" - id: "general_occupancy" + name: "Radar Zone Occupancy" + id: "radar_zone_occupancy" device_class: occupancy icon: mdi:motion-sensor lambda: |- From 9dd9982580d1213a43769715a7bfb9c4f038a86e Mon Sep 17 00:00:00 2001 From: Brandon Harvey Date: Sat, 31 Jan 2026 15:18:31 -0600 Subject: [PATCH 08/27] Add configurable update interval for LTR390 sensor Allows users to adjust the LTR390 sensor update frequency from the default 60 seconds to any value between 1-300 seconds through the web interface, eliminating the need for YAML edits and firmware recompilation. Uses ESPHome's interval component to manually poll the sensor at the configured rate, as sensor platform update_interval is not templatable. The setting is exposed as a number input under the CONFIG entity category with values persisted across device reboots. Resolves #54 Co-Authored-By: Claude Sonnet 4.5 --- Integrations/ESPHome/Core.yaml | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) diff --git a/Integrations/ESPHome/Core.yaml b/Integrations/ESPHome/Core.yaml index a7f7df3..b66b866 100644 --- a/Integrations/ESPHome/Core.yaml +++ b/Integrations/ESPHome/Core.yaml @@ -43,6 +43,10 @@ globals: restore_value: no type: bool initial_value: "false" + - id: ltr390_last_update + restore_value: no + type: uint32_t + initial_value: '0' # Enable Home Assistant API # Also Add Buzzer Service Connection @@ -157,6 +161,19 @@ number: update_interval: never step: 0.1 mode: box + - platform: template + name: LTR390 Update Interval + id: ltr390_update_interval + restore_value: true + initial_value: 60 + min_value: 1 + max_value: 300 + entity_category: "CONFIG" + unit_of_measurement: "s" + optimistic: true + update_interval: never + step: 1 + mode: box # Setting start of zone 1 occupancy - platform: template name: "Radar Zone 1 Start" @@ -552,6 +569,7 @@ sensor: - platform: ltr390 id: ltr_390 + update_interval: never light: name: "LTR390 Light" id: ltr390light @@ -682,6 +700,21 @@ button: id: scd40 +interval: + - interval: 1s + then: + - lambda: |- + uint32_t current_time = millis() / 1000; // Convert to seconds + uint32_t last_update = id(ltr390_last_update); + uint32_t interval = (uint32_t)id(ltr390_update_interval).state; + + // Check if enough time has passed + if (current_time - last_update >= interval) { + id(ltr_390).update(); + id(ltr390_last_update) = current_time; + } + + switch: - platform: ld2410 bluetooth: From 2bb306f2c895e66d96878c3b8816b400a948db4e Mon Sep 17 00:00:00 2001 From: Brandon Harvey Date: Mon, 2 Feb 2026 12:04:00 -0600 Subject: [PATCH 09/27] Fix: Ensure immediate LTR390 reading on boot Add check for first boot condition (last_update == 0 && current_time > 0) to trigger an immediate sensor update instead of waiting for the full configured interval to elapse. The current_time > 0 guard prevents edge case where both values are 0 in the first second after boot. Co-Authored-By: Claude Opus 4.5 --- Integrations/ESPHome/Core.yaml | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/Integrations/ESPHome/Core.yaml b/Integrations/ESPHome/Core.yaml index b66b866..244a26f 100644 --- a/Integrations/ESPHome/Core.yaml +++ b/Integrations/ESPHome/Core.yaml @@ -708,13 +708,19 @@ interval: uint32_t last_update = id(ltr390_last_update); uint32_t interval = (uint32_t)id(ltr390_update_interval).state; + // Immediate update on boot (when last_update is still 0) + if (last_update == 0 && current_time > 0) { + id(ltr_390).update(); + id(ltr390_last_update) = current_time; + return; + } + // Check if enough time has passed if (current_time - last_update >= interval) { id(ltr_390).update(); id(ltr390_last_update) = current_time; } - switch: - platform: ld2410 bluetooth: From 196c738ec73b564dccd2f006eca44a293e97ffd9 Mon Sep 17 00:00:00 2001 From: Brandon Harvey Date: Tue, 24 Feb 2026 17:14:26 -0600 Subject: [PATCH 10/27] Add IP address text sensor via wifi_info platform --- Integrations/ESPHome/Core.yaml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/Integrations/ESPHome/Core.yaml b/Integrations/ESPHome/Core.yaml index a7f7df3..63d0be0 100644 --- a/Integrations/ESPHome/Core.yaml +++ b/Integrations/ESPHome/Core.yaml @@ -713,6 +713,11 @@ text_sensor: version: name: "Radar Firmware Version" + - platform: wifi_info + ip_address: + name: "IP Address" + id: wifi_ip + select: - platform: ld2410 distance_resolution: From 0cefd9f774560bd1987215eb6d342daaccdd8afb Mon Sep 17 00:00:00 2001 From: Brandon Harvey Date: Tue, 24 Feb 2026 17:15:54 -0600 Subject: [PATCH 11/27] Rename API services to actions (play_buzzer, calibrate_co2_value, set_ld2410_bluetooth_password) --- Integrations/ESPHome/Core.yaml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/Integrations/ESPHome/Core.yaml b/Integrations/ESPHome/Core.yaml index a7f7df3..c4795e9 100644 --- a/Integrations/ESPHome/Core.yaml +++ b/Integrations/ESPHome/Core.yaml @@ -45,18 +45,18 @@ globals: initial_value: "false" # Enable Home Assistant API -# Also Add Buzzer Service Connection +# Also Add Buzzer Action Connection api: - services: - - service: play_buzzer + actions: + - action: play_buzzer variables: song_str: string then: - rtttl.play: rtttl: !lambda 'return song_str;' - #Co2 Calibration Service - - service: calibrate_co2_value + #Co2 Calibration Action + - action: calibrate_co2_value variables: co2_ppm: float then: @@ -65,7 +65,7 @@ api: id: scd40 #Setting HLK Password - - service: set_ld2410_bluetooth_password + - action: set_ld2410_bluetooth_password variables: password: string then: From d7d33acb9c9263601126f28caa5dea8b0f74872e Mon Sep 17 00:00:00 2001 From: Brandon Harvey Date: Tue, 24 Feb 2026 17:17:01 -0600 Subject: [PATCH 12/27] Modernise board spec and remove legacy platformio/BLE config - esp32: board -> variant: esp32c3 + flash_size: 4MB - Remove platformio_options board_build.flash_mode from all device YAMLs - MSR-2_Factory: remove legacy BLE on_connect/on_disconnect wifi hooks --- Integrations/ESPHome/Core.yaml | 3 ++- Integrations/ESPHome/MSR-2.yaml | 3 --- Integrations/ESPHome/MSR-2_BLE.yaml | 3 --- Integrations/ESPHome/MSR-2_Factory.yaml | 7 ------- 4 files changed, 2 insertions(+), 14 deletions(-) diff --git a/Integrations/ESPHome/Core.yaml b/Integrations/ESPHome/Core.yaml index a7f7df3..2cb6218 100644 --- a/Integrations/ESPHome/Core.yaml +++ b/Integrations/ESPHome/Core.yaml @@ -4,7 +4,8 @@ substitutions: device_description: ${name} made by Apollo Automation - version ${version}. esp32: - board: esp32-c3-devkitm-1 + variant: esp32c3 + flash_size: 4MB framework: type: esp-idf diff --git a/Integrations/ESPHome/MSR-2.yaml b/Integrations/ESPHome/MSR-2.yaml index 6c46650..31c827d 100644 --- a/Integrations/ESPHome/MSR-2.yaml +++ b/Integrations/ESPHome/MSR-2.yaml @@ -3,9 +3,6 @@ esphome: friendly_name: Apollo MSR-2 comment: Apollo MSR-2 name_add_mac_suffix: true - platformio_options: - board_build.flash_mode: dio - on_boot: - priority: 900.0 then: diff --git a/Integrations/ESPHome/MSR-2_BLE.yaml b/Integrations/ESPHome/MSR-2_BLE.yaml index 6a8408c..393acd9 100644 --- a/Integrations/ESPHome/MSR-2_BLE.yaml +++ b/Integrations/ESPHome/MSR-2_BLE.yaml @@ -3,9 +3,6 @@ esphome: friendly_name: Apollo MSR-2 comment: Apollo MSR-2 name_add_mac_suffix: true - platformio_options: - board_build.flash_mode: dio - on_boot: - priority: 900.0 then: diff --git a/Integrations/ESPHome/MSR-2_Factory.yaml b/Integrations/ESPHome/MSR-2_Factory.yaml index 2625e73..e4353c9 100644 --- a/Integrations/ESPHome/MSR-2_Factory.yaml +++ b/Integrations/ESPHome/MSR-2_Factory.yaml @@ -3,8 +3,6 @@ esphome: friendly_name: Apollo MSR-2 comment: Apollo MSR-2 name_add_mac_suffix: true - platformio_options: - board_build.flash_mode: dio on_boot: - priority: 900.0 then: @@ -36,11 +34,6 @@ esp32_improv: authorizer: none wifi: - on_connect: - - delay: 5s - - ble.disable: - on_disconnect: - - ble.enable: ap: ssid: "Apollo MSR2 Hotspot" From 797d75e4913c30a3fb41765202f7b0eab055c03c Mon Sep 17 00:00:00 2001 From: Brandon Harvey <8107750+bharvey88@users.noreply.github.com> Date: Wed, 25 Feb 2026 14:51:11 -0600 Subject: [PATCH 13/27] fix: remove unused id, add entity_category diagnostic to IP address sensor --- Integrations/ESPHome/Core.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Integrations/ESPHome/Core.yaml b/Integrations/ESPHome/Core.yaml index 63d0be0..21a31dd 100644 --- a/Integrations/ESPHome/Core.yaml +++ b/Integrations/ESPHome/Core.yaml @@ -716,7 +716,7 @@ text_sensor: - platform: wifi_info ip_address: name: "IP Address" - id: wifi_ip + entity_category: "diagnostic" select: - platform: ld2410 From 0bcb5b79bd68c949beacdeceae8112cf24f5a1b3 Mon Sep 17 00:00:00 2001 From: Brandon Harvey <8107750+bharvey88@users.noreply.github.com> Date: Wed, 25 Feb 2026 15:04:43 -0600 Subject: [PATCH 14/27] fix: restore id: wifi_ip (needed for ESPHome automations) --- Integrations/ESPHome/Core.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/Integrations/ESPHome/Core.yaml b/Integrations/ESPHome/Core.yaml index 21a31dd..536115c 100644 --- a/Integrations/ESPHome/Core.yaml +++ b/Integrations/ESPHome/Core.yaml @@ -716,6 +716,7 @@ text_sensor: - platform: wifi_info ip_address: name: "IP Address" + id: wifi_ip entity_category: "diagnostic" select: From e128ea1b276d2bdd8d5a0025b7a2da38eab94dec Mon Sep 17 00:00:00 2001 From: Brandon Harvey <8107750+bharvey88@users.noreply.github.com> Date: Thu, 26 Feb 2026 07:24:38 -0600 Subject: [PATCH 15/27] feat: apply DPS310 pressure offset in filter lambda --- Integrations/ESPHome/Core.yaml | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/Integrations/ESPHome/Core.yaml b/Integrations/ESPHome/Core.yaml index 46f25ce..1ce12c0 100644 --- a/Integrations/ESPHome/Core.yaml +++ b/Integrations/ESPHome/Core.yaml @@ -343,6 +343,10 @@ sensor: - lambda: |- static float last_reported_value = -6.0; float current_value = x; + float offset = id(dps310_pressure_offset).state; + if (!isnan(offset)) { + current_value += offset; + } // Check if the reduce_db_reporting switch is on if (id(reduce_db_reporting).state) { @@ -560,6 +564,10 @@ sensor: - lambda: |- static float last_reported_value = -21.0; float current_value = x; + float offset = id(dps310_pressure_offset).state; + if (!isnan(offset)) { + current_value += offset; + } // Check if the reduce_db_reporting switch is on if (id(reduce_db_reporting).state) { @@ -583,6 +591,10 @@ sensor: - lambda: |- static float last_reported_value = -21.0; float current_value = x; + float offset = id(dps310_pressure_offset).state; + if (!isnan(offset)) { + current_value += offset; + } // Check if the reduce_db_reporting switch is on if (id(reduce_db_reporting).state) { @@ -609,6 +621,10 @@ sensor: - lambda: |- static float last_reported_value = -6.0; float current_value = x; + float offset = id(dps310_pressure_offset).state; + if (!isnan(offset)) { + current_value += offset; + } // Check if the reduce_db_reporting switch is on if (id(reduce_db_reporting).state) { From 796b4f916732c15f7fa8049e66ebd19cd0f09cdc Mon Sep 17 00:00:00 2001 From: Brandon Harvey <8107750+bharvey88@users.noreply.github.com> Date: Thu, 26 Feb 2026 07:24:39 -0600 Subject: [PATCH 16/27] feat: add DPS310 Pressure Offset configurable number entity --- Integrations/ESPHome/Core.yaml | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/Integrations/ESPHome/Core.yaml b/Integrations/ESPHome/Core.yaml index 1ce12c0..0a2fe43 100644 --- a/Integrations/ESPHome/Core.yaml +++ b/Integrations/ESPHome/Core.yaml @@ -145,6 +145,21 @@ number: name: g8 still threshold + - platform: template + name: "DPS310 Pressure Offset" + id: dps310_pressure_offset + disabled_by_default: true + restore_value: true + initial_value: 0.0 + min_value: -100.0 + max_value: 100.0 + entity_category: "CONFIG" + unit_of_measurement: "hPa" + optimistic: true + update_interval: never + step: 0.1 + mode: box + - platform: template name: DPS Temperature Offset id: dps310_temperature_offset From b8dcd6deb79d67b710b1614e7efa8886bd5765a2 Mon Sep 17 00:00:00 2001 From: Brandon Harvey Date: Tue, 24 Feb 2026 17:15:06 -0600 Subject: [PATCH 17/27] Add ESPHome version and Apollo firmware version text sensors --- Integrations/ESPHome/Core.yaml | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/Integrations/ESPHome/Core.yaml b/Integrations/ESPHome/Core.yaml index 46f25ce..77458b3 100644 --- a/Integrations/ESPHome/Core.yaml +++ b/Integrations/ESPHome/Core.yaml @@ -719,6 +719,16 @@ text_sensor: name: "IP Address" id: wifi_ip entity_category: "diagnostic" + - platform: version + name: "ESPHome Version" + hide_timestamp: true + entity_category: "diagnostic" + - platform: template + name: "Apollo Firmware Version" + id: apollo_firmware_version + lambda: |- + return {"${version}"}; + entity_category: "diagnostic" select: - platform: ld2410 From 3420441d443c89aace30f7f5f1ad42ef0fc10ef2 Mon Sep 17 00:00:00 2001 From: Brandon Harvey <8107750+bharvey88@users.noreply.github.com> Date: Thu, 26 Feb 2026 07:01:29 -0600 Subject: [PATCH 18/27] fix: add entity_category diagnostic to ESPHome Version sensor --- Integrations/ESPHome/Core.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/Integrations/ESPHome/Core.yaml b/Integrations/ESPHome/Core.yaml index 77458b3..86fab41 100644 --- a/Integrations/ESPHome/Core.yaml +++ b/Integrations/ESPHome/Core.yaml @@ -723,6 +723,7 @@ text_sensor: name: "ESPHome Version" hide_timestamp: true entity_category: "diagnostic" + entity_category: "diagnostic" - platform: template name: "Apollo Firmware Version" id: apollo_firmware_version From e349e0c82e75427452cf1737fb294b9a13d2664c Mon Sep 17 00:00:00 2001 From: Brandon Harvey <8107750+bharvey88@users.noreply.github.com> Date: Thu, 26 Feb 2026 07:01:30 -0600 Subject: [PATCH 19/27] fix: add update_interval: never to static Apollo Firmware Version sensor --- Integrations/ESPHome/Core.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/Integrations/ESPHome/Core.yaml b/Integrations/ESPHome/Core.yaml index 86fab41..20e4e23 100644 --- a/Integrations/ESPHome/Core.yaml +++ b/Integrations/ESPHome/Core.yaml @@ -729,6 +729,7 @@ text_sensor: id: apollo_firmware_version lambda: |- return {"${version}"}; + update_interval: never entity_category: "diagnostic" select: From 2268d77d50befb55294a56d12b6e436997005c07 Mon Sep 17 00:00:00 2001 From: Brandon Harvey <8107750+bharvey88@users.noreply.github.com> Date: Thu, 26 Feb 2026 07:05:34 -0600 Subject: [PATCH 20/27] fix: remove duplicate entity_category keys in ESPHome Version sensor --- Integrations/ESPHome/Core.yaml | 1 - 1 file changed, 1 deletion(-) diff --git a/Integrations/ESPHome/Core.yaml b/Integrations/ESPHome/Core.yaml index 20e4e23..e6b205f 100644 --- a/Integrations/ESPHome/Core.yaml +++ b/Integrations/ESPHome/Core.yaml @@ -723,7 +723,6 @@ text_sensor: name: "ESPHome Version" hide_timestamp: true entity_category: "diagnostic" - entity_category: "diagnostic" - platform: template name: "Apollo Firmware Version" id: apollo_firmware_version From 1f5d0ae34b0d1a0a68e7e192963f5453d77608b5 Mon Sep 17 00:00:00 2001 From: Brandon Harvey Date: Fri, 27 Feb 2026 14:30:04 -0600 Subject: [PATCH 21/27] feat: disable LTR390 update interval entity by default --- Integrations/ESPHome/Core.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/Integrations/ESPHome/Core.yaml b/Integrations/ESPHome/Core.yaml index 244a26f..303fc4f 100644 --- a/Integrations/ESPHome/Core.yaml +++ b/Integrations/ESPHome/Core.yaml @@ -164,6 +164,7 @@ number: - platform: template name: LTR390 Update Interval id: ltr390_update_interval + disabled_by_default: true restore_value: true initial_value: 60 min_value: 1 From 3fb5fba7d5e3a509070f9f884883b5d8dc7206be Mon Sep 17 00:00:00 2001 From: Brandon Harvey Date: Sun, 1 Mar 2026 13:11:50 -0600 Subject: [PATCH 22/27] Fix: remove pressure offset from non-DPS310 sensor lambdas dps310_pressure_offset was incorrectly applied to three sensors that have no relation to barometric pressure: ESP internal temperature, LTR390 light, and LTR390 UV Index. The offset is now applied only in the DPS310 pressure sensor lambda where it belongs. Co-Authored-By: Claude Sonnet 4.6 --- Integrations/ESPHome/Core.yaml | 12 ------------ 1 file changed, 12 deletions(-) diff --git a/Integrations/ESPHome/Core.yaml b/Integrations/ESPHome/Core.yaml index 0a2fe43..313442d 100644 --- a/Integrations/ESPHome/Core.yaml +++ b/Integrations/ESPHome/Core.yaml @@ -358,10 +358,6 @@ sensor: - lambda: |- static float last_reported_value = -6.0; float current_value = x; - float offset = id(dps310_pressure_offset).state; - if (!isnan(offset)) { - current_value += offset; - } // Check if the reduce_db_reporting switch is on if (id(reduce_db_reporting).state) { @@ -579,10 +575,6 @@ sensor: - lambda: |- static float last_reported_value = -21.0; float current_value = x; - float offset = id(dps310_pressure_offset).state; - if (!isnan(offset)) { - current_value += offset; - } // Check if the reduce_db_reporting switch is on if (id(reduce_db_reporting).state) { @@ -606,10 +598,6 @@ sensor: - lambda: |- static float last_reported_value = -21.0; float current_value = x; - float offset = id(dps310_pressure_offset).state; - if (!isnan(offset)) { - current_value += offset; - } // Check if the reduce_db_reporting switch is on if (id(reduce_db_reporting).state) { From a6d74c1bfa032dfec691a3767af0a54b2d6f2422 Mon Sep 17 00:00:00 2001 From: Brandon Harvey Date: Mon, 2 Mar 2026 15:05:40 -0600 Subject: [PATCH 23/27] Fix LTR390 interval lambda: handle NAN state, remove boot timing guard --- Integrations/ESPHome/Core.yaml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/Integrations/ESPHome/Core.yaml b/Integrations/ESPHome/Core.yaml index 7562310..e3922fd 100644 --- a/Integrations/ESPHome/Core.yaml +++ b/Integrations/ESPHome/Core.yaml @@ -727,10 +727,11 @@ interval: - lambda: |- uint32_t current_time = millis() / 1000; // Convert to seconds uint32_t last_update = id(ltr390_last_update); - uint32_t interval = (uint32_t)id(ltr390_update_interval).state; + float configured_interval = id(ltr390_update_interval).state; + uint32_t interval = (configured_interval >= 1.0f) ? (uint32_t)configured_interval : 60u; // Immediate update on boot (when last_update is still 0) - if (last_update == 0 && current_time > 0) { + if (last_update == 0) { id(ltr_390).update(); id(ltr390_last_update) = current_time; return; From 543e2994f509db36767e7412cbb6634c81cb7395 Mon Sep 17 00:00:00 2001 From: Brandon Harvey <8107750+bharvey88@users.noreply.github.com> Date: Mon, 2 Mar 2026 15:23:42 -0600 Subject: [PATCH 24/27] Bump version to 26.3.2.1 --- Integrations/ESPHome/Core.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Integrations/ESPHome/Core.yaml b/Integrations/ESPHome/Core.yaml index 7562310..9a27440 100644 --- a/Integrations/ESPHome/Core.yaml +++ b/Integrations/ESPHome/Core.yaml @@ -1,6 +1,6 @@ substitutions: name: apollo-msr-2 - version: "25.8.12.1" + version: "26.3.2.1" device_description: ${name} made by Apollo Automation - version ${version}. esp32: From 9ef21bc62f36045d738203919a39e369f0e00f56 Mon Sep 17 00:00:00 2001 From: bharvey88 <8107750+bharvey88@users.noreply.github.com> Date: Fri, 6 Mar 2026 12:54:35 -0600 Subject: [PATCH 25/27] Fix Apollo Firmware Version sensor showing unknown --- Integrations/ESPHome/Core.yaml | 1 - 1 file changed, 1 deletion(-) diff --git a/Integrations/ESPHome/Core.yaml b/Integrations/ESPHome/Core.yaml index 1b03657..9ce4ded 100644 --- a/Integrations/ESPHome/Core.yaml +++ b/Integrations/ESPHome/Core.yaml @@ -788,7 +788,6 @@ text_sensor: id: apollo_firmware_version lambda: |- return {"${version}"}; - update_interval: never entity_category: "diagnostic" select: From e6bd10f05aba32021175f656e3d4278ead15c629 Mon Sep 17 00:00:00 2001 From: Brandon Harvey Date: Fri, 6 Mar 2026 17:18:20 -0600 Subject: [PATCH 26/27] fix: publish firmware version once on boot instead of polling Per ESPHome dev feedback: the version is a compile-time constant, so publish it once on_boot rather than using a lambda with periodic updates. --- Integrations/ESPHome/Core.yaml | 3 +-- Integrations/ESPHome/MSR-2.yaml | 3 +++ 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/Integrations/ESPHome/Core.yaml b/Integrations/ESPHome/Core.yaml index 9ce4ded..fc36704 100644 --- a/Integrations/ESPHome/Core.yaml +++ b/Integrations/ESPHome/Core.yaml @@ -786,8 +786,7 @@ text_sensor: - platform: template name: "Apollo Firmware Version" id: apollo_firmware_version - lambda: |- - return {"${version}"}; + update_interval: never entity_category: "diagnostic" select: diff --git a/Integrations/ESPHome/MSR-2.yaml b/Integrations/ESPHome/MSR-2.yaml index 31c827d..0c2f39f 100644 --- a/Integrations/ESPHome/MSR-2.yaml +++ b/Integrations/ESPHome/MSR-2.yaml @@ -6,6 +6,9 @@ esphome: on_boot: - priority: 900.0 then: + - text_sensor.template.publish: + id: apollo_firmware_version + state: "${version}" - lambda: |- id(radar_bluetooth).turn_off(); - priority: -10 From db71fea7cc707065e06b8e93a3784d92ab9b05ca Mon Sep 17 00:00:00 2001 From: Brandon Harvey Date: Fri, 6 Mar 2026 18:24:58 -0600 Subject: [PATCH 27/27] fix: move firmware version publish to priority 500 for all variants Move publish from priority 900 to separate 500 block in MSR-2.yaml. Add publish at priority 500 to MSR-2_BLE and MSR-2_Factory. --- Integrations/ESPHome/MSR-2.yaml | 6 ++++-- Integrations/ESPHome/MSR-2_BLE.yaml | 5 +++++ Integrations/ESPHome/MSR-2_Factory.yaml | 5 +++++ 3 files changed, 14 insertions(+), 2 deletions(-) diff --git a/Integrations/ESPHome/MSR-2.yaml b/Integrations/ESPHome/MSR-2.yaml index 0c2f39f..78fdd46 100644 --- a/Integrations/ESPHome/MSR-2.yaml +++ b/Integrations/ESPHome/MSR-2.yaml @@ -5,12 +5,14 @@ esphome: name_add_mac_suffix: true on_boot: - priority: 900.0 + then: + - lambda: |- + id(radar_bluetooth).turn_off(); + - priority: 500 then: - text_sensor.template.publish: id: apollo_firmware_version state: "${version}" - - lambda: |- - id(radar_bluetooth).turn_off(); - priority: -10 then: - if: diff --git a/Integrations/ESPHome/MSR-2_BLE.yaml b/Integrations/ESPHome/MSR-2_BLE.yaml index 393acd9..480104e 100644 --- a/Integrations/ESPHome/MSR-2_BLE.yaml +++ b/Integrations/ESPHome/MSR-2_BLE.yaml @@ -8,6 +8,11 @@ esphome: then: - lambda: |- id(radar_bluetooth).turn_off(); + - priority: 500 + then: + - text_sensor.template.publish: + id: apollo_firmware_version + state: "${version}" - priority: -10 then: - if: diff --git a/Integrations/ESPHome/MSR-2_Factory.yaml b/Integrations/ESPHome/MSR-2_Factory.yaml index e4353c9..04b3aae 100644 --- a/Integrations/ESPHome/MSR-2_Factory.yaml +++ b/Integrations/ESPHome/MSR-2_Factory.yaml @@ -8,6 +8,11 @@ esphome: then: - lambda: |- id(radar_bluetooth).turn_off(); + - priority: 500 + then: + - text_sensor.template.publish: + id: apollo_firmware_version + state: "${version}" - priority: -10 then: - if: