MFI program or WAC or NEHotspotHelper?

Hello,

As we know there is no direct way to show Wi-fi List in iOS app. We have small devices which are working as Wi-fi itself (Having multiple SSIDs, Within which one is common for all Ex. 'ABCD'). I want to show all devices list and its details (SSID, BSSID, Signal Strength etc.) in our iOS app. Please suggest best approach.

As I know NEHotspotHelper is not that much good approach due to low user experience. Please suggest if NEHotspotHelper is the only way to accomplish our requirement.

  1. Do We require to use MFi program for each device while manufacturing (to use WAC)? Please give some Info.
  2. NEHotspotConfiguration would be helpful? How?
  3. Do we need to support BLE.

Please suggest we are ready to do Anything.

Answered by Systems Engineer in 677571022

However we don't want to connect to the device directly, we first want to show the List of available devices in our app List and details (SSID, BSSID, Signal Strength etc.) in our iOS app by only scanning without connecting with it.

As mentioned, iOS does not provide an API to scan for Wi-Fi networks. Further information on this is provided in Q&A 1942:

https://developer.apple.com/library/archive/qa/qa1942/_index.html

There may be an opportunity here for your IoT devices to do the actual scan of Wi-Fi networks and report this information back to your iOS app over Core Bluetooth, but that is something you will need to research on your own.

Matt Eaton
DTS Engineering, CoreOS
meaton3@apple.com

For the following answer I am going to provide the information that I have in regards to NEHotspotConfiguration and NEHotspotHelper, I am not a MFi expert, so if you do have MFi questions I would recommend opening a MFi TSI for further help in that context.

Regarding:

I want to show all devices list and its details (SSID, BSSID, Signal Strength etc.) in our iOS app. Please suggest best approach. Please suggest if NEHotspotHelper is the only way to accomplish our requirement.

NEHotspotHelper would not be recommended here as you are interacting with accessory Wi-Fi devices that you manage and control. A typical use-cae that I see for NEHotspotHelper would be in an Enterprise environment where a iOS device could be navigating and associating with many different network hotspots over a given period. Now, that is my take on the situation and since I am not the NEHotspotHelper authority, if you require further insight on this matter I would recommend opening a TSI.

NEHotspotConfiguration and NEHotspotConfigurationManager are more of what you are looking for in this scenario. These APIs DO NOT list the details of the surrounding networks, such as the (SSID, BSSID, Signal Strength etc.). What they do allow you to do is configure your app to associate to a known SSID or SSID prefixed networks. For example, if all of the SSID's on the accessory Wi-Fi devices that you control are prefixed with a standard name followed by a numeric code you could do the following:

  • Network 1: iotdevice-123
  • Network 2: iotdevice-456
  • Network 3: iotdevice-789

And then use the init(ssidPrefix:passphrase:isWEP:) API to associate with "iotdevice" from your app. This would pick up the nearest "iotdevice" network as you came into contact with it. I wrote a sample that demonstrates using the NEHotspotConfiguration and NEHotspotConfigurationManager API called Configuring a Wi-Fi Accessory to Join the User’s Network. I would check that out as a first start into research this topic.

Matt Eaton
DTS Engineering, CoreOS
meaton3@apple.com

Thank you so much for your quick reply. 

We have few doubts around this, 

  1. If we have same SSID across all devices, is it possible to get the list of all wi-fi devices?
  2. Main motive behind this is to get SSID, BSSID, Signal Strength, So is there any way to get this info if we have same SSIDs. 

(List of all wi-fi devices and SSID, BSSID, Signal Strength these parameter are very much important rather Key feature for us)

If we have same SSID across all devices, is it possible to get the list of all wi-fi devices?

No.

Main motive behind this is to get SSID, BSSID, Signal Strength, So is there any way to get this info if we have same SSIDs.

No, you could try adding a unique suffix to each SSID as I described above.

You could also try advertising this information over BLE from your devices, but then the issue becomes how does the iOS app known which IoT device NEHotspotConfiguration needs to connect to if all are the same SSID?

Matt Eaton
DTS Engineering, CoreOS
meaton3@apple.com

Thanks for clarification,

However we don't want to connect to the device directly, we first want to show the List of available devices in our app (We are open to configure SSID with any specific prefi😆

Use Case:  Get the nearby Wi-Fi (our devices work itself as Wi-Fi) List and details (SSID, BSSID, Signal Strength etc.) in our iOS app by only scanning without connecting with it.

Hello meaton,

If we see below screenshots then these two apps can show nearby WIFI List? Is it right?

Alexa App Screenshot:  https://ibb.co/f9zf2qn
Google Home App Screenshot: https://ibb.co/B4WxvKd

If so, please let us know about these apps' implementation technique, will be helpful a lot. Your reply is valuable.

Accepted Answer

However we don't want to connect to the device directly, we first want to show the List of available devices in our app List and details (SSID, BSSID, Signal Strength etc.) in our iOS app by only scanning without connecting with it.

As mentioned, iOS does not provide an API to scan for Wi-Fi networks. Further information on this is provided in Q&A 1942:

https://developer.apple.com/library/archive/qa/qa1942/_index.html

There may be an opportunity here for your IoT devices to do the actual scan of Wi-Fi networks and report this information back to your iOS app over Core Bluetooth, but that is something you will need to research on your own.

Matt Eaton
DTS Engineering, CoreOS
meaton3@apple.com

Ok meaton, thank you for the help. I will research on it.

MFI program or WAC or NEHotspotHelper?
 
 
Q