After some struggle, we have come up with the mechanism how to make the connection of the device to the mobile app. It will require implementation of a broadcast protocol, which will search for the devices in the wifi network. Because this is quite low-level programming, which we want to avoid, we have to rely on some existing library. We have decided to use SSDP protocol, for which JT has found a reliable library we can use. We have also verified that there is an implementation of the SSDP for PhoneGap, which is the target platform for the mobile app.