From f2f780daf24fb025232fc8bff592b414498ef042 Mon Sep 17 00:00:00 2001 From: Diego Roversi Date: Thu, 1 Jan 1970 01:20:14 +0100 Subject: added ring.sh script, to ring the bells --- ring/ring.sh | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100755 ring/ring.sh diff --git a/ring/ring.sh b/ring/ring.sh new file mode 100755 index 0000000..ab3d192 --- /dev/null +++ b/ring/ring.sh @@ -0,0 +1,17 @@ +# PB4 -> gpio2 - pin 13 +# PB10 -> gpio2 - pin 15 +echo 2 > /sys/class/gpio/export +echo 3 > /sys/class/gpio/export +echo out > /sys/class/gpio/gpio2_pb4/direction +echo out > /sys/class/gpio/gpio3_pb10/direction + +for i in $(seq 1 10); do + echo 1 > /sys/class/gpio/gpio2_pb4/value + sleep 0.001 + echo 1 > /sys/class/gpio/gpio3_pb10/value + sleep 0.001 + echo 0 > /sys/class/gpio/gpio2_pb4/value + sleep 0.001 + echo 0 > /sys/class/gpio/gpio3_pb10/value + sleep 0.001 +done -- cgit v1.2.3