Umstellung auf UTC Timestamp
This commit is contained in:
1 parent
d5ec222efd
commit
6154bf833e
8 files changed
+14
-17
No files matched your search
@@ -595,7 +595,7 @@ class MqttCore with ProducerMixin, ConsumerMixin {
|
||||
answer.utcUnixTime = DateTime.now().toUtc().millisecondsSinceEpoch ~/ 1000;
|
||||
|
||||
answer.pos = SyncMessagePos();
|
||||
answer.pos!.time = currentPosition != null ? Util.toUnixMillisUtc(currentPosition.timestamp.toUtc()) : 0;
|
||||
answer.pos!.time = currentPosition != null ? Util.toUnixSecondsUtc(currentPosition.timestamp.toUtc()) : 0;
|
||||
answer.pos!.lat = currentPosition != null ? currentPosition.latitude : 0.0;
|
||||
answer.pos!.long = currentPosition != null ? currentPosition.longitude : 0.0;
|
||||
answer.pos!.acc = currentPosition != null ? currentPosition.accuracy.toInt() : 0;
|
||||
@@ -622,7 +622,7 @@ class MqttCore with ProducerMixin, ConsumerMixin {
|
||||
var trackMessage = TrackPosition();
|
||||
|
||||
if (position != null) {
|
||||
trackMessage.time = Util.toUnixMillisUtc(position.timestamp);
|
||||
trackMessage.time = Util.toUnixSecondsUtc(position.timestamp);
|
||||
trackMessage.lat = position.latitude;
|
||||
trackMessage.long = position.longitude;
|
||||
trackMessage.acc = position.accuracy.toInt();
|
||||
|
||||
Reference in new issue
Block a user