arduino and wi fi

Control Boards, Controllers, Tethers, Ect.
Post Reply
m_g
Posts: 51
Joined: May 17th, 2012, 7:14 pm

arduino and wi fi

Post by m_g »

Hi
I am wondering if anyone with arduino/xbee skills knows whether it is possible for arduino to receive a 2.4 GHz WiFi signal, trasmit it the data along a cat 5 cable, then rebroadcast that data as wifi (possibly using another arduino)at the other end?
Cheers,
Mg
fryslan76
Posts: 290
Joined: Dec 18th, 2012, 4:52 pm
Location: Netherlands

Re: arduino and wi fi

Post by fryslan76 »

Hmm a quick google search on arduino an wifi gives plenty of shields to work with so I would say yes. I assume you wanna use the UTP cable as theter then? And Wifi on the surface to get some moving space?
m_g
Posts: 51
Joined: May 17th, 2012, 7:14 pm

Re: arduino and wi fi

Post by m_g »

fryslan76 wrote:Hmm a quick google search on arduino an wifi gives plenty of shields to work with so I would say yes. I assume you wanna use the UTP cable as theter then? And Wifi on the surface to get some moving space?
Yes, for a few reasons, I will be remote to my "base station" so I would like to communicate with my base station via wifi, then stream the data to the rov over the tether, then retransmit (it must be retransmitted, not hard wired) this data to the rov. Anyone else know whether this is possible( I don't need to know the specifics, but an idea of feasibility and required parts would be helpful)
Cheers!
fryslan76
Posts: 290
Joined: Dec 18th, 2012, 4:52 pm
Location: Netherlands

Re: arduino and wi fi

Post by fryslan76 »

On land no problem for a base station to communicate through wifi with an arduino. For communication of the land arduino to the ROV arduino UTP or an other cable should be used the distance that wifi travels in water is not very much. From the ROV arduino yoo can use wifi in the hull and maybe for some external devices very nearby. How far you can go I don't know but a quick test should give you the needed answers.
Seawolf
Posts: 33
Joined: Oct 15th, 2011, 10:22 pm

Re: arduino and wi fi

Post by Seawolf »

For a class project we made AUVs with a wireless router onboard. Adruino connected to the router over USB, and an antenna extension cable ran from the router to the surface. It worked well, but were were only going to a depth of 15 feet.

I can get you some more information about what exactly we did if this sounds like what you need.
m_g
Posts: 51
Joined: May 17th, 2012, 7:14 pm

Re: arduino and wi fi

Post by m_g »

Seawolf wrote:For a class project we made AUVs with a wireless router onboard. Adruino connected to the router over USB, and an antenna extension cable ran from the router to the surface. It worked well, but were were only going to a depth of 15 feet.

I can get you some more information about what exactly we did if this sounds like what you need.
Hi Seawolf,
That sounds interesting, if you have any more info I would definitely be interested.
Cheers
Mg
Seawolf
Posts: 33
Joined: Oct 15th, 2011, 10:22 pm

Re: arduino and wi fi

Post by Seawolf »

We used an ASUS WL-520gu router (which will fit nicely inside a 6" PVC pipe). You're going to need a third party firmware, which will allow you to run a serial to network gateway on the router. Just follow the directions Here: http://todbot.com/blog/2010/12/16/wifi- ... -wl-520gu/ to get the software working on the router.

Then get yourself an antenna extension cable from amazon, like this one: http://www.amazon.com/Wireless-Router-A ... sion+cable We used a 15' extension and didn't have any problems. If you're adventurous, you could try the 25 foot one and see what happens.

Add the extension between the router and the antenna, then put the antenna on a buoy and you should be good to go.

Note: Having to unscrew the antenna extension from the router every time you take your vehicle apart can be a real pain in the ass, so plan ahead.

You're going to want to duct all your thrusters, that way your antenna doesn't get caught in a prop. (And you should do it anyway, since it increases efficiency).

Other lessons learned: Be careful with the power going to the router/arduino. The router takes 5 volts, while the arduino takes 12. Putting 12 volts through the router and plugging in the arduino will destroy your arduino (ask me how I know).


On the software side of things, you may want a virtual serial port on your base station, so the arduino will look like it's plugged directly into the computer.
We never found a good solution for windows, but on a linux or mac you should be able to use the following:

socat -d -d pty,raw,echo=0 TCP:192.168.1.1:3001 (or whatever IP and port the arduino is connected to)
sudo ln -s /dev/pts/12 /dev/ttyS4 (The values that go in this line are determined by the output of the first command, so be sure to read it).


But unless you have a compelling reason to make it look like a USB device, I'd stick to just opening up a socket and sending it commands through a network interface.
For our robots we just sent a string of comma separated motor values with unique start and end characters. (#255,255,1$ for example). The arduino parsed the string and sent the right PWM values to the motor controller. It also sent back information from the IMU and distance sensors in a similar format.

I may have some of the arduino source code still, if that would be helpful. (It's nice for prototyping, since you can sent motor commands via matlab).


There are a few pictures of our robots in the AUV section.
Post Reply