Skip to content

Commit

Permalink
aio: ensure that AnalogSensor event Data is always int
Browse files Browse the repository at this point in the history
Signed-off-by: deadprogram <[email protected]>
  • Loading branch information
deadprogram committed Apr 30, 2017
1 parent b250670 commit c9ec619
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/aio/analog_sensor_driver.go
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ func NewAnalogSensorDriver(a AnalogReader, pin string, v ...time.Duration) *Anal
// Data int - Event is emitted on change and represents the current reading from the sensor.
// Error error - Event is emitted on error reading from the sensor.
func (a *AnalogSensorDriver) Start() (err error) {
value := 0
var value int = 0
go func() {
timer := time.NewTimer(a.interval)
timer.Stop()
Expand Down

0 comments on commit c9ec619

Please sign in to comment.