tinygo-org / drivers

TinyGo drivers for sensors, displays, wireless adaptors, and other devices that use I2C, SPI, GPIO, ADC, and UART interfaces.
https://tinygo.org
BSD 3-Clause "New" or "Revised" License
607 stars 192 forks source link

Sensirion Sht4x Support #597

Closed trichner closed 1 year ago

trichner commented 1 year ago

Support for the SHT4x family of humidity & temperature sensors from Sensirion.

I've tried to keep the interface aligned with the existing SHT3x driver where it made sense but kept it simple.

deadprogram commented 1 year ago

Hello @trichner thanks for the new device support.

Can you please also add it to the smoketests here? https://github.com/tinygo-org/drivers/blob/dev/smoketest.sh

trichner commented 1 year ago

Hello @trichner thanks for the new device support.

Can you please also add it to the smoketests here? https://github.com/tinygo-org/drivers/blob/dev/smoketest.sh

Done! Though running them fails on some other test locally:

> make test
...
src/machine/board_bluepill.go:6:2: package device/stm32 is not in GOROOT (<redacted>/.cache/tinygo/goroot-3db76b2bbe6512878c9fc4ff18b9674eba0696a404ae4e2915298e4f7a087fad/src/device/stm32)
deadprogram commented 1 year ago

Thank you for making the requested changes @trichner now going to squash/merge.