From 066a2e70d5530b23edde4d7aa5d334651f3c22d7 Mon Sep 17 00:00:00 2001
From: Kevin Lyda <kevin@ie.suberic.net>
Date: Wed, 1 Feb 2017 23:57:44 +0000
Subject: [PATCH] Fix config deserialisation.

---
 devices/geiger/gqgmc.go | 106 ++++++++++++++++++++--------------------
 1 file changed, 53 insertions(+), 53 deletions(-)

diff --git a/devices/geiger/gqgmc.go b/devices/geiger/gqgmc.go
index 072e88e..08b04d7 100644
--- a/devices/geiger/gqgmc.go
+++ b/devices/geiger/gqgmc.go
@@ -63,59 +63,59 @@ type GQGMCCounter struct {
 
 // DevConfig is the gcgmc config block.
 type DevConfig struct {
-	PowerOnOff                   int8  `struct:"int8"`
-	AlarmOnOff                   int8  `struct:"int8"`
-	SpeakerOnOff                 int8  `struct:"int8"`
-	GraphicModeOnOff             int8  `struct:"int8"`
-	BackLightTimeoutSeconds      int8  `struct:"int8"`
-	IdleTitleDisplayMode         int8  `struct:"int8"`
-	AlarmCPMValue                int16 `struct:"int16,big"`
-	CalibrationCPM0              int16 `struct:"int16,big"`
-	CalibrationSvUcByte3p0       byte  `struct:"byte"`
-	CalibrationSvUcByte2p0       byte  `struct:"byte"`
-	CalibrationSvUcByte1p0       byte  `struct:"byte"`
-	CalibrationSvUcByte0p0       byte  `struct:"byte"`
-	CalibrationCPM1              int16 `struct:"int16,big"`
-	CalibrationSvUcByte3p1       byte  `struct:"byte"`
-	CalibrationSvUcByte2p1       byte  `struct:"byte"`
-	CalibrationSvUcByte1p1       byte  `struct:"byte"`
-	CalibrationSvUcByte0p1       byte  `struct:"byte"`
-	CalibrationCPM2              int16 `struct:"int16,big"`
-	CalibrationSvUcByte3p2       byte  `struct:"byte"`
-	CalibrationSvUcByte2p2       byte  `struct:"byte"`
-	CalibrationSvUcByte1p2       byte  `struct:"byte"`
-	CalibrationSvUcByte0p2       byte  `struct:"byte"`
-	IdleDisplayMode              byte  `struct:"byte"`
-	AlarmValueuSvByte3           byte  `struct:"byte"`
-	AlarmValueuSvByte2           byte  `struct:"byte"`
-	AlarmValueuSvByte1           byte  `struct:"byte"`
-	AlarmValueuSvByte0           byte  `struct:"byte"`
-	AlarmType                    byte  `struct:"byte"`
-	SaveDataType                 byte  `struct:"byte"`
-	SwivelDisplay                byte  `struct:"byte"`
-	ZoomByte3                    byte  `struct:"byte"`
-	ZoomByte2                    byte  `struct:"byte"`
-	ZoomByte1                    byte  `struct:"byte"`
-	ZoomByte0                    byte  `struct:"byte"`
-	SPIDataSaveAddress2          byte  `struct:"byte"`
-	SPIDataSaveAddress1          byte  `struct:"byte"`
-	SPIDataSaveAddress0          byte  `struct:"byte"`
-	SPIDataReadAddress2          byte  `struct:"byte"`
-	SPIDataReadAddress1          byte  `struct:"byte"`
-	SPIDataReadAddress0          byte  `struct:"byte"`
-	PowerSavingMode              int8  `struct:"int8"`
-	SensitivityMode              int8  `struct:"int8"`
-	CounterDelay                 int16 `struct:"int16,big"`
-	VoltageOffset                int8  `struct:"int8"`
-	MaxCPM                       int16 `struct:"uint16,big"`
-	SensitivityAutoModeThreshold int8  `struct:"int8"`
-	SaveDateTimeStamp6           byte  `struct:"byte"`
-	SaveDateTimeStamp5           byte  `struct:"byte"`
-	SaveDateTimeStamp4           byte  `struct:"byte"`
-	SaveDateTimeStamp3           byte  `struct:"byte"`
-	SaveDateTimeStamp2           byte  `struct:"byte"`
-	SaveDateTimeStamp1           byte  `struct:"byte"`
-	MaximumBytes                 byte  `struct:"byte"`
+	PowerOnOff                   int8   `struct:"int8"`
+	AlarmOnOff                   int8   `struct:"int8"`
+	SpeakerOnOff                 int8   `struct:"int8"`
+	GraphicModeOnOff             int8   `struct:"int8"`
+	BackLightTimeoutSeconds      int8   `struct:"int8"`
+	IdleTitleDisplayMode         int8   `struct:"int8"`
+	AlarmCPMValue                int16  `struct:"int16,big"`
+	CalibrationCPM0              int16  `struct:"int16,big"`
+	CalibrationSvUcByte3p0       byte   `struct:"byte"`
+	CalibrationSvUcByte2p0       byte   `struct:"byte"`
+	CalibrationSvUcByte1p0       byte   `struct:"byte"`
+	CalibrationSvUcByte0p0       byte   `struct:"byte"`
+	CalibrationCPM1              int16  `struct:"int16,big"`
+	CalibrationSvUcByte3p1       byte   `struct:"byte"`
+	CalibrationSvUcByte2p1       byte   `struct:"byte"`
+	CalibrationSvUcByte1p1       byte   `struct:"byte"`
+	CalibrationSvUcByte0p1       byte   `struct:"byte"`
+	CalibrationCPM2              int16  `struct:"int16,big"`
+	CalibrationSvUcByte3p2       byte   `struct:"byte"`
+	CalibrationSvUcByte2p2       byte   `struct:"byte"`
+	CalibrationSvUcByte1p2       byte   `struct:"byte"`
+	CalibrationSvUcByte0p2       byte   `struct:"byte"`
+	IdleDisplayMode              byte   `struct:"byte"`
+	AlarmValueuSvByte3           byte   `struct:"byte"`
+	AlarmValueuSvByte2           byte   `struct:"byte"`
+	AlarmValueuSvByte1           byte   `struct:"byte"`
+	AlarmValueuSvByte0           byte   `struct:"byte"`
+	AlarmType                    byte   `struct:"byte"`
+	SaveDataType                 byte   `struct:"byte"`
+	SwivelDisplay                byte   `struct:"byte"`
+	ZoomByte3                    byte   `struct:"byte"`
+	ZoomByte2                    byte   `struct:"byte"`
+	ZoomByte1                    byte   `struct:"byte"`
+	ZoomByte0                    byte   `struct:"byte"`
+	SPIDataSaveAddress2          byte   `struct:"byte"`
+	SPIDataSaveAddress1          byte   `struct:"byte"`
+	SPIDataSaveAddress0          byte   `struct:"byte"`
+	SPIDataReadAddress2          byte   `struct:"byte"`
+	SPIDataReadAddress1          byte   `struct:"byte"`
+	SPIDataReadAddress0          byte   `struct:"byte"`
+	PowerSavingMode              int8   `struct:"int8"`
+	SensitivityMode              int8   `struct:"int8"`
+	CounterDelay                 int16  `struct:"int16,big"`
+	VoltageOffset                int8   `struct:"int8"`
+	MaxCPM                       uint16 `struct:"uint16,big"`
+	SensitivityAutoModeThreshold int8   `struct:"int8"`
+	SaveDateTimeStamp6           byte   `struct:"byte"`
+	SaveDateTimeStamp5           byte   `struct:"byte"`
+	SaveDateTimeStamp4           byte   `struct:"byte"`
+	SaveDateTimeStamp3           byte   `struct:"byte"`
+	SaveDateTimeStamp2           byte   `struct:"byte"`
+	SaveDateTimeStamp1           byte   `struct:"byte"`
+	MaximumBytes                 byte   `struct:"byte"`
 }
 
 // NewGQGMC creates a new GQGMC Counter instance
-- 
GitLab