Skip to content

Commit 8ad1331

Browse files
ferbuloustekmaven
andauthored
Girier-4gang-switch (#1252)
* Create index.md Added config for tuya ceiling light * Add pics for tuya ceiling light * Update index.md * Lint fix + frontmatter fix * girier 4 switch * photo devices * Fix linter issues * Fix frontmatter * Fix lint error --------- Co-authored-by: Ryan Hoffman <[email protected]>
1 parent 55d807a commit 8ad1331

File tree

5 files changed

+155
-0
lines changed

5 files changed

+155
-0
lines changed
249 KB
Loading
117 KB
Loading
280 KB
Loading
Lines changed: 155 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,155 @@
1+
---
2+
title: GIRIER Switch 4 Gang ZS-TYT1-SM-41W-W
3+
date-published: 2025-10-01
4+
type: switch
5+
standard: eu
6+
board: bk72xx
7+
difficulty: 3
8+
---
9+
10+
![alt text](front.jpg "4g_front")
11+
![alt text](back.jpg "4g_back")
12+
![alt text](box.jpg "4g_box")
13+
14+
- Has a BK7231N chip (CB3S)
15+
- Push button wall switch with button on each sides. 2 buttons one each gang which can toggled top or bottom with both
16+
wired to the same GPIO pin.
17+
18+
## GPIO Pinout
19+
20+
### 4-Gang Version
21+
22+
| Pin | Function |
23+
| ------ | ------------------ |
24+
| GPIO26 | Button 1 |
25+
| GPIO14 | Relay 1 |
26+
| GPIO24 | Button 2 |
27+
| GPIO9 | Relay 2 |
28+
| GPIO6 | Button 3 |
29+
| GPIO8 | Relay 3 |
30+
| GPI23 | Button 4 |
31+
| GPIO7 | Relay 4 |
32+
| GPI10 | Wifi LED indicator |
33+
34+
## PCB
35+
36+
![alt text](pcb.jpg "PCB")
37+
38+
## Basic Configuration (4 gang)
39+
40+
```yaml
41+
esphome:
42+
name: 4g-switch-girier
43+
44+
bk72xx:
45+
board: generic-bk7231n-qfn32-tuya
46+
47+
logger:
48+
49+
web_server:
50+
51+
captive_portal:
52+
53+
mdns:
54+
55+
api:
56+
57+
ota:
58+
platform: esphome
59+
60+
wifi:
61+
networks:
62+
- ssid: !secret wifi_ssid
63+
password: !secret wifi_password
64+
priority: 1
65+
- ssid: !secret wifi2_ssid
66+
password: !secret wifi2_password
67+
priority: 2
68+
output_power: 10dB
69+
70+
# Enable fallback hotspot in case wifi connection fails
71+
ap:
72+
password: !secret ap_password
73+
74+
75+
button:
76+
- platform: restart
77+
name: Restart
78+
79+
debug:
80+
update_interval: 30s
81+
82+
text_sensor:
83+
- platform: debug
84+
reset_reason:
85+
name: Reset Reason
86+
- platform: libretiny
87+
version:
88+
name: LibreTiny Version
89+
90+
sensor:
91+
- platform: uptime
92+
name: Uptime
93+
94+
binary_sensor:
95+
- platform: gpio
96+
id: binary_switch_1
97+
pin:
98+
number: P26
99+
inverted: true
100+
mode: INPUT_PULLUP
101+
on_press:
102+
then:
103+
- switch.toggle: switch_1
104+
- platform: gpio
105+
id: binary_switch_2
106+
pin:
107+
number: P24
108+
inverted: true
109+
mode: INPUT_PULLUP
110+
on_press:
111+
then:
112+
- switch.toggle: switch_2
113+
- platform: gpio
114+
id: binary_switch_3
115+
pin:
116+
number: P6
117+
inverted: true
118+
mode: INPUT_PULLUP
119+
on_press:
120+
then:
121+
- switch.toggle: switch_3
122+
- platform: gpio
123+
id: binary_switch_4
124+
pin:
125+
number: P23
126+
inverted: true
127+
mode: INPUT_PULLUP
128+
on_press:
129+
then:
130+
- switch.toggle: switch_4
131+
132+
switch:
133+
- platform: gpio
134+
id: switch_1
135+
name: Relay 1
136+
pin: P14
137+
- platform: gpio
138+
id: switch_2
139+
name: Relay 2
140+
pin: P9
141+
- platform: gpio
142+
id: switch_3
143+
name: Relay 3
144+
pin: P8
145+
- platform: gpio
146+
id: switch_4
147+
name: Relay 4
148+
pin: P7
149+
150+
status_led:
151+
pin:
152+
number: P10
153+
inverted: true
154+
155+
```
314 KB
Loading

0 commit comments

Comments
 (0)