Skip to content

Commit

Permalink
Allow a slightly wider range of piezo vibration values
Browse files Browse the repository at this point in the history
  • Loading branch information
zankich committed Jul 9, 2015
1 parent d560583 commit 317591b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion platforms/gpio/grove_drivers.go
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ func NewGrovePiezoVibrationSensorDriver(a AnalogReader, name string, pin string,
sensor.AddEvent(Vibration)

gobot.On(sensor.Event(Data), func(data interface{}) {
if data.(int) == 1023 {
if data.(int) > 1000 {
gobot.Publish(sensor.Event(Vibration), data)
}
})
Expand Down

0 comments on commit 317591b

Please sign in to comment.