You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+2-2Lines changed: 2 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -11,7 +11,7 @@ Track the battery type, when the battery was replaced, when a battery is low bas
11
11
12
12
A battery+ sensor provides useful attributes for easy use in dashboards, the standard battery can optionally be hidden.
13
13
14
-
Battery low, replaced and not reported are all via events and services, you have the option of creating your own automations for these or using the predefined ones in [community](https://andrew-codechimp.github.io/HA-Battery-Notes/community).
14
+
Battery low, replaced and not reported are all via events and actions, you have the option of creating your own automations for these or using the predefined ones in [community](https://andrew-codechimp.github.io/HA-Battery-Notes/community).
15
15
16
16
*Please :star: this repo if you find it useful*
17
17
*If you want to show your support please*
@@ -56,7 +56,7 @@ battery_notes:
56
56
57
57
## Docs
58
58
59
-
To get full use of the integration, read the documentation. It contains community quick starts as well as details on all the services, events and entities.
59
+
To get full use of the integration, read the documentation. It contains community quick starts as well as details on all the actions, events and entities.
|`device_id`|`yes`| The device id that you want to change the battery replaced date for. |
12
+
|`source_entity_id`|`yes`| The entity id that you want to change the battery replaced date for (only used for entity associated battery notes). |
13
+
|`datetime_replaced`|`yes`| The optional datetime that you want to set the battery replaced to, if omitted the current date/time will be used. |
14
+
15
+
You must specify either a device_id or entity_id, entity_id will be used in preference if both are specified. This allows the action to work with battery notes associated with both a device and also an individual entity, whether it is part of a device or not.
16
+
17
+
## battery_notes.check_battery_last_reported
18
+
19
+
For raising events for devices that haven't reported their battery level.
20
+
21
+
The action will raise a seperate [battery_not_reported](./events.md/#battery_not_reported) event for each device where its last reported date is older than the number of days specified.
22
+
23
+
You can use this action to schedule checks on batteries that is convenient to you, e.g. when you wake up, once a week etc.
24
+
25
+
See how to use this action in the [community contributions](./community.md)
|`days_last_reported`|`no`| The number of days since a device last reported its battery level. |
30
+
31
+
## battery_notes.check_battery_low
32
+
33
+
For raising events for devices that have a battery low status.
34
+
35
+
The action will raise a seperate [battery_threshold](./events.md/#battery_threshold) event for each device that have a battery low status.
36
+
37
+
You can use this action as a reminder that is convenient to you, e.g. when you wake up, once a week etc. The event has a boolean data item `reminder` to determine if the event was raised by this action or the device battery going to a low state.
38
+
39
+
See how to use this action in the [community contributions](./community.md)
Copy file name to clipboardExpand all lines: docs/community.md
+5-5Lines changed: 5 additions & 5 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -73,7 +73,7 @@ mode: queued
73
73
```
74
74
75
75
### Check Battery Low daily reminder
76
-
Call the check battery low service every day to raise events for those that are still low.
76
+
Call the check battery low action every day to raise events for those that are still low.
77
77
To be used in conjunction with a [Battery Low Notification](community.md/#battery-low-notification) or similar.
78
78
79
79
```yaml
@@ -146,7 +146,7 @@ mode: queued
146
146
```
147
147
148
148
### Check Battery Last Reported Daily
149
-
Call the check battery last reported service every day to raise events for those not reported in the last two days.
149
+
Call the check battery last reported action every day to raise events for those not reported in the last two days.
150
150
To be used in conjunction with a Battery Not Reported automation.
151
151
152
152
```yaml
@@ -164,7 +164,7 @@ mode: single
164
164
```
165
165
166
166
### Battery Not Reported
167
-
Respond to events raised by the check_battery_last_reported service and create notifications.
167
+
Respond to events raised by the check_battery_last_reported action and create notifications.
168
168
169
169
Note this cannot be run manually as it examines event triggers, use it with the [Check Battery Last Reported Daily](community.md/#check-battery-last-reported-daily) or similar.
170
170
@@ -193,7 +193,7 @@ max: 30
193
193
194
194
## Automation Tips
195
195
196
-
To call the battery replaced service from an entity trigger you will need the device_id, here's an easy way to get this
196
+
To call the battery replaced action from an entity trigger you will need the device_id, here's an easy way to get this
197
197
198
198
```yaml
199
199
action:
@@ -224,7 +224,7 @@ It is extended from the example Battery Replaced automation yaml above for those
224
224
225
225
This blueprint will allow notifications to be raised and/or custom actions to be performed when the battery not reported event is fired.
226
226
It is extended from the example Battery Not Reported automation yaml above for those who'd prefer an easy way to get started.
227
-
You must trigger the check_battery_not_reported service via an automation to raise events, see [Check Battery Last Reported Daily](community.md/#check-battery-last-reported-daily) above.
227
+
You must trigger the check_battery_not_reported action via an automation to raise events, see [Check Battery Last Reported Daily](community.md/#check-battery-last-reported-daily) above.
228
228
229
229
## Contributing
230
230
If you want to contribute then [fork the repository](https://github.com/andrew-codechimp/HA-Battery-Notes), edit this page which is in the docs folder and submit a pull request.
Copy file name to clipboardExpand all lines: docs/events.md
+3-3Lines changed: 3 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -20,7 +20,7 @@ You can use this to send notifications in your preferred method. An example aut
20
20
|`battery_quantity`|`int`| Battery quantity. |
21
21
|`battery_level`|`float`| Battery level % of the device. |
22
22
|`previous_battery_level`|`float`| Previous battery level % of the device. |
23
-
|`reminder`|`bool`| Returns true if the event was raised by a service call, false if it's from a device event. |
23
+
|`reminder`|`bool`| Returns true if the event was raised by an action, false if it's from a device event. |
24
24
25
25
### Automation Example
26
26
@@ -113,9 +113,9 @@ mode: queued
113
113
## Battery Not Reported
114
114
`battery_notes_battery_not_reported`
115
115
116
-
This is fired from the [check_battery_last_reported](./services.md/#check_battery_last_reported) service call for each device that has not reported its battery level for the number of days specified in the service call.
116
+
This is fired from the [check_battery_last_reported](./actions.md/#check_battery_last_reported) action call for each device that has not reported its battery level for the number of days specified in the action call.
117
117
118
-
The service can raise multiple events quickly so when using with an automation it's important to use the `mode: queued` to handle these.
118
+
The action can raise multiple events quickly so when using with an automation it's important to use the `mode: queued` to handle these.
Copy file name to clipboardExpand all lines: docs/index.md
+2-2Lines changed: 2 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -2,7 +2,7 @@
2
2
3
3
Integration to add battery notes to a device or entity, with automatic discovery via a growing [battery library](library.md) for devices.
4
4
Track the battery type, when the battery was replaced, when a battery is low based on device or global thresholds and also when a battery hasn't been reported for a while.
5
-
Battery low, replaced and not reported are all via events and services, you have the option of creating your own automations for these or using the predefined ones in [community](./community.md).
5
+
Battery low, replaced and not reported are all via events and actions, you have the option of creating your own automations for these or using the predefined ones in [community](./community.md).
6
6
7
7
*Please :star: this repo on [GitHub](https://github.com/andrew-codechimp/HA-Battery-Notes) if you find it useful*
8
8
*If you want to show your support please*
@@ -17,7 +17,7 @@ The integration will add additional diagnostic entities to your device.
0 commit comments