diff --git a/lanbon-l9-hf.yaml b/lanbon-l9-hf.yaml index c8851b2..3a99ba4 100644 --- a/lanbon-l9-hf.yaml +++ b/lanbon-l9-hf.yaml @@ -83,13 +83,15 @@ network: enable_ipv6: true # min_ipv6_addr_count: 2 -# TODO: test to make sure bluetooth proxy doesn't cause boot looping! -# esp32_ble_tracker: -# scan_parameters: -# active: false -# -# bluetooth_proxy: -# active: false +esp32_improv: + authorizer: authorize_improv_over_ble_binary_sensor + +esp32_ble_tracker: + scan_parameters: + active: false + +bluetooth_proxy: + active: false time: - id: !extend ${time_source} @@ -222,6 +224,12 @@ binary_sensor: condition: lvgl.is_paused: + - platform: template + id: authorize_improv_over_ble_binary_sensor + name: Authorizing Improv-over-BLE + entity_category: diagnostic + internal: true + light: - platform: monochromatic id: display_backlight @@ -594,6 +602,47 @@ lvgl: text_align: CENTER text_font: roboto_20 + - id: page_setup + widgets: + - button: + width: 164 + height: 100 + x: 2 + y: 58 + id: authorize_improv_over_ble_lvgl_button + on_press: + - logger.log: "Authorizing Improv-over-BLE" + - binary_sensor.template.publish: + id: authorize_improv_over_ble_binary_sensor + state: ON + on_release: + - binary_sensor.template.publish: + id: authorize_improv_over_ble_binary_sensor + state: OFF + widgets: + - label: + id: authorize_improv_over_ble_lvgl_button_label + align: CENTER + text: "Improv-over-BLE\nAuthorize" + text_align: CENTER + text_font: roboto_20 + + - button: + width: 164 + height: 100 + x: 2 + y: 162 + id: page_setup_lvgl_cancel_button + on_release: + - lvgl.page.show: page_main + widgets: + - label: + id: page_setup_lvgl_cancel_button_label + align: CENTER + text: "Cancel" + text_align: CENTER + text_font: roboto_20 + globals: - id: factory_reset_lvgl_button_longpress_ms type: int diff --git a/shelly-em-gen3.yaml b/shelly-em-gen3.yaml index 57f4161..497d7f4 100644 --- a/shelly-em-gen3.yaml +++ b/shelly-em-gen3.yaml @@ -110,12 +110,17 @@ i2c: sda: GPIO7 scan: true -# esp32_ble_tracker: -# scan_parameters: -# active: false -# -# bluetooth_proxy: -# active: false +improv_serial: + +esp32_improv: + authorizer: shelly_button_id + +esp32_ble_tracker: + scan_parameters: + active: false + +bluetooth_proxy: + active: false light: - platform: status_led diff --git a/shelly-plus-1pm-ul.yaml b/shelly-plus-1pm-ul.yaml index d04ef73..827525a 100644 --- a/shelly-plus-1pm-ul.yaml +++ b/shelly-plus-1pm-ul.yaml @@ -87,6 +87,18 @@ wifi: captive_portal: +improv_serial: + +esp32_improv: + authorizer: shelly_button_id + +esp32_ble_tracker: + scan_parameters: + active: false + +bluetooth_proxy: + active: false + output: - platform: gpio id: "relay_output" diff --git a/shelly-plus-i4.yaml b/shelly-plus-i4.yaml index b1d2538..70b8b04 100644 --- a/shelly-plus-i4.yaml +++ b/shelly-plus-i4.yaml @@ -81,6 +81,18 @@ wifi: captive_portal: +improv_serial: + +esp32_improv: + authorizer: shelly_button_id + +esp32_ble_tracker: + scan_parameters: + active: false + +bluetooth_proxy: + active: false + binary_sensor: - platform: gpio id: sw1 diff --git a/shelly-pm-mini-gen3.yaml b/shelly-pm-mini-gen3.yaml index 41b9f20..712d2c8 100644 --- a/shelly-pm-mini-gen3.yaml +++ b/shelly-pm-mini-gen3.yaml @@ -70,12 +70,17 @@ network: enable_ipv6: true # min_ipv6_addr_count: 2 -# esp32_ble_tracker: -# scan_parameters: -# active: false +improv_serial: -# bluetooth_proxy: -# active: false +esp32_improv: + authorizer: shelly_button_id + +esp32_ble_tracker: + scan_parameters: + active: false + +bluetooth_proxy: + active: false light: - platform: status_led