BARRAUX Arthur
2 years ago
4 changed files with 5 additions and 5 deletions
@ -1,10 +1,10 @@ |
|||||
#!/bin/bash |
#!/bin/bash |
||||
|
|
||||
gpio mode $1 out |
gpio mode $1 out |
||||
|
let "out=`gpio read $1`" |
||||
if [ gpio read $1 = 1 ] |
if [ $out = 1 ] |
||||
then |
then |
||||
gpio write $1 0 |
gpio write $1 0 |
||||
else |
else |
||||
gpio write $1 1 |
gpio write $1 1 |
||||
fi |
fi |
||||
|
Loading…
Reference in new issue