(Classic) Bluetooth providing IP address

Dears, I'm struggling with something that I wasn't able to find on the internet.

Here is my scenario:


I have a (classic) bluetooth device (non iOS) running Linux (I don't have any access to source code or whatever) and its need an IP address/port to communicate (send/receive data).


If I connect it to a WiFi network, I can use CFStreamCreatePairWithSocketToHost or NWEndpoint to create in/out socket streams to the device (the device can act either as Client or Server, that's why I can choose which network method to use).


If I enable Bluetooth and Personal hotspot, I can connect (pair) to the device and send/receive data the same way as WiFi.

But, on this case, I lost WiFi as iOS only supports Personal hotspot over Cellular network (3G/4G).

That limits my (hardware) options as my App will only runs on iPhones or iPads with mobile data. I would like to use it also on WiFi iPads and iPods.


My question is: is there any way my App can act as DHCP server (or similar) to provide an IP address to the device over Bluetooth ? So I can keep my WiFi on at the same time the device is connected to the phone/tablet using Bluetooth?


thanks, Cassio

(Classic) Bluetooth providing IP address
 
 
Q