i2c: update bme280 example
Signed-off-by: deadprogram <ron@hybridgroup.com>
This commit is contained in:
parent
4c573b43f4
commit
633abf0751
|
@ -16,11 +16,10 @@ import (
|
|||
|
||||
func main() {
|
||||
firmataAdaptor := firmata.NewAdaptor(os.Args[1])
|
||||
bme280 := i2c.NewBME280Driver(firmataAdaptor, i2c.WithAddress(0x76))
|
||||
bme280 := i2c.NewBME280Driver(firmataAdaptor)
|
||||
|
||||
work := func() {
|
||||
gobot.Every(1*time.Second, func() {
|
||||
//fmt.Println("Pressure", mpl115a2.Pressure())
|
||||
t, _ := bme280.Temperature()
|
||||
fmt.Println("Temperature", t)
|
||||
|
||||
|
|
Loading…
Reference in New Issue