Estimote / iOS-Proximity-SDK

Estimote Proximity SDK for iOS
https://developer.estimote.com
Apache License 2.0
61 stars 26 forks source link

Sample code not working #54

Closed MuhammedFareed closed 4 years ago

MuhammedFareed commented 4 years ago

Hello I have been trying to use the SDK when using the sample code below

self.proximityObserver = ProximityObserver(credentials: credentials, onError: { error in
    print("Oops! \(error)")
})
// Define zones
let blueberryZone = ProximityZone(tag: "blueberry", range: ProximityRange.near)
blueberryZone.onEnter = { zoneContext in
    print("Entered near range of tag 'blueberry'. Attachments payload: \(zoneContext.attachments)")
}
blueberryZone.onExit = { zoneContext in
    print("Exited near range of tag 'blueberry'. Attachment payload: \(zoneContext.attachments)")
}

blueberryZone.onContextChange = { contexts in
    print("Now in range of \(contexts.count) contexts")
}

// ... etc. You can define as many zones as you need.

// Start proximity observation
self.proximityObserver.startObserving([blueberryZone])

The call backs for onEnter and onExit never gets called. Knowing that I have on my cloud account a tag and beacon that has this tag.

Update: I discovered that my beacons was hardware version D would this affect the behavior of the code above

chwastek commented 4 years ago

sorry for the delay, did you enable in the Cloud Estimote Monitoring for these beacons?