Comments (8)
Hi @zkenstein
What do you mean by that?
from beaconcontrol.
Hi @jkurdel,
If I plan to use the backend with the hybrid app (Cordova or Ionic) is there any plan to release the plugin for this?
Thanks
from beaconcontrol.
Hi @zkenstein,
Currently we provide plugins for native apps - this may change in future. You can alway implement BLE plugin for Cordova/Ionic https://github.com/don/cordova-plugin-ble-central to be able to receive device ID and then use our REST API to control beacons with known ID's https://beaconcontrol.io/dev/backend-docs - which is not complicated solution.
from beaconcontrol.
Hi @botmonster @zkenstein i guess the plugin ble-central is meant to BLE communication when you can use https://github.com/petermetz/cordova-plugin-ibeacon made for iBeacon where you can monitor and range devices.
But am not sure which the API you need to call when you first get a beacon in a range I have read the docs but still can't figure it out can you please help @botmonster !
from beaconcontrol.
Hi! @zkenstein @botmonster Regarding to the second part of my previous comment about which API should hit to deliver the events it's/events
api however, I still think there is no clear way to understand the how things are working unless you know about how the iBeacon protocol well.
And follow the SDK code, work flow digram might solve this issue.
from beaconcontrol.
Hi @zkenstein @botmonster @mhd999 . Was anyone able to figure out the entire code that would monitor ibeacons within range of the UUID by making an ajax request to the "GET /s2s_api/v1/beacons" api, and based on the results (major, minor, promimity id, late, lng etc.), and then an "if" statements that would make another Ajax post request to the notifications api? It would be really helpful if someone could the code for such a Scenario. Thank you in advance.
from beaconcontrol.
So far I found this resource that will help in ranging/monitoring Ibeacons that are hard coded into the client, which is not the ideal solution unless you use a third party service like Ionic Cloud's Deploy service or MicroSoft's CodePush to update files in Cordova "www" folder to update the .js file with the ibeacon information. Although not a complete solution to my previous question, still need to figure out the "if" statement once an ibeacon is in range to send an ajax post request to fire the action. https://evothings.com/quick-guide-to-writing-mobile-ibeacon-applications-in-javascript/
from beaconcontrol.
Hi @brandecho you may want to add which SDK/Plugin you're using.
Since this issue opened for Cordova based app, and if your using Ionic 1 then this code should do the work for you or you can use vanilla javaScript instead if you are not using Ionic 1 and Angular.
Plugin: https://github.com/petermetz/cordova-plugin-ibeacon
Fetch your beacons and ranging them:
$http({
method: 'GET',
}).then(function(beacons){
beacons.forEach(function(beacon, index) {
$window.cordova.plugins.locationManager.startRangingBeaconsInRegion(createBeaconRegion(beacon.id, beacon.uuid, beacon.major, beacon.minor, true));
})
}, function(response){/*LOG ERROR*/}
Monitor Enter/Exit event:
delegate.didEnterRegion = function (pluginResult) {
$timeout(function () {
$window.cordova.plugins.locationManager.startRangingBeaconsInRegion(createBeaconRegion(pluginResult.region.identifier, pluginResult.region.uuid, pluginResult.region.major, pluginResult.region.minor, true))
.fail(function(e) {/*LOG ERROR*/})
.done(function(){delegate.didRangeBeaconsInRegion = function (pluginResult) {}})
});
};
from beaconcontrol.
Related Issues (20)
- After deploying on heroku , it's showing error related to "Google Maps API error" HOT 3
- Google Maps bug: TypeError: d is undefined HOT 1
- App freezing when deployed in load-balanced setting HOT 2
- Still Actively Maintained? HOT 3
- GCM/FCM notifications HOT 1
- Issues Adding coupon with image HOT 1
- Cannot upload coupon image through s2s API HOT 1
- SAAS format HOT 4
- Eddystone HOT 2
- beaconcontrol.io platform password HOT 6
- Outline of the next release
- How to install beaconcontrol HOT 2
- S2S Api - Internal Server Error - Converting Circular Structure to Json
- s2s api : how to create a user without using the UI HOT 1
- .
- Integrate with cubeacon
- Can't connect to local MySQL serve
- The `branch` option for `gem 'simple_form'` is not allowed when deploye to heroku HOT 2
- URL Web or correct port
- backend-docs page is down, is this project still fine to be used?
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from beaconcontrol.