From b79071389517ed6d2360459283b9f41c503603a6 Mon Sep 17 00:00:00 2001 From: Max Campbell Date: Sun, 10 Feb 2019 01:52:18 +0100 Subject: jumbotron: fakta: added fakta bell --- roles/jumbotron/files/fakta-bell.sh | 31 +++++++++++++++++++++++++++++++ roles/jumbotron/files/fakta.service | 7 +++++++ roles/jumbotron/files/fakta.timer | 9 +++++++++ 3 files changed, 47 insertions(+) create mode 100644 roles/jumbotron/files/fakta-bell.sh create mode 100644 roles/jumbotron/files/fakta.service create mode 100644 roles/jumbotron/files/fakta.timer (limited to 'roles/jumbotron/files') diff --git a/roles/jumbotron/files/fakta-bell.sh b/roles/jumbotron/files/fakta-bell.sh new file mode 100644 index 0000000..1adf451 --- /dev/null +++ b/roles/jumbotron/files/fakta-bell.sh @@ -0,0 +1,31 @@ +#!/bin/sh + +for i in 1 2 3; do + gpio write 2 1 + sleep 0.01 + gpio write 2 0 + sleep 0.1 + gpio write 2 1 + sleep 0.01 + gpio write 2 0 + sleep 0.01 + gpio write 2 1 + sleep 0.01 + gpio write 2 1 + sleep 0.01 + gpio write 2 0 + sleep 0.01 + gpio write 2 1 + sleep 0.01 + gpio write 2 0 + sleep 0.1 + gpio write 2 1 + sleep 0.01 + gpio write 2 0 + sleep 0.01 + gpio write 2 1 + sleep 0.01 + gpio write 2 1 + sleep 0.01 + gpio write 2 0 +done diff --git a/roles/jumbotron/files/fakta.service b/roles/jumbotron/files/fakta.service new file mode 100644 index 0000000..7338d64 --- /dev/null +++ b/roles/jumbotron/files/fakta.service @@ -0,0 +1,7 @@ +[Unit] +Description=Ring fakta bell + +[Service] +Type=oneshot +User=jumbotron +ExecStart=/home/jumbotron/fakta-bell.sh diff --git a/roles/jumbotron/files/fakta.timer b/roles/jumbotron/files/fakta.timer new file mode 100644 index 0000000..1417a59 --- /dev/null +++ b/roles/jumbotron/files/fakta.timer @@ -0,0 +1,9 @@ +[Unit] +Description=Ring fakta bell + +[Timer] +OnCalendar=*-*-* 20:45:00 +Persistent=false + +[Install] +WantedBy=timers.target -- cgit v1.2.1