From cd6d708d687a80587e666c83db51471b2a30c05b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Diego=20Elio=20Petten=C3=B2?= Date: Tue, 17 Jan 2017 00:28:44 +0000 Subject: fsprecisionneo: move the version and serial number information to the common support class. --- glucometerutils/support/freestyle.py | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'glucometerutils/support/freestyle.py') diff --git a/glucometerutils/support/freestyle.py b/glucometerutils/support/freestyle.py index b6dce38..9857086 100644 --- a/glucometerutils/support/freestyle.py +++ b/glucometerutils/support/freestyle.py @@ -152,6 +152,14 @@ class FreeStyleHidDevice(object): # Some of the commands are also shared across devices that use this HID # protocol, but not many. Only provide here those that do seep to change # between them. + def _get_version(self): + """Return the software version of the device.""" + return self._send_text_command(b'$swver?').rstrip('\r\n') + + def get_serial_number(self): + """Returns the serial number of the device.""" + return self._send_text_command(b'$serlnum?').rstrip('\r\n') + def get_datetime(self): """Gets the date and time as reported by the device. -- cgit v1.2.3