Skip to content

Commit b426bdd

Browse files
authored
Merge pull request #111 from edwardtfn/remove-duplicated-names
Support to ESPHome 2025.7.0
2 parents ddb5e0f + 3cdd9f8 commit b426bdd

12 files changed

+101
-282
lines changed

.github/workflows/validate_esphome.yml

Lines changed: 0 additions & 72 deletions
Original file line numberDiff line numberDiff line change
@@ -55,18 +55,6 @@ jobs:
5555
yaml-file: ".test/esphome_idf_core.yaml"
5656
version: latest
5757

58-
build_idf53_core:
59-
name: Core (IDF v5.3)
60-
needs: code_scan
61-
runs-on: ubuntu-latest
62-
steps:
63-
- uses: actions/checkout@main
64-
- name: Build Core (IDF v5.3)
65-
uses: esphome/build-action@main
66-
with:
67-
yaml-file: ".test/esphome_idf53_core.yaml"
68-
version: latest
69-
7058
build_ard_basic:
7159
name: Basic (Arduino)
7260
needs: build_ard_core
@@ -91,18 +79,6 @@ jobs:
9179
yaml-file: ".test/esphome_idf_basic.yaml"
9280
version: latest
9381

94-
build_idf53_basic:
95-
name: Basic (IDF v5.3)
96-
needs: build_idf53_core
97-
runs-on: ubuntu-latest
98-
steps:
99-
- uses: actions/checkout@main
100-
- name: Build Basic (IDF v5.3)
101-
uses: esphome/build-action@main
102-
with:
103-
yaml-file: ".test/esphome_idf53_basic.yaml"
104-
version: latest
105-
10682
build_ard_hw_relays:
10783
name: HW Relays (Arduino)
10884
needs: build_ard_core
@@ -127,18 +103,6 @@ jobs:
127103
yaml-file: ".test/esphome_idf_hw_relays.yaml"
128104
version: latest
129105

130-
build_idf53_hw_relays:
131-
name: HW Relays (IDF v5.3)
132-
needs: build_idf53_core
133-
runs-on: ubuntu-latest
134-
steps:
135-
- uses: actions/checkout@main
136-
- name: Build HW Relays (IDF v5.3)
137-
uses: esphome/build-action@main
138-
with:
139-
yaml-file: ".test/esphome_idf53_hw_relays.yaml"
140-
version: latest
141-
142106
build_ard_hw_speaker:
143107
name: HW Speaker (Arduino)
144108
needs: build_ard_core
@@ -163,18 +127,6 @@ jobs:
163127
yaml-file: ".test/esphome_idf_hw_speaker.yaml"
164128
version: latest
165129

166-
build_idf53_hw_speaker:
167-
name: HW Speaker (IDF v5.3)
168-
needs: build_idf53_core
169-
runs-on: ubuntu-latest
170-
steps:
171-
- uses: actions/checkout@main
172-
- name: Build HW Speaker (IDF v5.3)
173-
uses: esphome/build-action@main
174-
with:
175-
yaml-file: ".test/esphome_idf53_hw_speaker.yaml"
176-
version: latest
177-
178130
build_ard_hw_vibration:
179131
name: HW Vibration (Arduino)
180132
needs: build_ard_core
@@ -199,18 +151,6 @@ jobs:
199151
yaml-file: ".test/esphome_idf_hw_vibration.yaml"
200152
version: latest
201153

202-
build_idf53_hw_vibration:
203-
name: HW Vibration (IDF v5.3)
204-
needs: build_idf53_core
205-
runs-on: ubuntu-latest
206-
steps:
207-
- uses: actions/checkout@main
208-
- name: Build HW Vibration (IDF v5.3)
209-
uses: esphome/build-action@main
210-
with:
211-
yaml-file: ".test/esphome_idf53_hw_vibration.yaml"
212-
version: latest
213-
214154
build_ard_ble_proxy:
215155
name: Bluetooth Proxy (Ard)
216156
needs: build_ard_basic
@@ -235,18 +175,6 @@ jobs:
235175
yaml-file: ".test/esphome_idf_ble_proxy.yaml"
236176
version: latest
237177

238-
build_idf53_ble_proxy:
239-
name: Bluetooth Proxy (IDF v5.3)
240-
needs: build_idf53_basic
241-
runs-on: ubuntu-latest
242-
steps:
243-
- uses: actions/checkout@main
244-
- name: Build BLE Proxy (IDF v5.3)
245-
uses: esphome/build-action@main
246-
with:
247-
yaml-file: ".test/esphome_idf53_ble_proxy.yaml"
248-
version: latest
249-
250178
build_ard_media_player:
251179
name: Media Player (Ard)
252180
needs:

.github/workflows/validate_esphome_beta.yml

Lines changed: 0 additions & 72 deletions
Original file line numberDiff line numberDiff line change
@@ -73,18 +73,6 @@ jobs:
7373
yaml-file: ".test/esphome_idf_core.yaml"
7474
version: beta
7575

76-
build_idf53_core:
77-
name: Core (IDF v5.3)
78-
needs: code_scan
79-
runs-on: ubuntu-latest
80-
steps:
81-
- uses: actions/checkout@main
82-
- name: Build Core (IDF v5.3)
83-
uses: esphome/build-action@main
84-
with:
85-
yaml-file: ".test/esphome_idf53_core.yaml"
86-
version: beta
87-
8876
build_ard_basic:
8977
name: Basic (Arduino)
9078
needs: build_ard_core
@@ -109,18 +97,6 @@ jobs:
10997
yaml-file: ".test/esphome_idf_basic.yaml"
11098
version: beta
11199

112-
build_idf53_basic:
113-
name: Basic (IDF v5.3)
114-
needs: build_idf53_core
115-
runs-on: ubuntu-latest
116-
steps:
117-
- uses: actions/checkout@main
118-
- name: Build Basic (IDF v5.3)
119-
uses: esphome/build-action@main
120-
with:
121-
yaml-file: ".test/esphome_idf53_basic.yaml"
122-
version: beta
123-
124100
build_ard_hw_relays:
125101
name: HW Relays (Arduino)
126102
needs: build_ard_core
@@ -145,18 +121,6 @@ jobs:
145121
yaml-file: ".test/esphome_idf_hw_relays.yaml"
146122
version: beta
147123

148-
build_idf53_hw_relays:
149-
name: HW Relays (IDF v5.3)
150-
needs: build_idf53_core
151-
runs-on: ubuntu-latest
152-
steps:
153-
- uses: actions/checkout@main
154-
- name: Build HW Relays (IDF v5.3)
155-
uses: esphome/build-action@main
156-
with:
157-
yaml-file: ".test/esphome_idf53_hw_relays.yaml"
158-
version: beta
159-
160124
build_ard_hw_speaker:
161125
name: HW Speaker (Arduino)
162126
needs: build_ard_core
@@ -181,18 +145,6 @@ jobs:
181145
yaml-file: ".test/esphome_idf_hw_speaker.yaml"
182146
version: beta
183147

184-
build_idf53_hw_speaker:
185-
name: HW Speaker (IDF v5.3)
186-
needs: build_idf53_core
187-
runs-on: ubuntu-latest
188-
steps:
189-
- uses: actions/checkout@main
190-
- name: Build HW Speaker (IDF v5.3)
191-
uses: esphome/build-action@main
192-
with:
193-
yaml-file: ".test/esphome_idf53_hw_speaker.yaml"
194-
version: beta
195-
196148
build_ard_hw_vibration:
197149
name: HW Vibration (Arduino)
198150
needs: build_ard_core
@@ -217,18 +169,6 @@ jobs:
217169
yaml-file: ".test/esphome_idf_hw_vibration.yaml"
218170
version: beta
219171

220-
build_idf53_hw_vibration:
221-
name: HW Vibration (IDF v5.3)
222-
needs: build_idf53_core
223-
runs-on: ubuntu-latest
224-
steps:
225-
- uses: actions/checkout@main
226-
- name: Build HW Vibration (IDF v5.3)
227-
uses: esphome/build-action@main
228-
with:
229-
yaml-file: ".test/esphome_idf53_hw_vibration.yaml"
230-
version: beta
231-
232172
build_ard_ble_proxy:
233173
name: Bluetooth Proxy (Ard)
234174
needs: build_ard_basic
@@ -253,18 +193,6 @@ jobs:
253193
yaml-file: ".test/esphome_idf_ble_proxy.yaml"
254194
version: beta
255195

256-
build_idf53_ble_proxy:
257-
name: Bluetooth Proxy (IDF v5.3)
258-
needs: build_idf53_basic
259-
runs-on: ubuntu-latest
260-
steps:
261-
- uses: actions/checkout@main
262-
- name: Build BLE Proxy (IDF v5.3)
263-
uses: esphome/build-action@main
264-
with:
265-
yaml-file: ".test/esphome_idf53_ble_proxy.yaml"
266-
version: beta
267-
268196
build_ard_media_player:
269197
name: Media Player (Ard)
270198
needs:

.test/esphome_idf53_basic.yaml

Lines changed: 0 additions & 11 deletions
This file was deleted.

.test/esphome_idf53_ble_proxy.yaml

Lines changed: 0 additions & 13 deletions
This file was deleted.

.test/esphome_idf53_core.yaml

Lines changed: 0 additions & 5 deletions
This file was deleted.

.test/esphome_idf53_hw_relays.yaml

Lines changed: 0 additions & 6 deletions
This file was deleted.

.test/esphome_idf53_hw_speaker.yaml

Lines changed: 0 additions & 6 deletions
This file was deleted.

.test/esphome_idf53_hw_vibration.yaml

Lines changed: 0 additions & 6 deletions
This file was deleted.

ESPHome/TX-Ultimate-Easy-ESPHome_core_common.yaml

Lines changed: 11 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,8 @@ substitutions:
1717

1818
<<: !include ../versioning/VERSION_YAML
1919

20+
EVENT_NAME: esphome.tx_ultimate_easy
21+
2022
TX_MODEL_FORMAT_EU_TEXT: "EU (Square, T5-xC-86)"
2123
TX_MODEL_FORMAT_US_TEXT: "US (Rectangle, T5-xC-120)"
2224

@@ -116,13 +118,15 @@ script:
116118
parameters:
117119
type: string
118120
then:
119-
- homeassistant.event:
120-
event: esphome.tx_ultimate_easy
121-
data:
122-
device_name: !lambda return tx_device_name->state.c_str();
123-
firmware: ${version}
124-
domain: boot
125-
type: !lambda return type.c_str();
121+
- lambda: |-
122+
// Send event to Home Assistant
123+
esphome::api::CustomAPIDevice ha_event;
124+
ha_event.fire_homeassistant_event("${EVENT_NAME}", {
125+
{"device_name", id(tx_device_name).state.c_str()},
126+
{"firmware", "${version}"},
127+
{"domain", "boot"},
128+
{"type", type.c_str()}
129+
});
126130
127131
- id: boot_done
128132
mode: restart

ESPHome/TX-Ultimate-Easy-ESPHome_core_hw_buttons.yaml

Lines changed: 12 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -112,18 +112,19 @@ script:
112112
action: string
113113
count: uint8_t
114114
then:
115-
- homeassistant.event:
116-
event: esphome.tx_ultimate_easy
117-
data:
118-
device_name: !lambda return tx_device_name->state.c_str();
119-
firmware: ${version}
120-
domain: touch
121-
type: button
122-
action: !lambda return action.c_str();
123-
button_id: !lambda return button;
124-
count: !lambda return count;
125-
position: !lambda return id(button_press_position);
126115
- lambda: |-
116+
// Send event to Home Assistant
117+
esphome::api::CustomAPIDevice ha_event;
118+
ha_event.fire_homeassistant_event("${EVENT_NAME}", {
119+
{"device_name", id(tx_device_name).state.c_str()},
120+
{"firmware", "${version}"},
121+
{"domain", "touch"},
122+
{"type", "button"},
123+
{"action", action.c_str()},
124+
{"button_id", std::to_string(button)},
125+
{"count", std::to_string(count)},
126+
{"position", std::to_string(id(button_press_position))}
127+
});
127128
ESP_LOGI("core_hw_buttons", "Button %" PRIu8 " action: '%s'", button, action.c_str());
128129
if (action == "click") {
129130
switch (button) {

0 commit comments

Comments
 (0)