Phonegap client app that detects iBeacon ranges on background and posts the data to a REST service