diff --git a/app/src/main/java/nodomain/freeyourgadget/gadgetbridge/service/devices/pebble/GadgetbridgePblSupport.java b/app/src/main/java/nodomain/freeyourgadget/gadgetbridge/service/devices/pebble/GadgetbridgePblSupport.java index f12bba39..099fd8fc 100644 --- a/app/src/main/java/nodomain/freeyourgadget/gadgetbridge/service/devices/pebble/GadgetbridgePblSupport.java +++ b/app/src/main/java/nodomain/freeyourgadget/gadgetbridge/service/devices/pebble/GadgetbridgePblSupport.java @@ -57,7 +57,7 @@ public class GadgetbridgePblSupport { byte type = (byte) ((sample & 0xe000) >>> 13); byte intensity = (byte) ((sample & 0x1f80) >>> 7); byte steps = (byte) (sample & 0x007f); - db.addGBActivitySample(timestamp + offset_seconds, SampleProvider.PROVIDER_PEBBLE_GADGETBRIDGE, intensity, steps, type); + db.addGBActivitySample(timestamp + offset_seconds, SampleProvider.PROVIDER_PEBBLE_GADGETBRIDGE, (short) (intensity & 0xff), (short) (steps & 0xff), type); offset_seconds += 60; } } catch (GBException e) {