SDK created to scan Beacons
- iOS 12.0+
- Xcode 11
When using Xcode 11 or later, you can install Zen Beacon
by going to your Project settings > Swift Packages
and add the repository by providing the GitHub URL. Alternatively, you can go to File
> Swift Packages
> Add Package Dependencies...
Retrieve Zen Beacon
import Zen_Beacon
var Z_Beacon:ZenBeaconScanner()
Configure ZenBeaconDelegate
Z_Beacon.delegate = self
Start scan
Z_Beacon.Start_Scanning(AppID: "your APP ID")
Receive listener calls
ZenBeaconDelegate
func didReceivedAdvertiseDetails(AdvertiseData: NSDictionary)
{
print(AdvertiseData)
}
func didClickedOnAdvertise(AdvertiseData: NSDictionary)
{
print(AdvertiseData)
}
Stop scan
Z_Beacon.stop_Scan()
Extras
//turn on Notification (false by default)
Z_Beacon.is_enable_notification = true
Note
-- if you want to run this SDK in background mode , you have to call this all from 'AppDelegate'
-- you need to add NSLocationAlwaysUsageDescription in info.plist to run app in background as-well.
-- you need to add NSLocationUsageDescription, NSLocationWhenInUseUsageDescription, NSLocationAlwaysAndWhenInUseUsageDescription in info.plist.
-- you need to add NSBluetoothAlwaysUsageDescription in info.plist to run app in background as-well.
##Developed by Joyharsh Christie
##License
Copyright 2015 ZenExim Private limited.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.