If you own a webcam from this list than you can attach it to one of routers usb port and see in real time images from it, like babyroom, garage, courtyard...
This version is for mipsel devices like RT-N16, RT-N66U, RT-AC66U...
We need an usb-flash formatted EXT2 or an usb-hdd formated EXT3, will not work on FAT32 or NTFS.
1 - Install Optware from here
2 - Download and install Mjpg-Streamer
wget -c -O /tmp/mjpg-streamer_r63-2_mipsel.ipk https://bit.ly/2l0QOMD
ipkg install /tmp/mjpg-streamer_r63-2_mipsel.ipk
rm /opt/etc/init.d/K99webcam
wget -c -O /opt/etc/init.d/S99webcam https://bit.ly/2LFoJG6
chmod 755 /opt/etc/init.d/S99webcam
3 - Download and load UVC modules (if you have a different firmware version, use this guide to compile modules or ask someone on forums)
cd /
tar -zxf /opt/tmp/uvc_modules_2.6.22.19-378.50b2-mipsel.tar
wget -c -O /opt/etc/webcam/videomod.sh https://bit.ly/2xZTdR5
chmod a+rx /opt/etc/webcam/videomod.sh
/opt/etc/webcam/videomod.sh load
/opt/etc/init.d/S99webcam start
4 - Go to web browser and type: 192.168.1.1:9999/stream_simple.html default username admin and password admin
You can change username, password, resolution, fps...
/opt/etc/init.d/S99webcam stop
nano /opt/etc/init.d/S99webcam
Find this two lines and replace with desired login
• Save with CTRL-O / Enter / and exit with CTRL-X
5 - To start mjpg-streamer automatically on every router reboot we have to create S99webcam script
Add this lines
#!/bin/sh
/opt/etc/init.d/S99webcam start
• Save with CTRL-O / Enter / and exit with CTRL-X
6 - If you want to access the webcam from wan, we have to create another script that open the port 9999
Add this lines
#!/bin/sh
iptables -I INPUT -p tcp --destination-port 9999 -j ACCEPT
• Save with CTRL-O / Enter / and exit with CTRL-X
7 - Start mjpg server
8 - Now type your_wan_ip adress:9999/stream_simple.html in browser and should see your webcam
If you have dynamic ip, better set a dynamic dns 192.168.1.1/Advanced_ASUSDDNS_Content.asp
Tested successfully with Logitech C270 webcam
Video HERE...