Introduction: Cheap and Easy Arduino Wi-Fi Hack

Picture of Cheap and Easy Arduino Wi-Fi Hack

I was sitting around and messing with my Arduino UNO and an ENC28J60 Ethernet module, and thought to myself it would be cool to have a Wi-Fi shield, when I realized I did not have to buy a shield as I had the components and all I had to do was hook them up together ( pure intense light bulb moment!!).
When I travel carry a small Wi-Fi router to use in hotel rooms (TP-Link TL-WR702N) which is a 150Mbps access point, I remembered that it could be configured as a client among other modes it has.
I reconfigured it as a client and assigned an IP number checked I could access it over my home Wi-Fi network , by plugging into a desktop’s LAN port, also checked that it had  access to the internet .

I then plugged the TP-Link TL-WR702N into the ENC28J60 Ethernet module and the UNO and ran the etherShield web switch example which came with the etherShield library and it worked. The router runs of 5 volts via a mini USB connector which works out well with the Arduino.

I live in mainland China and this whole experiment cost me about US$20 for the ENC28J60 Ethernet module and the wireless router, I checked up on the local prices for an Arduino Wi-Fi shield and it was between US$45 to US$80.
Once I figure out what my final project will be I might splurge and buy a real Wi-Fi shield for it, till then this serves my purpose albeit a bit messy with the wires.

Any and all feedback is appreciated, I will try and answer any questions if any.


janisalnis (author)2012-06-10

Like your idea very much.
I tried WR703N and Arduino with USB, saving ethernet shield.
OpenWRT WiFi client config had to do in text editor without webinterface.

jasonduiella (author)2016-05-16

So does this system create a wifi network without connecting to a laptop or wall? I'm trying to get some wifi in my car and if I power this setup through a portable battery charger pack, would I be able to connect my phone to the wifi it creates?

JonasLue. (author)jasonduiella2016-12-04

Well, it creates an access point to where you can connect with your phone or tablet, but you won't have internet access, thus needing another device (like a laptop with a 3G card) to give it an internet connection

MadamE2 (author)2016-05-17

this is a very Informative post, I am Glad to read this.

majdi210187 (author)2014-11-15

It is possible to use Mr3020 with broadband 3g modem to control arduino?

hawth33 (author)2013-08-26

I found this and am trying a wireless setup using the arduino ethernet and the same router. Can you point me to the "etherShield web switch example which came with the etherShield library"? I cannot seem to find it. I guess i am just confused on how to get the arduino to actually connect to a wifi connection once the router is in client mode.

ddoss (author)hawth332013-08-31

Hi, If you look in the examples folder on the IDE ( once you have installed the library ) it's called webserverpde .
Change the ip address according to your wifi router static uint8_t myip[4] = {192,168,0,15};
static char baseurl[ ]="";

ddoss (author)ddoss2013-08-31

I have mentioned below about an excellent tutorial for the ENC28J60 in 8 parts

IDE2 (author)2013-03-25

Hi ddoss

Thanks for posting this project.

I’m using Arduino Uno R3, Ethernet shield and TP-Link TL-MR3020 (switch at WISP mode). I’m having trouble connecting.

There are 3 types of connections: PPPoE, Dynamic IP and Static IP. Which one did you use? How do you figure out what IP address to use in the Arduino pde program? I’m using the Arduino 23 IDE.

Thanks in advance.

iamseer (author)2012-04-29

ENC28J60 is totally unnecessary and it is wasting Arduino's computation power. Just connect your power supply to router and connect USB from WR702 to Arduino will establish serial connection. OpenWRT is the best choice to deal with internet access issues.

rajusaleem (author)iamseer2012-11-13

Dear @iamseer & @ddoss, can you plz tell how to connect arduino UNO to wireless router directly wothout ethernet shield?.i can not find any USB compatable port in router. I have already Any link or suggestion? Sorry i am new to wifi field. thanks

ddoss (author)rajusaleem2012-11-13

@rajusaleem , Please check Janisalnis's instructables ( ) he has had luck with the Arduino and serial connections. I do not have any experience with the router you have and checking the link seems dlink stopped support for it in 2008 , as suggested before invest in an Ethernet shield for the Arduino and save yourself a lot of trouble . best of luck on your quest .

rajusaleem (author)ddoss2012-11-14

thanks ddoss .. i have already ENC28J60 shield and am working on. I just asked for more info., may be if you know about that.. Well i also found an other ethernet shield i think it could also serve this purpose and more than this..

ddoss (author)rajusaleem2012-11-14

Hey Man, If you reread my replies I have given you links to information sources , there are differences in both shields such as the price for starters, the W5100 has a full TCP/IP stack and interface , but the ENC2860J does not and needs you to implement a TCP/IP stack in the software , search the Arduino forums and google it there is a lot of useful information there to help you get your project up and running with either of the Ethernet shields.

ddoss (author)iamseer2012-06-20

I did reply but for reasons unknown it's down at the bottom of this thread.
Apr 30, 2012. 1:28 AM

Point noted , I would have if I could have , the WR702 uses the AR9331 chipset. which is not supported by OpenWrt for one , secondly the onboard USB is only available as the power port for the router.
I will be cracking open the case in the near future to see if I could access the serial port connections

sudopeople (author)iamseer2012-06-18

@iamseer, while your tone is annoying, you're almost correct. For anyone else interested in saving a couple extra bones, check out the tl-wr703n (this instructable uses the the attention *702* vs *703* !!!!)

The cheapest "wifi shield" hack I've found thus far is a Neewer 150M mini Pocket Wireless Router ($17) + the mentioned ENC28J60 (~$6) for an end cost of ~$23. The 703n is closer to $30.

See the OpenWRT wiki page for the 702 to see why it's not supported.

Elac. (author)2012-10-31

Really cool instructable.
One question, I have a WR703 on the way with DDWRT firmware pre-installed.
Do I have to flash OpenWRT or will DDWRT work?

ddoss (author)Elac.2012-11-01

Thanks, it should not matter which firmware you have , as long as your device can be configured to a client mode via the firmware ui .
I have no experience using either DDWRT or OpenWRT on the WR703/702

Elac. (author)ddoss2012-11-02

Ok, client mode is an option in DDWRT.
Thanks for the reply ddoss.

rajusaleem (author)2012-10-16

nice idea.. :) I like it. but can you please tell me will this approach work properly for controlling LEDs/Appliances through wifi from Android Mobile..???

ddoss (author)rajusaleem2012-10-17

Hi , Yes you can control LED's and Appliances with Wifi /Arduino and an Android device.
Here is a neat starting point for the Arduino and ENC28J60 Ethernet module , well written tutorials in 8 parts , the control is via a webpage from any web enabled device

Also Janisalnis ( ) has written some instructables on home automation
You should look into these.

rajusaleem (author)ddoss2012-10-18

thank you so much for reply... Actually i don't want to use internet connection or GPRS from mobile.. i.e i want to create LAN network from these components that will be free of daily charges to the end users...

More can you plz guide me that how can i use the Wifi functionality of Bluetooth mate gold
to control LEDs through wifi??... can it be possible ?? i have already used this Bluetooth mate gold to control LED's via bluetooth.. :)

ddoss (author)rajusaleem2012-10-19

Sorry buddy you cannot use your bluetooth dongle as a wifi device.

rajusaleem (author)ddoss2012-10-22

Thanks sir but the links you provided are little confusing to me. i want to actually find alternate for

ddoss (author)rajusaleem2012-10-22

Hi Man,
As much as I would like to help you , I'd suggest you first get yourself an Ethernet module/shield wired or wireless the follow the tutorial on the first link I gave you
( ) the tutorial is written in a easy to understand manner , follow the examples there understand each of the tutorial's before jumping to the next., if there is something that is confusing in the new tutorial go back to the previous one's and re-read them , don't copy and paste the code from the page's ,manually type it into the IDE .
If you still have a problem search the web and on the Arduino Forum
Having said all the above I hope you have understood the basics of an Arduino.

sudopeople (author)2012-06-26

FYI, for those trying to get the ENC28J60 to work with a simple(r) library, check out EtherCard on github. It's much more straightforward than the nuelectronics library and it's actively supported - it works with Arduino 1.0+

...another note. I used the Neewer 150 Mini Pocket WiFi router in reverse mode (WiFi switch on the device) and was able to get the Arduino serving a simple web page after a lot of fail trying to make it connect to google.

It's pretty damn convoluted but it works.

I don't recommend this project for beginners...I support and develop the full LAMP stack for a living and I've got a gnarly headache from this undertaking.

amaze1 (author)sudopeople2012-10-18

As already requested to ddoss I would like use this mini wifi router:

It seems identical to the neewer one:

Have you used the latter ? Why it should be so difficult ?

As far as I understand you have to configure the device as client so it gives wireless capability to the ethernet shield (or module, either ENC28J60 or W5100).

Maybe am I too optimistic ?

amaze1 (author)2012-10-12

Hi ddoss
Nice hack !
Do you think ANY wifi router configurable as client will do the job ?
This one for example:

ddoss (author)amaze12012-10-15

Hi , I am pretty sure that if configurable as a client ( like a wifi card for laptop would act) it would work.
I looked at your example link and the data there does not suggest it could be a client.

amaze1 (author)ddoss2012-10-16

On the photo you can see a slide switch on the side with the "RT-Client-AP" indications:
but indeed I'm not so skilled on Wifi to understand ...

ddoss (author)amaze12012-10-17

Hi, Theoretically the switch is labeled to allow the module to act as either one of these modes I can't be sure about this in situation, did a quick google on the model and could not find any data sheets , sorry man that's the best I can help you with ....
Noticed that on ebay they are selling the TP-link TL-WR702N on average for about 22$ .

wilsonjc (author)2012-07-10

As i understand it theTP-Link TL-WR702N has a serial port inside that if set up right could be connected to the Arduino. another way to connect it to the TL-WR702N would be to install drivers for a serial usb dongle on the router and connect the Arduino to that. that should be cheaper and wont require any Ethernet stack etc software on tha ardurino.


janisalnis (author)2012-07-09

Your approach using Arduino webserver is more reliable compared to serial communication. I experience problem that after some days of continuous operation Arduino serial port communication to router simply crashes.

diy_bloke (author)2012-05-19

interesting article.

Could not help wondering though: why you carry a router to hotels? To use more than one appliance in case there is only LAN and no WLAN?

ddoss (author)diy_bloke2012-05-20

I use multiple devices, a laptop and smartphone. WLAN is available in larger hotels in cities and not in some of the little towns I have to visit.

diy_bloke (author)ddoss2012-05-20

Thank you for settling my curiosity

Computothought (author)2012-04-27

Cool. You can do the same thing with say a computer or a laptop that does not have wireless.

ddoss (author)Computothought2012-04-30

You sure can. you could also have a couple hooked up as repeaters at blind spots around your place.

IOwnCalculus (author)2012-04-30

How did you wire up your ENC28J60 to your Arduino? I've got that exact same shield and I can't get it to do anything more than light up a link light.

ddoss (author)IOwnCalculus2012-04-30

I have attached a jpeg of my wiring which works with the examples which come with the etherShield library

IOwnCalculus (author)ddoss2012-04-30

Thank you so much, I think I had most of those but wasn't sure on whether or not RST or INT needed to be hooked up. Trying to use it to make a box that will ping an address, and if the ping fails, reboot my modem.

ddoss (author)2012-04-30

Point noted , I would have if I could have , the WR702 uses the AR9331 chipset. which is not supported by OpenWrt for one , secondly the onboard USB is only available as the power port for the router.
I will be cracking open the case in the near future to see if I could access the serial port connections .

About This Instructable




Bio: I am a hippie at heart , just got back into electronics after about 30 years away from it, by playing with an Arduino .
More by ddoss:Cheap and Easy Arduino Wi-Fi Hack
Add instructable to: