How to use a beacon's accelerometer? What is Motion UUID?


Every Estimote Beacon has an accelerometer installed. This means that the beacon detects when it’s put in motion, giving you the ability to enrich your app with additional context. Also, conditional broadcasting allows to ‘mute’ a beacon based on accelerometer readings, which makes testing easier and helps preserve battery life.

Conditional broadcasting modes:

  • Motion UUID
  • Flip to Sleep
  • Motion only

The new beacons automatically enable/disable the accelerometer depending on whether you're using any features that require it or not. For example, if you enable the Estimote Telemetry packet, which makes the beacon broadcast all of its sensor data, then our firmware automatically enables the accelerometer.

Estimote Stickers also come with a built-in accelerometer. They use our own Nearable communication protocol to advertise motion status. This means that stickers broadcast full accelerometer data over the air at all times.

Visit Estimote Developer Portal to learn how to utilize stickers’ motion data.

Motion UUID

Motion UUD is an alternative UUID value, broadcast when the beacon is moving. It’s automatically derived from the regular UUID by the beacon firmware and the Estimote SDK.

Only one UUID is broadcast at a time (the ‘static’ one or the ‘motion’ one). We can figure out whether the beacons in motion or not by ranging/monitoring for both UUIDs.

Note about monitoring:

Beacon region monitoring has a built-in delay of around 30 seconds from the point when the beacon goes out of range till the exit event is triggered by iOS. The implication is that when the beacon starts moving, the exit event for the ‘static’ region won’t be triggered until 30 seconds pass with the beacon constantly in motion. Same goes for the beacon stopping moving and the ‘exit’ event for the “motion” region.

How do you use it?

Define the “static” and “motion” regions:

CLBeaconRegion *staticRegion = [[CLBeaconRegion alloc] initWithProximityUUID:stillUUID major:123 minor:456 identifier:@"still"]; NSUUID *motionUUID = [ESTBeaconManager
CLBeaconRegion *motionRegion = [[CLBeaconRegion alloc] initWithProximityUUID:motionUUID major:123 minor:456 identifier:@"moving"];

Use ranging for best responsiveness in detecting whether the beacon broadcasts its regular UUID, or the motion UUID:

[self.beaconManager startRangingBeaconsInRegion:staticRegion];
[self.beaconManager startRangingBeaconsInRegion:motionRegion];

- (void)beaconManager:(id)manager
      didRangeBeacons:(NSArray *)beacons
             inRegion:(CLBeaconRegion *)region {
    if ([region.identifier isEqualToString:@"still"]
            && beacons.count > 0) {
        NSLog(@"the beacon is still");
    } else if ([region.identifier isEqualToString:@"moving"]
            && beacons.count > 0) {
        NSLog(@"the beacon is moving");

Hint: Location Beacons (hardware revision "F") and next-generation Proximity Beacons (hardware revision "G") can broadcast their motion status, as well as full accelerometer data, directly in an Estimote Telemetry packet:

Scanning telemetry data with Estimote iOS SDK
Scanning telemetry data with Estimote Android SDK

Flip to Sleep and Motion only

When Flip to Sleep is enabled, beacon goes ‘mute’ if it’s put on its back.

When Motion UUID is enabled, beacon goes ‘mute’ if it’s not moving.

Read the article on conditional broadcasting to learn about benefits of Flip to Sleep and Motion only modes.

Was this article helpful?
0 out of 0 found this helpful

1 Comment(s)

  • Avatar
    Samuel Cox

    I'm slightly unsure how to implement this code within, say, the iOS SDK accelerator example app. Could you expand on how to do this? Thanks

Estimote is