Merge branch '2.0' into develop

This commit is contained in:
Markus Mäkelä
2017-02-01 09:35:13 +02:00
14 changed files with 314 additions and 78 deletions

View File

@ -291,7 +291,9 @@ static void unpack_datetime2(uint8_t *ptr, uint8_t decimals, struct tm *dest)
dest->tm_hour = time >> 12;
dest->tm_mday = date % (1 << 5);
dest->tm_mon = yearmonth % 13;
dest->tm_year = yearmonth / 13;
/** struct tm stores the year as: Year - 1900 */
dest->tm_year = (yearmonth / 13) - 1900;
}
/** Unpack a "reverse" byte order value */