3 Simple Ways to
Share What You Make

With Instructables you can share what you make with the world — and tap into an ever-growing community of creative experts.

PhotosPhotos

Share one or more photos of a project, recipe, or whatever you've made, quickly and easily.

Step by StepStep-By-Step

Share your step-by-step photos with text instructions of what you made so others can do it too!

VideoVideo

Share your how-to video. You'll need your embed code from a video site such as YouTube.

Home automation server with router

Step 3Configure the Router

Configure the Router
Install the Linux based OpenWRT firmware on the router.
The TL-WR741ND instructions can be found here:
http://wiki.openwrt.org/toh/tp-link/tl-wr741nd

 If you are stuck, start here: http://openwrt.org

After you have a working SSH connection you can proceed.

Because of the router (by default) runs the web admin page on the port 80, we need to add a secondary port to serve our custom web site. For that, we need to configure the uhttpd (web server application) configuration file.

Download WinSCP, to simply do this through SSH.
http://winscp.net/download/winscp429.zip

Set up a new connection:
Host name: normally 192.168.1.1 (by default)
Port: 22
User name: root
Password: what you gave after installation
File protocol: SCP

Find this file: /etc/config/uhttpd

Copy the following into it:

config 'uhttpd' 'secondary'
option 'listen_http' '81'
option 'home' '/HomeAutomation/www'
option 'cgi_prefix' '/cgi-bin'
option 'script_timeout' '60'
option 'network_timeout' '30'

And save it.
« Previous StepDownload PDFView All StepsNext Step »
6 comments
Mar 8, 2012. 10:37 PMedisonchung says:
I have downloaded WinSCP and type followed what you told :
" Download WinSCP, to simply do this through SSH.
http://winscp.net/download/winscp429.zip

Set up a new connection:
Host name: normally 192.168.1.1 (by default)
Port: 22
User name: root
Password: what you gave after installation
File protocol: SCP "

but what do you mean by " Password: what you gave after installation " ?
do u mean the installation of OpenWRT firmware on the router?
Mar 10, 2012. 9:00 AMedisonchung says:
Thx!!! But I come across another problem ><

After the first login, I changed my password then I login again using:

ssh root@192.168.1.1

I tried to install the web UI using Luci due to I'm using MacOS,
but when I tried to update opkg with the command :

opkg update

It failed(as shown in the image attached), it seems like it has no internet connection,
but in fact, I'm able to browse websites on my browser.
Hope you could help me with this and sorry for my ignorance.
Aug 21, 2011. 3:42 AMEddy Dean says:
looks great, but, how could this be done without WINSCP (as this does not work on my computer)?

Pro

Get More Out of Instructables

Already have an Account?

close

All Steps Viewing
View all steps of an Instructable on the same page when you're a Pro Member.

Upgrade to Pro today!
17
Followers
1
Author:mrx23dot