diff --git a/components/tc_bus/__init__.py b/components/tc_bus/__init__.py index 965813a..5c82a63 100644 --- a/components/tc_bus/__init__.py +++ b/components/tc_bus/__init__.py @@ -49,10 +49,10 @@ "floor_call": COMMAND_TYPE.COMMAND_TYPE_FLOOR_CALL, "internal_call": COMMAND_TYPE.COMMAND_TYPE_INTERNAL_CALL, "control_function": COMMAND_TYPE.COMMAND_TYPE_CONTROL_FUNCTION, - "start_talking_door_station": COMMAND_TYPE.COMMAND_TYPE_START_TALKING_DOOR_STATION, - "start_talking_ia": COMMAND_TYPE.COMMAND_TYPE_START_TALKING_IA, - "stop_talking_door_station": COMMAND_TYPE.COMMAND_TYPE_STOP_TALKING_DOOR_STATION, - "stop_talking_ia": COMMAND_TYPE.COMMAND_TYPE_STOP_TALKING_IA, + "start_talking_door_call": COMMAND_TYPE.COMMAND_TYPE_START_TALKING_DOOR_CALL, + "start_talking": COMMAND_TYPE.COMMAND_TYPE_START_TALKING, + "stop_talking_door_call": COMMAND_TYPE.COMMAND_TYPE_STOP_TALKING_DOOR_CALL, + "stop_talking": COMMAND_TYPE.COMMAND_TYPE_STOP_TALKING, "open_door": COMMAND_TYPE.COMMAND_TYPE_OPEN_DOOR, "light": COMMAND_TYPE.COMMAND_TYPE_LIGHT, "door_opened": COMMAND_TYPE.COMMAND_TYPE_DOOR_OPENED, diff --git a/components/tc_bus/protocol.cpp b/components/tc_bus/protocol.cpp index dc442f8..96306bd 100644 --- a/components/tc_bus/protocol.cpp +++ b/components/tc_bus/protocol.cpp @@ -34,27 +34,27 @@ namespace esphome command |= 0x41; // 41 break; - case COMMAND_TYPE_START_TALKING_IA: + case COMMAND_TYPE_START_TALKING_DOOR_CALL: command |= (3 << 28); // 3 command |= ((serial_number & 0xFFFFF) << 8); // C30BA command |= (1 << 7); // 8 command |= (address & 0xFF); // 0 break; - case COMMAND_TYPE_START_TALKING_DOOR_STATION: + case COMMAND_TYPE_START_TALKING: command |= (3 << 28); // 3 command |= ((serial_number & 0xFFFFF) << 8); // C30BA command &= ~(1 << 7); // 0 command |= (address & 0xFF); // 0 break; - case COMMAND_TYPE_STOP_TALKING_IA: + case COMMAND_TYPE_STOP_TALKING_DOOR_CALL: command |= (3 << 12); // 3 command |= (1 << 7); // 08 command |= (address & 0xFF); // 0 break; - case COMMAND_TYPE_STOP_TALKING_DOOR_STATION: + case COMMAND_TYPE_STOP_TALKING: command |= (3 << 12); // 3 command &= ~(1 << 7); // 00 command |= (address & 0xFF); // 0 @@ -185,11 +185,11 @@ namespace esphome break; case 3: - data.type = (command & (1 << 7)) ? COMMAND_TYPE_START_TALKING_IA : COMMAND_TYPE_START_TALKING_DOOR_STATION; + data.type = (command & (1 << 7)) ? COMMAND_TYPE_START_TALKING_DOOR_CALL : COMMAND_TYPE_START_TALKING; data.address = command & 0xF; // Door Readiness - if(data.type == COMMAND_TYPE_START_TALKING_DOOR_STATION) + if(data.type == COMMAND_TYPE_START_TALKING_DOOR_CALL) { data.payload = (command & (1 << 8)) != 0; } @@ -292,7 +292,7 @@ namespace esphome } else if (first == 3) { - data.type = (command & (1 << 7)) ? COMMAND_TYPE_STOP_TALKING_IA : COMMAND_TYPE_STOP_TALKING_DOOR_STATION; + data.type = (command & (1 << 7)) ? COMMAND_TYPE_STOP_TALKING_DOOR_CALL : COMMAND_TYPE_STOP_TALKING; data.address = command & 0xF; } else if (first == 5) @@ -387,10 +387,10 @@ namespace esphome if (str == "FLOOR_CALL") return COMMAND_TYPE_FLOOR_CALL; if (str == "INTERNAL_CALL") return COMMAND_TYPE_INTERNAL_CALL; if (str == "CONTROL_FUNCTION") return COMMAND_TYPE_CONTROL_FUNCTION; - if (str == "START_TALKING_DOOR_STATION") return COMMAND_TYPE_START_TALKING_DOOR_STATION; - if (str == "START_TALKING_IA") return COMMAND_TYPE_START_TALKING_IA; - if (str == "STOP_TALKING_DOOR_STATION") return COMMAND_TYPE_STOP_TALKING_DOOR_STATION; - if (str == "STOP_TALKING_IA") return COMMAND_TYPE_STOP_TALKING_IA; + if (str == "START_TALKING_DOOR_CALL") return COMMAND_TYPE_START_TALKING_DOOR_CALL; + if (str == "START_TALKING") return COMMAND_TYPE_START_TALKING; + if (str == "STOP_TALKING_DOOR_CALL") return COMMAND_TYPE_STOP_TALKING_DOOR_CALL; + if (str == "STOP_TALKING") return COMMAND_TYPE_STOP_TALKING; if (str == "OPEN_DOOR") return COMMAND_TYPE_OPEN_DOOR; if (str == "LIGHT") return COMMAND_TYPE_LIGHT; if (str == "DOOR_OPENED") return COMMAND_TYPE_DOOR_OPENED; @@ -421,10 +421,10 @@ namespace esphome case COMMAND_TYPE_FLOOR_CALL: return "FLOOR_CALL"; case COMMAND_TYPE_INTERNAL_CALL: return "INTERNAL_CALL"; case COMMAND_TYPE_CONTROL_FUNCTION: return "CONTROL_FUNCTION"; - case COMMAND_TYPE_START_TALKING_DOOR_STATION: return "START_TALKING_DOOR_STATION"; - case COMMAND_TYPE_START_TALKING_IA: return "START_TALKING_IA"; - case COMMAND_TYPE_STOP_TALKING_DOOR_STATION: return "STOP_TALKING_DOOR_STATION"; - case COMMAND_TYPE_STOP_TALKING_IA: return "STOP_TALKING_IA"; + case COMMAND_TYPE_START_TALKING_DOOR_CALL: return "START_TALKING_DOOR_CALL"; + case COMMAND_TYPE_START_TALKING: return "START_TALKING"; + case COMMAND_TYPE_STOP_TALKING_DOOR_CALL: return "STOP_TALKING_DOOR_CALL"; + case COMMAND_TYPE_STOP_TALKING: return "STOP_TALKING"; case COMMAND_TYPE_OPEN_DOOR: return "OPEN_DOOR"; case COMMAND_TYPE_LIGHT: return "LIGHT"; case COMMAND_TYPE_DOOR_OPENED: return "DOOR_OPENED"; diff --git a/components/tc_bus/protocol.h b/components/tc_bus/protocol.h index c816965..78de33a 100644 --- a/components/tc_bus/protocol.h +++ b/components/tc_bus/protocol.h @@ -27,10 +27,10 @@ namespace esphome COMMAND_TYPE_FLOOR_CALL, COMMAND_TYPE_INTERNAL_CALL, COMMAND_TYPE_CONTROL_FUNCTION, - COMMAND_TYPE_START_TALKING_DOOR_STATION, - COMMAND_TYPE_START_TALKING_IA, - COMMAND_TYPE_STOP_TALKING_DOOR_STATION, - COMMAND_TYPE_STOP_TALKING_IA, + COMMAND_TYPE_START_TALKING_DOOR_CALL, + COMMAND_TYPE_START_TALKING, + COMMAND_TYPE_STOP_TALKING_DOOR_CALL, + COMMAND_TYPE_STOP_TALKING, COMMAND_TYPE_OPEN_DOOR, COMMAND_TYPE_LIGHT, COMMAND_TYPE_DOOR_OPENED, diff --git a/docs/de/guide/getting-started.md b/docs/de/guide/getting-started.md index 2be4214..5d88519 100644 --- a/docs/de/guide/getting-started.md +++ b/docs/de/guide/getting-started.md @@ -89,6 +89,10 @@ Du musst den Modus nicht manuell aktivieren; er wird bei jedem Neustart automati 2. **Setup-Modus aktivieren:**\ Gehe zum Bereich `Konfiguration` und schalte den `Setup Mode` ein, um die interaktive Einrichtung zu beginnen. +::: warning Bevor du weitermachst +Deine Gegensprechanlage muss angeschlossen und das Gehäuse verschlossen sein, damit die Einrichtung abgeschlossen werden kann. +::: + 3. **Einrichtung durchführen:**\ Die RGB-Status-LED wird grün-türkis pulsieren. Drücke den Klingeltaster vor der Wohnung oder am Eingang. diff --git a/docs/en/guide/getting-started.md b/docs/en/guide/getting-started.md index abbc886..bafad50 100644 --- a/docs/en/guide/getting-started.md +++ b/docs/en/guide/getting-started.md @@ -43,7 +43,7 @@ Example: > > Starting with revision `1.5` this method will only produce a subtle, yet noticeable hissing sound on the speaker. -After connecting the `a` and `b` lines, you still need to connect `BUS PWR` using a jumper cap. +After connecting the `a` and `b` lines, you need to connect `BUS PWR` using a jumper cap. Example: ![2-wire via intercom jumper](./images/2wire_intercom.png){width=300px} @@ -83,6 +83,10 @@ You don't need to manually activate this mode; it will start automatically at ea 2. **Activate Setup Mode:**\ Go to the `Configuration` section and enable `Setup Mode` to begin the interactive setup. +::: warning Before you proceed +The intercom phone must be connected, and the enclosure securely closed, to complete the setup process. +::: + 3. **Perform the Setup:**\ The RGB status LED will pulse green-turquoise. Press the doorbell button at your apartment or entrance. diff --git a/firmware/base.yaml b/firmware/base.yaml index 908f73a..afc196f 100644 --- a/firmware/base.yaml +++ b/firmware/base.yaml @@ -377,31 +377,57 @@ binary_sensor: sorting_group_id: sorting_group_listeners sorting_weight: -29 + - platform: tc_bus + id: pick_up_phone_door_call + name: "Pick up phone (door call)" + icon: "mdi:phone-check" + type: start_talking_door_call + address: 255 + auto_off: 0.2s + entity_category: DIAGNOSTIC + disabled_by_default: true + web_server: + sorting_group_id: sorting_group_listeners + sorting_weight: -19 + + - platform: tc_bus + id: hang_up_phone_door_call + name: "Hang up phone (door call)" + icon: "mdi:phone-remove" + type: stop_talking_door_call + address: 255 + auto_off: 0.2s + entity_category: DIAGNOSTIC + disabled_by_default: true + web_server: + sorting_group_id: sorting_group_listeners + sorting_weight: -18 + - platform: tc_bus id: pick_up_phone name: "Pick up phone" icon: "mdi:phone-check" - type: start_talking_door_station + type: start_talking address: 255 auto_off: 0.2s entity_category: DIAGNOSTIC disabled_by_default: true web_server: sorting_group_id: sorting_group_listeners - sorting_weight: -19 + sorting_weight: -17 - platform: tc_bus id: hang_up_phone name: "Hang up phone" icon: "mdi:phone-remove" - type: stop_talking_door_station + type: stop_talking address: 255 auto_off: 0.2s entity_category: DIAGNOSTIC disabled_by_default: true web_server: sorting_group_id: sorting_group_listeners - sorting_weight: -18 + sorting_weight: -16 - platform: tc_bus id: function_button