Use your iOS app to show things on Mirror
Objective-C Swift JavaScript Ruby Python Java
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
Core Moved EstimoteMirrorCore.podspec to the Core folder Jul 24, 2018
Examples Updated podspec and added Podfiles to examples Aug 9, 2018
MirrorDisplay.xcodeproj Examples project cleanup Jul 24, 2018
Sources Fixed: mirror actions were sent as single dictionary istead of an array Aug 8, 2018
Tests Removed all code related to Mirror proximity detection and revamped t… Jul 24, 2018
Tools/Mirrorator Bumped npm packages in Mirrorator. Jun 28, 2018
.gitignore
EstimoteMirror.podspec
LICENSE.txt Update license Jun 28, 2017
README.md Updated README Aug 9, 2018

README.md

Estimote Mirror iOS SDK

CocoaPod Version Apache License 2.0

This SDK allows you to take control of the big screen from your iOS app with Estimote Mirror.

Main features:

  • Building Mirror experience based on mobile SDKs - you can start prototyping your first Mirror application, using only mobile Display SDK. There is no need to upload any code or resources upfront to the Mirror.

  • Pre-defined views - No need to design your first Mirror app view. iOS Mirror SDK lets you define customized screens based on pre-defined views; All you need to do is to declare basic styling and data.

  • Feedback from Mirror screen to mobile - Whenever any display action is triggered, your mobile app gets notified about it. You can handle successful screen change and perform further actions inside your mobile app.

Please check the rest of README to get further details.

We really appreciate your feedback about our SDKs, thank you!

Table of Contents

Installation

Prerequisities

  • 1 Estimote Mirror w/ 1.0.15+ firmware version.
  • An account in Estimote Cloud.
  • An iOS device with Bluetooth Low Energy support. We suggest using iOS 10.0+ (on iPhone 5s or newer).

Pod

Install via CocoaPods:

  • $ pod init in the project root directory
  • Edit your Podfile to include the following repositories under your project target
  pod 'EstimoteMirror'
  pod 'EstimoteBluetoothScanning'
  pod 'EstimoteProximitySDK'
  • $ pod install

Obtain app credentials from Estimote Cloud

To obtain Estimote Cloud credentials for your mobile application:

  1. Log in to your Estimote Cloud account.
  2. Go to Apps section and click Add new app option.
  3. Select Your own app option.
  4. Save your App Id/App Token credentials.

Quick start

Here is simple example for showing Poster View on the screen, when user appears in Mirror nearby range.

// Declare mirrorClient and proximityObserver as class properties
let mirrorClient = MirrorClient(appID: "", appToken: "")
var proximityObserver: EPXProximityObserver!

// Inside you class implementation
// Prepare your customized Poster View
let sneakersBanner = Poster() { p in
            
    p.header = "Exceptional traction\nfrom your first to final mile"
    p.body = "Now 20% off!"
    p.image = .preloaded(path: "shoe_big.jpg")
    
    p.style = PosterStyle() { ps in
        
        ps.imagePosition = Position(horizontal: .center, vertical: .top(offset: 80))
        ps.textPosition = Position(horizontal: .center, vertical: .bottom(offset: 80))
        ps.textAlign = .center
        ps.headerFontSize = .percent(130)
    }
}
        
// Initialize your Estimote Cloud credentials
let credentials = CloudCredentials(appID: "", appToken: "")

// Build ProximityObserver with Cloud credentials
self.proximityObserver = ProximityObserver(credentials: credentials, onError: { error in
    
    print("\(error)")
})

// Define near proximity zone
let mirrorZone = ProximityZone(tag: "mirror", range: ProximityRange.near)
mirrorZone.onEnter = { zoneContext in
   
    print("Enter mirror")
    self.mirrorClient.display(sneakersBanner, onMirror: zoneContext.deviceIdentifier)
}
mirrorZone.onExit = { zoneContext in
    
    print("Exit mirror")
}

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

Zone monitoring is based on Estimote Proximity SDK - the most reliable signal-processing technology.

To get more details, you can check out README for iOS-Proximity-SDK.

Your feedback and questions

At Estimote we believe in open feedback! Here are some common ways to share your thoughts with us:

Changelog

To see what has changed in recent versions of our SDK, please visit our releases page.

License

Apache 2.0