diff --git a/vehicle.go b/vehicle.go index b2f940f..7e839f5 100644 --- a/vehicle.go +++ b/vehicle.go @@ -138,7 +138,7 @@ type Tire struct { Position string SubPosition string Pressure int - PressurePsi int + PressurePsi string Status string Updated time.Time } @@ -660,14 +660,14 @@ func (v *Vehicle) GetVehicleStatus() { v.client.logger.Debug("VEHICLE COND", "key", key, "data", child.Data(), "number", len(submatchall)) if tire, ok := v.Tires[pos]; ok { - tire.PressurePsi = child.Data().(int) + tire.PressurePsi = child.Data().(string) tire.Updated = time.Now() } else { - tire.PressurePsi = child.Data().(int) + tire.PressurePsi = child.Data().(string) tire.Updated = time.Now() v.Tires[pos] = Tire{ Position: submatchall[0], - PressurePsi: child.Data().(int), + PressurePsi: child.Data().(string), Updated: time.Now(), } if len(submatchall) >= 2 { @@ -832,14 +832,14 @@ func (v *Vehicle) GetVehicleCondition() { v.client.logger.Debug("VEHICLE COND", "key", key, "data", child.Data(), "number", len(submatchall)) if tire, ok := v.Tires[pos]; ok { - tire.PressurePsi = child.Data().(int) + tire.PressurePsi = child.Data().(string) tire.Updated = time.Now() } else { - tire.PressurePsi = child.Data().(int) + tire.PressurePsi = child.Data().(string) tire.Updated = time.Now() v.Tires[pos] = Tire{ Position: submatchall[0], - PressurePsi: child.Data().(int), + PressurePsi: child.Data().(string), Updated: time.Now(), } if len(submatchall) >= 2 {