Commit f365e558 authored by Axel Auweter's avatar Axel Auweter
Browse files

Fix weekstamp calculation and MBPusher timestamping.

parent 751689e9
......@@ -173,7 +173,7 @@ void SensorDataStoreImpl::insert(SensorId* sid, uint64_t ts, uint64_t value)
#endif
/* Calculate and insert week number */
uint16_t week = ts / 604800000000;
uint16_t week = ts / 604800000000000;
sid->dsid.rsvd = week;
/* Insert into Cassandra */
......
......@@ -103,7 +103,7 @@ uint64_t DCDBTimeStamp::getRaw(void)
*/
uint16_t DCDBTimeStamp::getWeekstamp(void)
{
uint16_t week = raw / 604800000000;
uint16_t week = raw / 604800000000000;
return week;
}
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment