-
-
Notifications
You must be signed in to change notification settings - Fork 9
/
switch-c3.yaml
68 lines (58 loc) · 1.27 KB
/
switch-c3.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
esphome:
name: lights_test
platformio_options:
board_build.flash_mode: dio
wifi:
ssid: !secret wifi_ssid
password: !secret wifi_password
output:
- platform: gpio
pin: GPIO3
id: simple_led
external_components:
source: github://rednblkx/HAP-ESPHome@main
refresh: 0s
esp32:
board: esp32-c3-devkitm-1
flash_size: 4MB
framework:
type: esp-idf
version: 5.2.1
platform_version: 6.7.0
sdkconfig_options:
CONFIG_COMPILER_OPTIMIZATION_SIZE: y
CONFIG_LWIP_MAX_SOCKETS: "16"
CONFIG_MBEDTLS_HKDF_C: y
homekit_base:
setup_code: '159-35-728'
homekit:
switch:
- id: some_switch
meta:
manufacturer: "AMICI&CO"
model: "TRANSMUTO"
serial_number: "42424242"
fw_rev: "0.16.2"
switch:
- platform: template
id: some_switch
name: "Template Switch"
restore_mode: RESTORE_DEFAULT_OFF
lambda: |-
if (id(desk_light).current_values.get_state()) {
return true;
} else {
return false;
}
turn_on_action:
- light.turn_on: desk_light
turn_off_action:
- light.turn_off: desk_light
light:
- platform: binary
id: desk_light
name: "Desk Lamp"
output: simple_led
restore_mode: RESTORE_DEFAULT_OFF
logger:
level: DEBUG