iOS Quick Start

Get Gimbal up and running in your iOS App.

Create Your Developer Account

Go to the Gimbal Manager and create an account.

Gimbal Manager »

Create Your iOS Application

The following steps will set up an application in Xcode ready for enabling Gimbal features.

Confirm Your Environment

Make sure you are:

  • Using Xcode 4.4 or higher
  • Targeting iOS 5.1.1 or higher
  • Using an iOS device with Bluetooth 4.0. Here is a list of the compatible devices:
    • iPhone 4S or newer
    • iPad 3 or newer
    • iPad mini
    • iPod touch (5th Generation)
  • Have a valid Apple Developer Account
  • Have a valid Apple Provisioning Profile

Create a new Xcode project

In Xcode choose File > New > Project and create a new Application

Add these iOS Frameworks and Libraries to your project

  • CoreBluetooth.framework
  • CoreLocation.framework
  • CoreData.framework
  • libz.dylib
  • MapKit.framework
  • Security.framework

Having trouble adding these to your project? Here's some help

Add these Gimbal Frameworks to your project

Important Right click the Frameworks folder and choose the "Add files to ..." option to add these frameworks.

It is strongly recommended to add the Gimbal Frameworks using this method to ensure that the Target Membership checkbox is enabled properly. If an alternate method is used, then the Target Membership of the frameworks must be verified and checked.

  • Common.embeddedframework
  • ContextCore.embeddedframework
  • ContextLocation.embeddedframework
  • FYX.framework
  • NetworkServices.embeddedframework

Note You will find these frameworks in the Frameworks folder inside the Gimbal SDK zip file.

Your frameworks directory should now look like this:

Verify Target Membership

For each Gimbal Framework, verify the Target Membership checkbox is set:

Verify your deployment target version

Verify your deployment target matches the iOS version of your device:

Create Your Gimbal Application

Follow the link below to create your application in Manager.

Create Gimbal Application»

Bundle Identifier is needed when you register your application. For example bundle identifier is generated during Xcode project creation

Once your application is created the generated API key will be available.

Create UserContext.plist properties file

Copy API key you generated in the Gimbal Manager

Gimbal Manager »

Create a plist file named UserContext.plist in your project and add the following properties. Insert your production api key for key PRODUCTION_API_KEY as shown below.

Enable Context Core Connector

Add this code to the top of your AppDelegate implementation (.m) file.


    #import <ContextCore/QLContextCoreConnector.h>
        

Add this code to your application: didFinishLaunchingWithOptions: method in your AppDelegate.

    QLContextCoreConnector *connector = [QLContextCoreConnector new];
    [connector enableFromViewController:self.window.rootViewController success:^
     {
         NSLog(@"Gimbal enabled");
     } failure:^(NSError *error) {
         NSLog(@"Failed to initialize gimbal %@", error);
     }];

        

Important The location of this code in your application will depend on your design and intended usage of Gimbal. For the purpose of demonstrating how to quickly get an application functioning we have placed it in the AppDelegate

Learn More

For additional details on how to leverage the SDK functionality, refer to the sample applications and documentation included in the zip file provided.

Gimbal iOS Guide »