Skip to content
This repository has been archived by the owner on Jul 22, 2024. It is now read-only.
Anthony Amanse edited this page Mar 16, 2018 · 6 revisions

Short Name

Using MapKit to create a Dynamic Indoor Map

Short Description

Build an Indoor Map with Apple's MapKit framework and use a Cloud Foundry app for its data.

Offering Type

Cloud

Introduction

Conferences can sometimes get messy but having an Indoor Map on an attendee's phone is an easy way to get people quickly find your booth. This Code Pattern introduces you into building one using Apple's existing framework, MapKit. This framework helps you use the Apple Maps in your iOS app and add in the floor plan of your conference. The framework also lets you add in more overlays rather than just a floor plan. With the help of a Cloud Foundry app and MongoDB acting as your backend and storage, you will have a dynamic mobile app. The app uses a heat map to represent the use of dynamic data.

Author

By Anthony Amanse

Code

https://github.com/IBM/ios-mapkit-indoor-map

Overview

In this Code Pattern, we will create an indoor map using Apple's MapKit framework and a Cloud Foundry app for the iOS app's backend. The iOS app will use the existing framework MapKit to display the map while the Cloud Foundry app will generate a PDF file of an indoor map which is consumed by the iOS app. With the use of a backend data that is separate from the iOS app, developers would not need to keep updating their iOS app if they want to modify their indoor map's floor plan. This app extends the sample code in Footprint: Indoor positioning from Apple.

When the reader has completed this Code Pattern, they will understand how to:

  • Deploy a Cloud Foundry app
  • Build an iOS map using MapKit
  • Integrate the iOS map to get data from the Cloud Foundry app
  • Make custom overlays with MapKit

Flow

  1. The user opens the iOS application and can toggle the heatmap on or off. The user will also generate random data of events in the zones of the indoor map. This should update the colors of the heatmap.
  2. The iOS app sends requests to the backend through RESTful API.
  3. The backend retrieves or updates the documents in the database. The backend would also generate the PDF based on the data received.
  4. The database gets or updates the data based on the request from the server.

Included components

  • Cloud Foundry: Build, deploy, and run applications on an open source cloud platform.
  • Compose for MongoDB: MongoDB with its powerful indexing and querying, aggregation and wide driver support, has become the go-to JSON data store for many startups and enterprises.

Featured technologies

  • Mobile: Systems of engagement are increasingly using mobile technology as the platform for delivery.
  • Node.js: An open-source JavaScript run-time environment for executing server-side JavaScript code.

Blog

http://developer.ibm.com/code/?p=33034&preview=1&_ppp=ae00eea957

Video

https://youtu.be/HJNzlc-LJ4U

Links

  • MapKit - Framework to embed maps directly into an iOS app.