-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathshinwabms.yaml
108 lines (86 loc) · 2.01 KB
/
shinwabms.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
esphome:
name: shinwabms
includes:
- shinwabms.h
esp8266:
board: esp12e
logger:
level: DEBUG
web_server:
port: 80
api:
password: ""
ota:
password: ""
wifi:
networks:
- ssid: "Network"
password: "Password"
ap:
ssid: "Shinwabms Fallback Hotspot"
password: "Pa$sword"
captive_portal:
uart:
id: uart_bus
tx_pin: GPIO12
rx_pin: GPIO13
baud_rate: 9600
sensor:
- platform: custom
lambda: |-
auto ShinwaBMS = new ShinwaBMSuartComponent(id(uart_bus));
App.register_component(ShinwaBMS);
return {
ShinwaBMS->batteryVoltage,
ShinwaBMS->batteryCurrent,
ShinwaBMS->tempSensorMax,
ShinwaBMS->tempSensorAvg,
ShinwaBMS->tempSensorMin,
ShinwaBMS->batteryCellMax,
ShinwaBMS->batteryCellMin,
ShinwaBMS->batteryCellAvg,
ShinwaBMS->batteryCapacity
};
sensors:
- name: "Battery voltage"
unit_of_measurement: V
accuracy_decimals: 3
device_class: "voltage"
- name: "Battery current"
unit_of_measurement: A
accuracy_decimals: 2
device_class: "current"
- name: "Battery temperature Hi"
unit_of_measurement: °C
accuracy_decimals: 1
device_class: "temperature"
- name: "Battery temperature Avg"
unit_of_measurement: °C
accuracy_decimals: 1
device_class: "temperature"
- name: "Battery temperature Lo"
unit_of_measurement: °C
accuracy_decimals: 1
device_class: "temperature"
- name: "Battery cell voltage Hi"
unit_of_measurement: V
accuracy_decimals: 3
device_class: "voltage"
- name: "Battery cell voltage Lo"
unit_of_measurement: V
accuracy_decimals: 3
device_class: "voltage"
- name: "Battery cell voltage Avg"
unit_of_measurement: V
accuracy_decimals: 3
device_class: "voltage"
- name: "Battery capacity"
unit_of_measurement: Ah
accuracy_decimals: 1
device_class: "battery"
#- platform: adc
# pin: VCC
# name: "VCC Voltage"
#- platform: wifi_signal
# name: "WiFi Signal"
# update_interval: 60s