forked from docteurzoidberg/my-esphome
-
Notifications
You must be signed in to change notification settings - Fork 0
/
testespcam.yaml
executable file
·91 lines (78 loc) · 1.86 KB
/
testespcam.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
substitutions:
devicename: "testespcam"
friendly_name: "test espcam"
esphome:
name: $devicename
build_path: build/$devicename
platform: ESP32
board: esp-wrover-kit
wifi: !include "common/wifi.yaml"
logger:
captive_portal:
api:
ota:
binary_sensor:
- platform: gpio
pin: GPIO19
name: "$friendly_name PIR"
device_class: "motion"
id: "motion"
- platform: gpio
pin:
number: GPIO15
mode: INPUT_PULLUP
inverted: True
name: "$friendly_name Button"
id: button
- platform: status
name: "$friendly_name Status"
switch:
- platform: restart
name: "$friendly_name Restart"
sensor:
- platform: wifi_signal
name: "$friendly_name WiFi Signal"
update_interval: 10s
- platform: "uptime"
name: "$friendly_name Uptime"
font:
- file: "fonts/Roboto-Regular.ttf"
id: tnr1
size: 20
- file: "fonts/Roboto-Regular.ttf"
id: tnr2
size: 24
time:
- platform: homeassistant
id: homeassistant_time
display:
- platform: ssd1306_i2c
model: "SSD1306 128x64"
address: 0x3C
rotation: 180
lambda: |-
it.strftime(64, 0, id(tnr1), TextAlign::TOP_CENTER,"%m-%d-%Y", id(homeassistant_time).now());
it.strftime(64, 64, id(tnr2), TextAlign::BASELINE_CENTER, "%I:%M:%S%p", id(homeassistant_time).now());
esp32_camera:
name: $friendly_name
external_clock:
pin: GPIO4
i2c_pins:
sda: GPIO18
scl: GPIO23
#Wrong pinout, as labeled in the picture
#data_pins: [GPIO34, GPIO13, GPIO14, GPIO35, GPIO39, GPIO12, GPIO15, GPIO36]
#Good pinout, as labeled on silkscreen
data_pins: [GPIO34, GPIO13, GPIO14, GPIO35, GPIO39, GPIO38, GPIO37, GPIO36]
vsync_pin: GPIO5
href_pin: GPIO27
pixel_clock_pin: GPIO25
resolution: 640X480
jpeg_quality: 12
vertical_flip: true
horizontal_mirror: true
idle_framerate: 0.1fps
max_framerate: 7fps
i2c:
sda: GPIO21
scl: GPIO22