I'm working on a project where we would like to add wireless Ethernet, your every day 802.11 b/g network. We're creating custom boards for this and I don't want to have to recreate whatever is needed for Wi-Fi onto our board. There are plenty of ready made solutions already, such as Roving Network's Wi-Fi modules that SFE sells (like this one). Looks like I can simply add the two 2mm headers that this module then simply snaps into. However, I also noticed there is no library for that unit, although I did find the Arduino WiFly Driver which claims to also work with the RN-XV unit. Guess I'll try that.
However, I can't figure out what is needed to actually make this work. Looking around, there are a number of shields that this unit plugs in to, and they're all different. So this is where I need some help.
Our boards are a standard 328P AVR with Arduino bootloader, they'll have an FTDI IC on board for USB communications, an RTC, and SD card (with a matching hex converter.) So what other bits and pieces will I need to communicate between our 328P and the RN module? What pins from the RN goes to what pins on the 328P?
Physically you just need 4 connections: +3.3v, ground, RX, and TX. If you're not using a real Arduino board and you're running your circuit at 5v you'll have to add a voltage regulator for 3.3v; the WiFly board can't take 5v.
It sounds like you're using the hardware UART for USB communication so you'll want to use the NewSoftSerial / SoftwareSerial library to speak to the board; the WiFly library works well with it.
Ok cool. And you're right, the UART is being connected to the FTDI IC. Another option would be to add a UART-to-SPI IC and have it communicate over SPI, however I don't know if there are any advantages to that. Not to mention the addition of more components (UART-to-SPI IC, crystal).
My idea of using a ready made RN module, like the RN-XV WiFly Modules that SFE sells, is because it makes everything modular. If something happens with the unit, I can simply pull it out and replace it for another one, as opposed to having to junk our entire board. And it also allows me to add a W5100 to the board and give the end user the option of either wired or wireless communication (but that's thinking out loud.)
Another option would be to add a UART-to-SPI IC and have it communicate over SPI, however I don't know if there are any advantages to that
The only advantage I can think of would be communication speed. I think the software serial library is unreliable above 56k baud; the WiFly hardware says it can go up to 1.1Mbps.
Hmmmm ... if that's the case, then I may as well build our board with all the additional pieces, as opposed to using the WiFly module as a plug-in part. It'll end up being the same as SFE's WiFly Shield then.