發表文章

目前顯示的是 12月, 2019的文章

MQTT learning on Pi with BME280 and node-red, node-red-dashboard

圖片
install on pi using apt https://randomnerdtutorials.com/how-to-install-mosquitto-broker-on-raspberry-pi/ testing mqtt with pi terminal https://randomnerdtutorials.com/testing-mosquitto-broker-and-client-on-raspbbery-pi/ using esp32 https://randomnerdtutorials.com/esp32-mqtt-publish-subscribe-arduino-ide/ becareful with the BME280 board, I have 2 kinds of board, one with a square sensor on it, this one works with adafruit library, the other one with a rectangle one, this one does not work with most of BME280 libs. there is a post, saying adafruit library checks CHIPID of 280: http://davidstein.cz/2017/09/30/arduino-bme280-could-not-find-a-valid-bme280-sensor-solved/ I followed it and sensor start to work. the default address used in adafruit is 0x77, if you use 0x76, then use this:    status = bme.begin(0x76); Below both with default ID=0x76, the purple ones works finally, but no humidity reading with the example of adafruit, the blue one reads humidity with same code.