From 60aaccb15fae38926cc9c1d1b46cd1ee7604aa68 Mon Sep 17 00:00:00 2001 From: Daniel Dakhno Date: Mon, 1 Feb 2021 17:08:45 +0100 Subject: [PATCH] Fossil HR: fixed bug with unknown data --- .../devices/qhybrid/parser/ActivityFileParser.java | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/app/src/main/java/nodomain/freeyourgadget/gadgetbridge/service/devices/qhybrid/parser/ActivityFileParser.java b/app/src/main/java/nodomain/freeyourgadget/gadgetbridge/service/devices/qhybrid/parser/ActivityFileParser.java index 557d530d2..3fdb7a591 100644 --- a/app/src/main/java/nodomain/freeyourgadget/gadgetbridge/service/devices/qhybrid/parser/ActivityFileParser.java +++ b/app/src/main/java/nodomain/freeyourgadget/gadgetbridge/service/devices/qhybrid/parser/ActivityFileParser.java @@ -94,11 +94,15 @@ public class ActivityFileParser { break; case (byte) 0xE2: byte type = buffer.get(); - int timestamp = buffer.getInt(); - short duration = buffer.getShort(); - short minutesOffset = buffer.getShort(); if (type == 0x04) { + int timestamp = buffer.getInt(); + short duration = buffer.getShort(); + short minutesOffset = buffer.getShort(); this.currentTimestamp = timestamp; + }else if(type == 0x09){ + byte[] args = new byte[2]; + buffer.get(args); + // dunno what to do with that } break; case (byte) 0xDD: