-
Notifications
You must be signed in to change notification settings - Fork 1
/
esp32-cam-test1.yaml
163 lines (120 loc) · 3.19 KB
/
esp32-cam-test1.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
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
#------------------------------
#-- esp32-cam-test1.yaml
#-- Code pour tester rapidement une esp32-cam pour voir si elle fonctionne
#-- ATTENTION, c'est du code jetable, vu qu'il sera flashé sur plusieurs caméras qui auront donc le même mDNS !
#-- zf210810.2127
#--
# sources:
# https://esphome.io/components/esp32_camera.html
# https://fr.aliexpress.com/item/1005001322358029.html
# https://randomnerdtutorials.com/esp32-cam-ai-thinker-pinout/
# https://siytek.com/home-assistant-face-recognition/
esphome:
name: esp32-cam-test1
platform: ESP32
board: esp32cam
project:
name: "zf.esp32-cam-test1"
version: "1.0.0"
# Configuration WIFI
wifi:
# ssid: !secret wifi_ssid_apzuzu7
# password: !secret wifi_pass_apzuzu7
networks:
- ssid: !secret wifi_ssid_apzuzu7
- password: !secret wifi_pass_apzuzu7
- ssid: !secret wifi_ssid_apzuzu6
- password: !secret wifi_pass_apzuzu6
- ssid: !secret wifi_ssid_3G_zf
- password: !secret wifi_pass_3G_zf2
- ssid: !secret wifi_ssid_3G_zf2
- password: !secret wifi_pass_3G_zf2
- ssid: !secret wifi_ssid_3g_s7
- password: !secret wifi_pass_3g_s7
- ssid: !secret wifi_ssid_apzuzu6_EXT
- password: !secret wifi_pass_apzuzu6_EXT
# Enable fallback hotspot (captive portal) in case wifi connection fails
ap:
ssid: "esp32-cam-test1 Fallback Hotspot"
password: !secret ap_wifi_password
captive_portal:
# Enable logging
logger:
# level: VERBOSE
# Enable Home Assistant API
api:
password: !secret api_password
# Enable OTA
ota:
password: !secret ota_password
# WEB Server
web_server:
port: 80
# Définition des Switch's
switch:
- platform: restart
name: "esp32-cam-test1 Restart"
- platform: gpio
name: "esp32-cam-test1 LED"
inverted: True
id: led
pin: GPIO33
- platform: gpio
name: "esp32-cam-test1 LED FLASH"
# inverted: True
id: led_flash
pin: GPIO4
- platform: gpio
name: "esp32-cam-test1 cam power"
inverted: True
id: cam_power
pin: GPIO32
# Définition des sensors
sensor:
- platform: wifi_signal
name: "esp32-cam-test1 Signal Wi-Fi"
update_interval: 60s
- platform: uptime
name: "esp32-cam-test1 uptime"
update_interval: 60s
# Définition des text sensors
text_sensor:
- platform: version
name: "esp32-cam-test1 Version"
- platform: wifi_info
ip_address:
name: esp32-cam-test1 IP Address
id: wifi_ip
ssid:
name: esp32-cam-test1 Connected SSID
id: wifi_ssid
# Définition des binary sensors
binary_sensor:
- platform: status
name: "esp32-cam-test1 Status"
- platform: gpio
pin:
number: GPIO2
# number: GPIO14
mode: INPUT_PULLUP
inverted: True
name: "esp32-cam-test1 pir"
# Définition de la esp32-cam
esp32_camera:
name: esp32-cam-test1
external_clock:
pin: GPIO0
frequency: 20MHz
i2c_pins:
sda: GPIO26
scl: GPIO27
data_pins: [GPIO5, GPIO18, GPIO19, GPIO21, GPIO36, GPIO39, GPIO34, GPIO35]
vsync_pin: GPIO25
href_pin: GPIO23
pixel_clock_pin: GPIO22
power_down_pin: GPIO32
# Image settings
resolution: 640x480
max_framerate: 5 fps
vertical_flip: false
horizontal_mirror: false