write a little cgi. This can even be done with a shell where you can send commands to sysfs
You can do something like
#!/bin/sh #this will parse the sent parameters eval $(echo "$QUERY_STRING"|awk -F'&' '{for(i=1;i<=NF;i++){print $i}}') # this has to be set to whatever you want GPIO=22 echo $GPIO > /sys/class/gpio/export echo "out" /sys/class/gpio/gpio$GPIO/direction echo 1 /sys/class/gpio/gpio$GPIO/value cat << EOF Content-Type: text/html <!DOCTYPE html> <html> <body> <h1>pin on</h1> </body> </html> EOF
Finally, you must be sure that you have write permissions to sysfs and that the web server is configured to use the shell as the cgi interpreter
source share