OpenWRt can read input from mouse attached, see instructions on H-wrt.com I connect a PIR motion detector board paralell to mouse button and get a simple digital input to router. In case of alarm the webcam takes picture. It took a while to figure out how to use output from cat /dev/input/event0 I continuously save mouse output to file. And then check if file is empty. I could not find easier method. In Ebay bought 5× Sensor Melder Module PIR Low Voltage Bewegungsmelder for 12 EUR. http://cgi.ebay.de/5-Sensor-Melder-Module-PIR-Low-Voltage-Bewegungsmelder-/270786796651?pt=DE_Haus_Garten_Heimwerker_Sicherheitstechnik&hash=item3f0c269c6b opkg install kmod-usb-serial-ftdi kmod-usb-hid cat /dev/input/event0 | hexdump cat /dev/input/event0 |hexdump cat /dev/hiddev0 |hexdump cat /proc/bus/input/devices ls /dev/input/ -l ######################################### while (true) do if ps -ef |grep /dev/input/event2 |grep -v grep; then echo "cat mouse runs" else echo "starting cat mouse" cat /dev/input/event2 > /www/test3 & fi if [ -s /www/test3 ]; then echo "alarm" #/www/webcam/webcamalarm.sh run here code that uploads picture cat /dev/null > /www/test3 else echo "quiet" fi done #########################################