Understanding Wifly Connection concept.

Hi All,

i want to control my project through wifi using android phone. I have a lot of confusion regarding this Wifly. I have done Xbee, and bluetooth UART module before. But for this wifly, i dont understand how it work. I already search all over the net and i found there are several type of way how it work. base on what i understand,

  1. adhoc - wifly will act like a router, then other device such as phone or pc will connect to it(correct me if i am wrong).

2.The other way wifly will work is by let the wifly connect to the router, then all phone or pc that also connected to the router will have access to the wifly (correct me if i am wrong).

  1. i also have read regarding webserver where the wifly act as webpage provider and any device can connect to the wifly as long as the internet connection is enabled.(again correct me if i am wrong)

my question,

  1. does my understanding is correct?

  2. base on the three method, which one is the most practical? what is the easy way? what i need to send through the net from pc or phone?

When you say most practical, that requires an understanding the goal. If you only want to talk to the wifly from the LAN, meaning your router, that is one thing. If you need access from any computer outside of your house to talk to the wifly, that is another thing. If you just want LAN, then set up the wifly with an ip, netmask, port number. You should be able to open a connection to it with any computer or phone via wifi on your LAN. The first thing to learn is how to configure the wifly from your processor or PC, so that you change parameters and also take a look at parameters from it. You can set up parameters in ad hoc, but ideally you are going to be using this with a processor right? In that case, it is a good idea to configure a method to enter CMD mode, display the response on a terminal, and change parameters as needed. Once you can do this, the rest is just a matter of choices. The wifly will just forward data that it receives to the processor via uart, the processor must parse the data and respond or perform some task. If you want to access the wifly via the internet, then you can set it up as a webserver, however your router must allow port forwarding from your ISP IP to your router to the wifly. Some routers must have port forwarding turned on per device or IP.

now i want to understand it one by one. first let talk about the adhoc. I manage to connect my wifly to my PC thorugh adhoc. What can i do with it? i mean,

does adhoc can only use to set the configuration?

or it can enable UART TX RX through it (send ASCII to uC from tera term)?

First of all, the wifly can only have one connection at a time. Maybe they are working on a version that allows multiple connections, but I am not aware. So you cannot connect via adhoc and uart at the same time.

Second, the wifly has a lot of parameters and a number of ways to use it. I suggest you do what I did. Print the manual, read it about 20 times, make notes, trial and error while testing. I spent more than a 100 hours figuring out the wifly, it takes practice and reading. There is no quick answer on the forum to determine what you want to do, how you need to do it. You have not stated the ultimate goal so it is not easy to provide a solution. In adhoc, you can program the device with the parameters you want. But, with a micro connected, you can also program the parameters just as easy.