package temperature type BatteryState int const ( BATT_NOT_AVAILABLE BatteryState = -1 BATT_BAD BatteryState = 0 BATT_GOOD BatteryState = 1 ) // Measurement provides an interface for each reading type Measurement struct { // ID of the sensor ID int // Temperature in celcius Temperature float64 BatteryState BatteryState }