Location aware lighting control, running in background

I have a project where a lighting prescription is created for each user based on their daily light exposure and desired goals. The prescribed lighting conditions need to follow the user as they move from room to room, with vacant rooms being turned off. We have built a server or hub that collects the prescriptions and can communicate with the lights. The hub will also prioritize which user’s settings are enabled when more than one user occupies the same room.

For this use case the location sensing app must run in the background, on iOS, other than for initial setup. My plan is to place one estimote in each room, all the estimotes in one residence would be assigned the same major. On entering a region, region being a minor, I would like to find the closest estimote and send a POST to our hub with the major and minor. On exiting a region if no estimotes are in range the app needs to POST to the hub so all the lights in the home turn off.

How reasonable is this? It is ok if there is a delay exiting a room but we want to minimize delay when entering a new room. I am new to iOS development and estimote development so any tips would be very helpful.

Thanks,
Geoff

Hi Geoff,

The use case sounds pretty interesting: thanks for sharing! Please remember that if you define the region with all values (UUID, Major, Minor) it will only include a single beacon: Estimote Cloud prevents two beacons from sharing the same ID. You can monitor for up to 20 regions at the same time, so if you need more, you’ll need to include a way to dynamically switch between them.

If you want to make sure there is as little delay as possible between entering beacon’s range and triggering enter region even, you might want to lower advertising interval on the beacons. Also, if the space is relatively small, you might want to reduce broadcasting power (range) too, to avoid signal overlapping.

Cheers.

Thanks for the advice. I imagine not too many homes have more than 20 rooms thankfully, but that is useful info to have. My plan is to provide a UI for the user to select what rooms are part of their home and to give each room a nick name.

I was going to associate UUID with the app (so all beacons would have the same UUID), Major with the household (so for one user all their beacons would have the same Major), and then Minor with room (only placing one beacon in each) room. Does that scheme of association seem reasonable? Would it be better to associate Major with each room in the event multiple beacons were needed to provide coverage?

Hi there,

In your case it makes sense to set up a region for each individual beacon (ie. with Minor). You can always play with the range or associate two regions with a single room, and don’t have to change the original structure (UUID: all beacons, Major: household, Minor: room).

Cheers.