I\'m using a bash script to set up GPIO pins on a raspberry pi like so:
for i in 2 3 9 10 11 do echo $i > /sys/class/gpio/export sudo chmod 777 /sys/cl