Skip to content

How to simulate user position

This guide explains how to simulate user position, for example for debugging or testing when you are not on the actual site, beacons aren’t available or you are using a emulator instead of a real phone.

There are two ways to simulate user position, one of them is using the “joystick” feature of our Map Widget. Second way is simulating beacons in some manner, to use a simulated beacon you need a device capable of receiving the simulated signal.

Mapwidget joystick

This is a custom UI element that Pointr provides if you are using our mapwidget, to allow testing wayfinding and other position related aspects without physically being on site.

To enable the joystick you need to set the isJoystickEnabled field of PTRMapFragment/PTRMapWidgetViewController to true.

mapWidgetFragment.mapFragment!!.isJoystickEnabled = true
let configuration = PTRMapWidgetConfiguration()
configuration.isJoystickEnabled = true
let mapWidget = PTRMapWidgetViewController(configuration: configuration)

Beacon

Besides testing with the joystick, if you prefer to test with an actual beacon, there are ways to simulate the configuration of a beacon which is actually on site, regardless of the real physical position. This is separated to two categories depending on codec configuration: lookup beacon and beacon codec. To simulate a beacon position, you can either use a beacon or an android device.

Lookup Beacon

For this type, the client should use the configuring app of their beacon vendor. For getting the parameters for the beacon, the client should go to their designated Pointr Cloud, and select the Map Designer tab from the left pane. From there, select the level that they want to simulate their position on, expand the POI Layer and then expand the IBeacon category. It is assumed that the client already added their beacon data to the cloud, if this is not done yet, an arbitrary IBeacon can be added, with Major & Minor that should be an unsigned integer value between 0 and 65535 not inclusive. Also, the UUID should follow the standard iBeacon UUID format. More information on how to add data to cloud can be found in the Pointr Cloud documentations. From the dropdown of IBeacon category, select a beacon, and note the Major, Minor, UUID of the beacon. Then open your vendor app, and configure the beacon with these values.

How to simulate beacons using your phones (Android/ iOS)

Go to your Pointr Cloud account and log in to your account.

  1. Go to Sites > Buildings > Levels > Content page.

  2. Click on Iot Devices.

  3. Pick and click on any beacon in the list and then copy the numbers from the 3 columns: UUID, major and minor (you will need these number for you to simulate the beacons on your phone later)

Then follow the guide below to simulate your own beacon using your phones (Android/iOS)

Beacon simulator for Android

You need two phones.

  • One needs to be an Android phone to simulate the beacon

  • Another device which can be either iOS or Android

Beacon simulator for Android Screenshots
1. Go to Play store with your Android phone and download the Beacon Simulator app:
2. Click ‘+ icon’ and choose ‘iBeacon’, a screen like this should appear:
3. Enter the numbers for UUID, major and minor to the corresponding columns that you copied from Pointr Cloud. There’s no need to change “Tx Power”.
4. Click on validate and the beacon appears on the Beacon Simulator app like this:
5. Activate the toggle button next to the beacon, which should now turn to orange. The moment you do this, your Android phone becomes a beacon.
Note: When you close the toggle of the beacon it removes the blue dot.
6. Download the Pointr app on the other phone. Start the app. Within seconds you can see the blue dot.

Beacon simulator for iOS

You need two phones. - One needs to be an iOS phone to simulate the beacon. - Another device which can be either iOS or Android - Please make sure the phones are not on Airplane mode.

Beacon simulator for iOS Screenshots
1. Go to App store with your iOS phone and download the Beacon Simulator app:
2. Open the app and enter the numbers for UUID, major and minor to the corresponding columns that you copied from Pointr Cloud.
3. Click on the image below to validate the simulated beacon, the image will start moving then it means that your beacon is starting to work.
Note: The moment you do this, your iOS phone becomes a beacon. When you click on the image again, the image will stop moving and the blue-dot on your app will be removed.
4. Download the Pointr app on the other phone. Start the app. Within seconds you can see the blue dot.

After following either of the mentioned methods, you should be able to see the blue-dot on the app. Please note that if you are using the Beacon Simulator app, you cannot use the same device for testing. So, for simulating a beacon with an Android device, you need to have a spare android device to use as a beacon.

Beacon Codec

For this type, the client should make sure their specific codec json is added to pointr cloud. Since the codec is custom, the beacon can only be configured using Pointr’s app, following the codec on cloud. This codec will be supplied by the Pointr team.

The client should ask their Project Manager for the password for the designated Guru App to configure their beacon. The Guru App is currently only available on iOS devices.

After downloading the Guru App, the client should select the Site that they want to simulate the position in, by opening the menu from the top left icon. After selecting this, the app needs to be restarted for the change to take effect.

Then, the client should click on the icon on top right, and select the beacon from the list. Then, the client should reposition the beacon as they please, and also select the UUID and Zone the beacon should be in. If you do not have a physical beacon, you can contact your project manager to get the encrypted major, minor, uuid values to configure a Beacon with these values using BeaconSimulator app as explained earlier.

After following either of these steps, you will be able to see the blue-dot as if you are physically on site.


Last update: June 4, 2024
Back to top