I want to build an embedded device which will take its current location (in latitude, longitude) and output custom serial data about a number of the nearest few points in a list.
Current location and the points holding the custom data are represented by latitude and longitude, although could be projected to another coordinate system in preprocessing.
Nearest doesn't need to be too accurate. The points are fairly sparse - tens of miles apart in general and where two are close-by it unlikely to matter much which order they are presented in. And I'm only interested in points within the nearest 50 miles or so.#
The list is intended to be static, albeit updated periodically. No dynamic changes are expected.
I'm currently thinking of using an Arduino with GPS/SD card shield, but am struggling to come up with a sensible way of storing the data which doesn't need an exhaustive search (which I assume will be too slow and use too much memory).
Is there a common pattern to do this? Obviously postgis, etc. do this sort of thing, but they're far too bloaty to run on an Arduino and similar techniques will suffer the same issues.
I'm expecting to need to do some sort of preprocessing such that I get a tree lookup or similar, but can't see how this would work in more than one dimension.