ein gpioset Kommando schaltet alle LED.
This commit is contained in:
@@ -17,9 +17,7 @@ function resetPins() {
|
||||
|
||||
|
||||
function setPins() {
|
||||
gpioset "${gpiochip}" ${pin_rot}=${state_rot}
|
||||
gpioset "${gpiochip}" ${pin_gelb}=${state_gelb}
|
||||
gpioset "${gpiochip}" ${pin_gruen}=${state_gruen}
|
||||
gpioset "${gpiochip}" ${pin_rot}=${state_rot} ${pin_gelb}=${state_gelb} ${pin_gruen}=${state_gruen}
|
||||
}
|
||||
|
||||
function ampel() {
|
||||
@@ -59,8 +57,8 @@ function ampel() {
|
||||
esac
|
||||
}
|
||||
|
||||
for i in 1 2 3 4; do
|
||||
ampel "${i}"
|
||||
for phase in 1 2 3 4 1; do
|
||||
ampel "${phase}"
|
||||
done
|
||||
|
||||
resetPins
|
||||
|
Reference in New Issue
Block a user