Currently the location ID for a device is configurable both on the back-end on the device. This is sort of a feature; the idea was that the user could easily update the device if it moves, without having to worry about the back-end. But it opens up the possibility that the device has an invalid location ID (it can't always check that it's valid) and that the device and back-end have different ideas of the location. It also adds a user-configurable datum that we would just as soon do without (see #55). Therefore:
[x] remove the ability for the user to configure the location on the device
[x] EITHER remove the location ID from the device and remove the location ID from the JSON package
[x] OR have the back-end send the location ID to the device as part of the startup package
I probably think that the device doesn't need to know its location. It's only being used for reporting, and if the location ID came from the back-end then this is nearly redundant. (To the extent it's not redundant, the back-end can add the location ID to the JSON package when it arrives at the back-end, by getting it from the device record.)
I opted for removing the location ID from the device, and the back-end does not add it to the observation message at this time, it's not currently useful.
Currently the location ID for a device is configurable both on the back-end on the device. This is sort of a feature; the idea was that the user could easily update the device if it moves, without having to worry about the back-end. But it opens up the possibility that the device has an invalid location ID (it can't always check that it's valid) and that the device and back-end have different ideas of the location. It also adds a user-configurable datum that we would just as soon do without (see #55). Therefore:
I probably think that the device doesn't need to know its location. It's only being used for reporting, and if the location ID came from the back-end then this is nearly redundant. (To the extent it's not redundant, the back-end can add the location ID to the JSON package when it arrives at the back-end, by getting it from the device record.)