Updated hoerman_door to esphome 2025.11.3...

Breaking changes existed in 2025.11.0
See https://github.com/esphome/esphome/pull/11704 for more information
This commit is contained in:
2025-12-04 01:47:24 +01:00
parent 1f7c437c3e
commit 4a0035d607
6 changed files with 40 additions and 16 deletions

View File

@@ -14,6 +14,12 @@
namespace esphome {
namespace hoermann_door {
enum DoorOpeningState {
OPENING = 0,
CLOSING = 1,
NO_ACTION = 2
};
class HoermannDoor : public Component, public cover::Cover
{
private:
@@ -53,12 +59,29 @@ public:
manual = false;
}
else{
ESP_LOGD(COMP_TAG, "Not yet supported");
uint8_t state = mainComponent->getEmulator()->getState().doorCurrentPosition;
switch(state){
case DoorState::DOOR_CLOSE_POSITION:
case DoorState::DOOR_OPEN_POSITION:
case DoorState::DOOR_HALF_POSITION:
break;
case DoorState::DOOR_MOVE_CLOSEPOSITION:
break;
case DoorState::DOOR_MOVE_OPENPOSITION:
break;
default:
ESP_LOGE(TAG, "ERROR, HCIEmulator reported door state as something else than normal values");
}
}
}
if (call.get_stop()) {
mainComponent->getEmulator()->stopDoor();
}
//if(call.get_close()) {
//emulator.closeDoor();