Communicate with an iPhone through WiFi

I want my Arduino to send and receive messages to an iPhone using the WiFi. I don't want to use a pc or a router as intermediate. How can I do this? What hardware should I have?

Thanks

How can I do this?

First, you need to make the iPhone act as a WiFi hot-spot. I don't think they are capable of that, so I think you are dead in the water.

I want the arduino to be the hotspot.

You can use an ethernet shield on the Arduino and one of those "ethernet to wifi" adapters off eBay.

But the WiFi shield by itself can not be a hotspot. It only connects to existing networks; it does not create a network.

I am trying the exact same thing, but then with an Android phone. Here you can set the phone up as a WiFi Hotspot. But I am stuck with the Arduino WiFi Shield,... Pretty complicated to get it running it seems :slight_smile:

But I am stuck with the Arduino WiFi Shield

Stuck how? Either you know the type of connection needed (WEP or WPA) or you don't. Either you know the network name and password, or you don't.

If you know the connection type and credentials, connection is trivial. If you don't, you aren't stuck. You are shit out of luck. Not the same thing at all.

The iPhone can also be turned into a Hotspot but only if the 3G/4G is on since the normal goal of turning an iPhone into a Hotspot is to give internet access to other devices around it. Which is not my goal.

Is there a better way to communicate wirelessly, without any intermediate, with the iPhone without using WiFi? I have been told that the bluetooth range is quite small..

Besides the hardware, what software are you going to use to communicate with on the iPhone ?

jpiabrantes:
Is there a better way to communicate wirelessly, without any intermediate, with the iPhone without using WiFi? I have been told that the bluetooth range is quite small..

I think you are asking the wrong question and better off sticking to WiFi.

Check here Best Bluetooth Module - Networking, Protocols, and Devices - Arduino Forum

This not necessarily because of the limited range of bluetooth, more that you are confronted with a dog-chasing-car situation brought about by software issues. As it turns out, Arduino can connect with I-stuff if you use BLE (bluetooth 4) and I now understand an advantage of BLE is a much greater range, but I don't think anybody will tell you that bluetooth to iPhone is a good idea.

That's why I asked :wink:

The Ethernet->Router solution is dead simple and has the added advantage that you can use the mature Ethernet library which in turn is used by other Libraries.. Full Ad-Hoc or infrastructure abilities. Most routers are easy to configure per web interface, from the iPhone if you like.

A TP-Link WR702n costs $20-25 and a standard Ethernet Shield is maybe $30. Compare that with the price and functionality of the daead-on-arrival official Arduino WiFi shield. You can get a little smaller, cheaper, and faster if you replace the Ethernet shield with a WIZ820io embedded Ethernet Module.

The only other small WiFi solution are breakout boards for the Texas Instruments CC3000. But then that module doesn't function as an AP either ( correct me if I am wrong, please!) and has to be connected to another router.

But even if WiFi provides more paths to a solution, the question with what application you are going to communicate and with which protocols is still not out of the world. You just have more options! I've chosen the OSC protocol and TouchOSC but that may not work at all for what you want to do.