Retrieving data recorded by an IoT sensor

bluetooth low energysdxbee

If an IoT object records data (accelerometer, gyroscope, …) in memory, what would be the smartest way to retrieve these data after, let's say, 2-3 days?

  • Store in JSON format on an SD Card?
  • Store in Memory then wire: USB?
  • Wireless: with BLE? XBee?

The idea is to retrieve the JSON data very easily from a computer without yet another hub, bridge, etc…

Best Answer

If your IoT device can interface with an SD card, then sure, store the data as ASCII bytes, comma seperated, and you can do a very quick import into Micrsoft Excel or any other spreadsheet program. CSV (Comma seperated values) files are very easy to read with a Java program too, perhaps you need a quick custom Java program to convert them to be JSON compatible.

If your IoT device supports USB, you can make it store the data in Flash memory or similar non volatile (or volatile, your choice! if batteries will be good enough for that long) however you must look at the sample rate and data size and expected run time to see if your device actually has enough onboard storage. A very quick custom serial routine can be written to make it dump all the data over serial/USB after request, and you can write a very simple custom C, C++, Java, or C# program to receive and store as a local CSV or JSON format file (whatever you want, really).

If you always have something nearby you can indeed set up an Xbee serial link for remote data storage, or BLE based serial bridge to a nearby "base station" that can do the storage and monitoring.