hardware / software / social hacks

Aug 4, 2007

f.i.c.s. - Fonera Internet Controlled Switch




I got my first FON router for free a couple of months ago.
First thing i did was flash dd-wrt firmware on it. Since FONera router has gpio pins i decided to use one of those pins to control AC loads or turn a switch ON/OFF remotely.
There's a similar/better way of controlling AC loads - check out dd-wrt wiki. However, i only had one NPN transistor some resistors and leds.
So i decided to build a small circuit that will turn a switch ON and OFF thru the Router's Web Interface. Now i can turn anything ON/OFF from anywhere in the world.....



PARTS NEEDED

-NPN transistor (2N3055) - $2.29
-One 10k Resistor - 99 cents
-One 1k Resistor - 99 cents
-1 LED

SCHEMATICS

after burning down the transistor and receiving death threads from other users i decided to build a new/SAFER circuit using a solid state relay :) .... Thanks for the feedback guys/girls.
Stay tuned. (this time i wont 'Drink and Solder')







SOFTWARE


- Log on to your router (ex: http:192.168.1.1)
- Go to Administration > Management
- JFFS2 Enable




- Go to 'Services'
- Enable SSH




- Go to Administration > Commands
- type:

echo 1 > /proc/gpio/3_dir
rmdir /tmp/www; ln -s /jffs/www /tmp

- Click 'Save Startup'




- Now log on to your router using ssh

ssh root@192.168.1.1

-then type:

cd /jffs
mkdir www
cd www
wget http://cryptonoid.googlepages.com/index.sh
wget http://cryptonoid.googlepages.com/on.sh
wget http://cryptonoid.googlepages.com/off.sh
wget http://cryptonoid.googlepages.com/blink.sh
chmod +x on.sh off.sh index.sh blink.sh


-then go to http://192.168.1.1/user/index.sh

-Now you can control the switch simply by clickin ON or OFF from your favorite browser (i use my cell phone to activate the switch thru the web interface). Since my linux kung-fu skills are not developed yet, it took me some time to get familiar with .sh scripts.


Image of the web interface.




On the video above you can see circuit and the router. the circuit is connected to a multimeter to detect short circuit. You can hear a *beep* when i turn the switch on from the web interface. Also, when i run blink.sh from the web interface you can hear 10 *beeps* (the switch turns on/off 10 times). The red LED indicated the status of the switch (on or off). to display the status of the switch on the web interface i wrote a small loop inside each .sh script.


USES

-Hook it up to your car's door switch and open your car with your wifi enabled cellphone.

-If you have Remote Start System installed on your car you can hook up the remote control of the system to your f.i.c.s. (fonera internet controlled switch) and turn ON/OFF your car from the internet

-Open your house/garage door.

-Turn ON/OFF your POOL PUMP.

-Restart additional routers with f.i.c.s.

RESOURCES

- DD-WRT
- OpenWrt
- Steve's Bourne / Bash shell scripting tutorial


NOTICE: I am not associated with the company/product(s) mentioned in this post. BEFORE YOU TRY THIS YOU MUST KNOW WHAT YOU'RE DOING....if you get electrocuted, executed, kidnapped, burn your house down dont blame it on me....

Enjoy :)








since im not very good in programming shell scripts can someone write a Shell script where the user will be able to schedule the f.i.c.s. to go ON/OFF at certain times thru the web interface.

34 comments:

SpiralBrain said...

Just to let you know, this isnt the correct way to use the 2N3055, its not ment for AC loads. this circuit isnt peoperly isolated for AC loads so it can brick your fonera!!!!
using a relay is safeer.

cheers!!
Spiralbrain

Anonymous said...

this circuit is totally stupid (for AC)… you have 110V AC on the foneras ground !!!
It will either kill your devices connected to the fonera or yourself if you touch it.

switching AC with a transistor is no good idea either…

Even for DC there are ways to do it better. electronic solid state relais for example

SoulFireX97 said...

I've been waiting for thid mod for awhile now, but like other have said it would be safer running this with a ssr.

My question now is can you run four independent switch controls with the GPIO and software? The GPIO does have 4 pins with SW1 control, How would that work with the software and the SSH comand lines?

cryptonoid said...

maybe this circuit will help you
to control four OUTPUTS



http://www.rentron.com/PIC16F84.htm

seo said...

Web design is a process of conceptualization, planning, modeling, and execution of electronic media delivery via Internet in the form of Markup language suitable for interpretation by Web browser and display as Graphical user interface (GUI). Design Web Format (DWF) is an open, secure file format developed by Auto desk for the efficient distribution and communication of rich Web design data to anyone who needs to view, review, or print design files. Because DWF files are highly compressed, they are smaller and faster to transmit than Web design files, without the overhead associated with complex CAD drawings (or the management of external links and dependencies). With DWF functionality, publishers of Web design data can limit the specific Web design data and plot styles to only what they want recipients to see and can publish multi sheet drawing sets from multiple auto cad drawings in a single DWF file. They can also publish 3D models from most Auto desk Web design applications. Search engine optimization (SEO) is the process of improving the volume and quality of traffic to a web site from search engines via ;natural; (;organic; or algorithmic) search results. Usually, the earlier a site is presented in the search results, or the higher it ;ranks;, the more searchers will visit that site. SEO can also target different kinds of search, including image search, local search, and industry-specific vertical search engines.

Pierre said...

If anyone has a clue why I get a index.sh file download proposition instead of the fics black control page when I go to http://router_ip/user/index.sh .....
cheers ...

migraine treatments said...

black mold exposureblack mold symptoms of exposurewrought iron garden gatesiron garden gates find them herefine thin hair hairstylessearch hair styles for fine thin hairnight vision binocularsbuy night vision binocularslipitor reactionslipitor allergic reactionsluxury beach resort in the philippines

afordable beach resorts in the philippineshomeopathy for eczema.baby eczema.save big with great mineral makeup bargainsmineral makeup wholesalersprodam iphone Apple prodam iphone prahacect iphone manualmanual for P 168 iphonefero 52 binocularsnight vision Fero 52 binocularsThe best night vision binoculars here

night vision binoculars bargainsfree photo albums computer programsfree software to make photo albumsfree tax formsprintable tax forms for free craftmatic air bedcraftmatic air bed adjustable info hereboyd air bedboyd night air bed lowest pricefind air beds in wisconsinbest air beds in wisconsincloud air beds

best cloud inflatable air bedssealy air beds portableportables air bedsrv luggage racksaluminum made rv luggage racksair bed raisedbest form raised air bedsaircraft support equipmentsbest support equipments for aircraftsbed air informercialsbest informercials bed airmattress sized air beds

bestair bed mattress antique doorknobsantique doorknob identification tipsdvd player troubleshootingtroubleshooting with the dvd playerflat panel television lcd vs plasmaflat panel lcd television versus plasma pic the bestThe causes of economic recessionwhat are the causes of economic recessionadjustable bed air foam The best bed air foam

hoof prints antique equestrian printsantique hoof prints equestrian printsBuy air bedadjustablebuy the best adjustable air bedsair beds canadian storesCanadian stores for air beds

migraine causemigraine treatments floridaflorida headache clinicdrying dessicantair drying dessicantdessicant air dryerpediatric asthmaasthma specialistasthma children specialistcarpet cleaning dallas txcarpet cleaners dallascarpet cleaning dallas

vero beach vacationvero beach vacationsbeach vacation homes veroms beach vacationsms beach vacationms beach condosmaui beach vacationmaui beach vacationsmaui beach clubbeach vacationsyour beach vacationscheap beach vacations

bob hairstylebob haircutsbob layeredpob hairstylebobbedclassic bobCare for Curly HairTips for Curly Haircurly hair12r 22.5 best pricetires truck bustires 12r 22.5

washington new housenew house houstonnew house san antonionew house venturanew houston house houston house txstains removal dyestains removal clothesstains removalteeth whiteningteeth whiteningbright teeth

ecommercewebmaster12 said...

As a top-rated company in the world of ecommerce, Infyecommercesolution has carved out a niche for itself and with the ecommerce solution provided by the company receiving accolades from clients all over the world, it has, in the true sense of the word, grown up to be a top-notch outsourcing software development company. For details on all the services provided by the company, visit http://www.infyecommercesolution.com.

Anonymous said...

Web Art Sense a web design company is here for a purpose to make art and design of your imagination alive and real on the web platform. After several months of hunting of the best talent and struggling for the name of their design company they finally reached a vertical which engages their vision of togetherness. The best talented people in web designs have joined hands to compete and provide innovative, unique concepts to users/clients all across the globe. Web Art Sense is not any design company; they take real care of having your brands be presented that invokes your revelation to others who see it.

Web Art Sense has their sales offices in London, New Jersey and New Delhi are heading towards marketing themselves to main continents of Europe, Australia and America. Web art sense already has ground foundation and is providing web based design development and SEO Services in countries like USA, UK, Australia and Italy. Web Art Sense has been growing above hundred percent every financial year since its foundation.
Web Design Company

Web Art Sense a leading web design company, affordable web design, web development, ecommerce, XHTML Services. Web Design Company offers a complete collection of web design solutions for business. Web Art Sense team of professionals with proven knowledge in the field of web design & development are skilled of providing high quality, e commerce websites, development and website redesign & maintenance solutions.

suparna said...

really great post.
Web Developer  |   Web Design

Aparna said...

Really nice post, thanks. Website Hosting | windows hosting

web said...

Your website is fine for all its distinctive features. However, I have found http://www.infysolutions.com to be another content enriched website containing details on Outsourcing software development,ecommerce solutions and software development.
Thanks.

Amrit Ray said...

Are you saying you bought this router or are you designing it yourself? The router is definitely super cool. Web Designer Web Hosting

Flerkin McBlerkin said...

Wow I think that designer really loves your site!
Langara Island Fishing

retouching said...

Thanks for sharing this information!!

Eric said...

Hi! Your blog is simply super. you have create a differentiate. more templates easy to download Thanks for the sharing this website. it is very useful professional knowledge.

Anonymous said...

[B]NZBsRus.com[/B]
Skip Sluggish Downloads Using NZB Files You Can Instantly Find Movies, Games, MP3s, Applications & Download Them at Flying Speeds

[URL=http://www.nzbsrus.com][B]Newsgroup Search[/B][/URL]

Anonymous said...

[url=http://www.facebook.com/pages/weathercom/298713874092l]www.weather.com[/url]

Send Flowers to USA said...

I suggest this site to my friends so it could be useful & informative for them also. Great effort.

tenax_technologies said...

Thanks for sharing.

Tenax Technologies is a Belarussian software company delivering complex web solutions. We provide comprehensive Java development of complex internet systems.

Mobile Game Development said...

Thanks for the nice information. I am sure, I will tweet this to my twitter account. This will help a lot of users. Windows Phone 7 Application Development Custom Software Development Mobile App Development iPhone Application Development iPhone Game Development

Anonymous said...

Green Web Hostng

Anonymous said...

Hi, I just can't create ANY directory by SSH in my fonera (fonera 2200 dd-wrt). I've tried with putty (mkdir WWW), with WinSCP, but it's impossible. Any ideas?

javi_el_largo (@) yahoo (.) es

Superheroes said...

Great man. Circuit is the main part for all the electronic devices.

reliance data card in chennai

Movies and Concepts Handled in the Movies said...

Such a wonderful post. Very interesting. Keep Going.
Mesothelioma claims

web designing said...

good job !

Infobanc said...

I have been meaning to read this and just never got a chance. Its an issue that Im very interested in, I just started reading and Im glad I did. Youre a wonderful blogger, 1 of the most effective that Ive seen. This weblog undoubtedly has some facts on topic that I just wasnt aware of. Thanks for bringing this stuff to light.

canada exporters
b2b trade leads
suppliers directory
indian trade portal
Indian buyers
Indian tenders
trade fairs
indian distributer

Hotel in Ranchi said...

Thanks for that post! We are glad to find someone who puts a lot of thought into their blog instead of just throwing up a bunch of junk!

Best Hotel in Ranchi
Budget hotels in Ranchi
Cheap Hotel Rooms in Ranchi
Economy hotels in Ranchi
Luxury Hotels in Ranchi
Restaurant in Ranchi
Bar in Ranchi
Best Banquet in Ranchi

Anonymous said...

I аm tгuly delіghteԁ to read this web site posts ωhіch carrіes
plеnty of valuable ԁatа, thanks foг proνіdіng theѕе κinԁs οf data.



Look intο mу blog post; verdopple deine dates download free

Anonymous said...

I bеlіevе thіs is οnе of thе mοst signifiсant infο for me.
And i аm glаd reading youг агticle.
Βut wanna ѕtatemеnt оn few
general things, The webѕite taste is great, the
artiсles is in reality eхcеllent :
D. Еxcellent process, сheers

My page: ohms law

Anonymous said...

constantly і used to read smaller articlеs οr rеviews whiсh also clear theіr motive, and that iѕ also hаppening with this
paragraph which I am reading at this time.

Hеre is my homepage ... http://azfreelyrics.com

Anonymous said...

This web ѕite certainlу has all the
іnformatiοn Ι wаnted concеrning thiѕ subϳеct аnd dіdn't know who to ask.

Here is my web-site :: HäMorrhoiden

Anonymous said...

What's up, after reading this awesome paragraph i am as well happy to share my know-how here with mates.

Here is my webpage; haemorrhoidenet.De

websenor infotech said...

WebSenor InfoTech deliver Website & software solutions to achieve challenging business objectives.We execute the most complex and ambitious projects and ensure high solution maintainability, performance, scalability and system integration.
sir our team members are the always ready for your help. any technical support visit our site- http://appsenor.com/ , http://www.websenor.com/ and contact us . 9950834560
thank you.

Blog Archive