Skip to content

Commit

Permalink
Start secplus_gdo before MQTT so that state is initialized before MQT…
Browse files Browse the repository at this point in the history
…T reports initial state
  • Loading branch information
heythisisnate committed Oct 18, 2024
1 parent 3da1d6b commit f0fcf4a
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions components/secplus_gdo/secplus_gdo.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -101,11 +101,11 @@ namespace secplus_gdo {
status->paired_devices.total_wall_controls, status->paired_devices.total_accessories,
status->paired_devices.total_all);
break;
case GDO_CB_EVENT_OPEN_DURATION_MEASURMENT:
case GDO_CB_EVENT_OPEN_DURATION_MEASUREMENT:
ESP_LOGI(TAG, "Open duration: %d", status->open_ms);
gdo->set_open_duration(status->open_ms);
break;
case GDO_CB_EVENT_CLOSE_DURATION_MEASURMENT:
case GDO_CB_EVENT_CLOSE_DURATION_MEASUREMENT:
ESP_LOGI(TAG, "Close duration: %d", status->close_ms);
gdo->set_close_duration(status->close_ms);
break;
Expand Down
2 changes: 1 addition & 1 deletion components/secplus_gdo/secplus_gdo.h
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ namespace secplus_gdo {
void start_gdo() { start_gdo_ = true; }

// Use Late priority so we do not start the GDO lib until all saved preferences are loaded
float get_setup_priority() const override { return setup_priority::LATE; }
float get_setup_priority() const override { return setup_priority::BEFORE_CONNECTION; }

void register_protocol_select(GDOSelect *select) { this->protocol_select_ = select; }
void set_protocol_state(gdo_protocol_type_t protocol) { if (this->protocol_select_) {
Expand Down
4 changes: 2 additions & 2 deletions garage-door-GDOv2-Q.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ substitutions:
name: konnected
friendly_name: GDO blaQ
project_name: konnected.garage-door-gdov2-q
project_version: "1.3.2"
project_version: "1.3.3"
garage_door_cover_name: Garage Door
garage_light_name: Garage Light
garage_openings_name: Garage Openings
Expand Down Expand Up @@ -186,7 +186,7 @@ web_server:
esphome:
platformio_options:
lib_deps:
- https://github.com/konnected-io/gdolib#76ba232
- https://github.com/konnected-io/gdolib#4a55112
build_flags:
- -DUART_SCLK_DEFAULT=UART_SCLK_APB
- -Wl,--wrap=esp_panic_handler

0 comments on commit f0fcf4a

Please sign in to comment.