Skip to content

Commit

Permalink
Added Alarm Clock
Browse files Browse the repository at this point in the history
  • Loading branch information
eifinger committed Jul 20, 2018
1 parent 0f1d731 commit 0f4d0fd
Show file tree
Hide file tree
Showing 6 changed files with 41 additions and 6 deletions.
4 changes: 4 additions & 0 deletions binary_sensor.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
- platform: workday
name: workday
country: DE
province: HE
3 changes: 2 additions & 1 deletion configuration.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -124,4 +124,5 @@ image_processing: !include image_processing.yaml
android_ip_webcam: !include android_ip_webcam.yaml
history_graph: !include history_graph.yaml
input_select: !include input_select.yaml
input_datetime: !include input_datetime.yaml
input_datetime: !include input_datetime.yaml
binary_sensor: !include binary_sensor.yaml
8 changes: 6 additions & 2 deletions group.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -358,8 +358,12 @@ current_commit:
- sensor.current_commit_name
alarm:
name: Wecker
entities:
- input_datetime.alarm
entities:
- sensor.alarm_time
- input_number.alarmhour
- input_number.alarmminutes
- input_boolean.wakemeup
- input_boolean.alarmweekday
#################################################################
## Synonym
#################################################################
Expand Down
8 changes: 7 additions & 1 deletion input_boolean.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,4 +18,10 @@
room_based_light:
icon: mdi:lightbulb
heading_home_notifier_user_one:
icon: mdi:telegram
icon: mdi:telegram
alarmweekday:
name: Nur an Arbeitstagen
icon: mdi:calendar
wakemeup:
name: Weck mich
icon: mdi:alarm-check
14 changes: 13 additions & 1 deletion input_number.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,16 @@ leave_time_offset:
name: Extra Zeit
min: 0
max: 60
step: 1
step: 1
alarmhour:
name: Stunde
icon: mdi:timer
min: 0
max: 23
step: 1
alarmminutes:
name: Minute
icon: mdi:timer
min: 0
max: 59
step: 5
10 changes: 9 additions & 1 deletion sensor.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -428,4 +428,12 @@
value_template: "{{states.sensor.current_commit.state.split(' ',1)[0]}}"
current_commit_name:
friendly_name: Message
value_template: "{{states.sensor.current_commit.state.split(' ',1)[1]}}"
value_template: "{{states.sensor.current_commit.state.split(' ',1)[1]}}"
#################################################################
## Alarm Clock
#################################################################
- platform: template
sensors:
alarm_time:
friendly_name: 'Uhrzeit'
value_template: '{{ "%0.02d:%0.02d" | format(states("input_number.alarmhour") | int, states("input_number.alarmminutes") | int) }}'

0 comments on commit 0f4d0fd

Please sign in to comment.