summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDiego Elio Pettenò <flameeyes@flameeyes.eu>2017-09-13 15:21:51 +0200
committerDiego Elio Pettenò <flameeyes@flameeyes.eu>2017-09-13 15:34:23 +0200
commit58dbe4d2a0ea42805dcf914859b6abf47b51c566 (patch)
treefbb18e01f63afe83e52a3d37293e12c120b1d973
parentotverio2015: add debug logging to help track Issue #22. (diff)
downloadglucometerutils-58dbe4d2a0ea42805dcf914859b6abf47b51c566.tar
glucometerutils-58dbe4d2a0ea42805dcf914859b6abf47b51c566.tar.gz
glucometerutils-58dbe4d2a0ea42805dcf914859b6abf47b51c566.tar.bz2
glucometerutils-58dbe4d2a0ea42805dcf914859b6abf47b51c566.tar.lz
glucometerutils-58dbe4d2a0ea42805dcf914859b6abf47b51c566.tar.xz
glucometerutils-58dbe4d2a0ea42805dcf914859b6abf47b51c566.tar.zst
glucometerutils-58dbe4d2a0ea42805dcf914859b6abf47b51c566.zip
-rw-r--r--glucometerutils/drivers/otverio2015.py7
1 files changed, 4 insertions, 3 deletions
diff --git a/glucometerutils/drivers/otverio2015.py b/glucometerutils/drivers/otverio2015.py
index deeac4b..632192f 100644
--- a/glucometerutils/drivers/otverio2015.py
+++ b/glucometerutils/drivers/otverio2015.py
@@ -53,7 +53,7 @@ _STRUCT_CHECKSUM = _STRUCT_UINT16
_STRUCT_TIMESTAMP = _STRUCT_UINT32
_STRUCT_RECORDID = _STRUCT_UINT16
_STRUCT_READING = _STRUCT_UINT32
-_STRUCT_RECORD = struct.Struct('<BBHBHIIBBB')
+_STRUCT_RECORD = struct.Struct('<BBHBHIHBBBBB')
_QUERY_REQUEST = b'\x04\xe6\x02'
_QUERY_KEY_SERIAL = b'\x00'
@@ -253,8 +253,9 @@ class Device(object):
response[0], response[1]))
(unused_const1, unused_const2, unused_counter, unused_const3,
- unused_counter2, timestamp, value, unused_flags, unused_const4,
- unused_const5) = _STRUCT_RECORD.unpack(response)
+ unused_counter2, timestamp, value, unused_meal, unused_const4,
+ unused_flags, unused_const5, unused_const6) = _STRUCT_RECORD.unpack(
+ response)
return common.Reading(_convert_timestamp(timestamp), float(value))