opendata-stuttgart / sensors-software

sourcecode for reading sensor data
573 stars 312 forks source link

GPS Date format #381

Open imaluschi opened 5 years ago

imaluschi commented 5 years ago

Hi, at the moment I'm working on a "mobile Feinstaubsensor" which is saving the Data on a SD-Card (to place the sensor somewhere where no WIFI is available. ESP8266 sends CSV to Teensy 3.5 over Serial. Therefore I need the GPS-Time.

At the moment the CSV-Output of the date is in the format month-day-year. I would suggest to change the format to the date representation according to ISO 8601: YYYY-MM-DD (also similar to GPX) <time>2002-02-10T21:01:29.250Z</time>

Why? Saving the CSV needs the date (I use it for filename to be able to identify the right file(s) ). But this is not possible - saving Files with MM-DD-YYYY mixes the files, so only YYYY-MM-DD is suitable. For me there are two possibilitys: (1) I change the Date-representation in airrohr-firmware.ino, but then I'm not able to easily switch to a new version because of code-modifications (ok, it's only shifting one code-line up, but it hase to be done). (2) Do a lot of string operations to change the format - oh no!!

Why MM-DD-YYYY? Especially here in europe is this format totally uncommon.

DeeKey commented 5 years ago

(to place the sensor somewhere where no WIFI is available. Very interesting idea! Then it will be possible to upload hystroical data from time to time