Cov txheej txheem:

Ntau BMP280 Sensors hauv Arduino Uno Via SPI: 6 Cov Kauj Ruam
Ntau BMP280 Sensors hauv Arduino Uno Via SPI: 6 Cov Kauj Ruam

Video: Ntau BMP280 Sensors hauv Arduino Uno Via SPI: 6 Cov Kauj Ruam

Video: Ntau BMP280 Sensors hauv Arduino Uno Via SPI: 6 Cov Kauj Ruam
Video: Ntau lub tswv yim 1 (full movie) 2024, Kaum ib hlis
Anonim
Ntau BMP280 Sensors hauv Arduino Uno Via SPI
Ntau BMP280 Sensors hauv Arduino Uno Via SPI

Hauv qhov kev qhia no peb yuav txuas peb BMP280 ntawm Arduino Uno ntawm SPI tab sis koj tuaj yeem txuas mus txog yim BMP280 ntawm Uno siv cov chaw nres nkoj digital D3 rau D10 ua nSS (Qhev Xaiv) rau txhua lub ntsuas.

Qhov tshwm sim ntawm qhov ntsuas huab cua ntsuas los ntawm BMP280 yuav raug qhia ntawm 16x2 LCD LCM1602 zaub.

Cov zaub LCD yuav txuas nrog Uno ntawm I2C (lossis IIC) los ntawm PCF8574 module.

Kauj ruam 1: Txheej txheem cej luam

Txheej txheem cej luam
Txheej txheem cej luam
Txheej txheem cej luam
Txheej txheem cej luam

Bosch BMP280 ntsuas qhov ntsuas cua thiab ntsuas kub ntsuas SPI thiab I2C (lossis IIC) kev sib txuas lus nrog lub microcontroller. Nws yog lub ntsuas qhov ntsuas siab (0.16Pa lossis ± 1m) thiab kev siv qis (2.7µA).

BMP280 yog kho dua tshiab ntawm BMP180 version uas muaj ntau yam kev txhim kho: kev daws teeb meem siab dua rau qhov siab thiab ntsuas kub, qis zog siv, tshiab ntxiv interface SPI, ntsuas suab nrov qis, qis RMS suab nrov, hneev taw me me, ntsuas ntau dua, ntsuas siab dua thiab ntxiv tshiab lim tawm ib puag ncig cuam tshuam.

Phau ntawv Bosch BMP280

Kauj ruam 2: BMP180 Versus BMP280

BMP180 piv rau BMP280
BMP180 piv rau BMP280

Cov ntaub ntawv los sib piv BMP280 sensor nrog BME280 sensor.

Kauj Ruam 3: Cov Npe Kho Vajtse

Cov Khoom Kho Khoom Siv
Cov Khoom Kho Khoom Siv
Cov Khoom Kho Khoom Siv
Cov Khoom Kho Khoom Siv
Cov Khoom Kho Khoom Siv
Cov Khoom Kho Khoom Siv
  • 1 Arduino Uno Pawg Thawj Coj
  • 3 module BMP280 breakout board sensor
  • 1 module PCF8574 (I2C) pawg thawj coj
  • 1 LCD LCM1602 (16x2) zaub
  • 1 protoboard
  • 35 jumper xov hlau

Kauj Ruam 4: Tsim Circuit Court

Tsim lub Circuit
Tsim lub Circuit
Tsim lub Circuit
Tsim lub Circuit

Rau peb BMP280, lub Circuit Court mus raws li hauv qab no:

Uno pin ……………………………………………………………………………………….. BMP280 (1) pinD13 SCK (Serial Clock, tso tawm los ntawm tus tswv) ………. SCLD12 MISO (Master in Slave OUT) …………………………… SDOD11 MOSI (Master OUT Slave IN) ………………………….. SDAD10 SSn (Qhib Xaiv) ………… ……………………………………. CSB

Uno pin ……………………………………………………………………………………….. BMP280 (2) pinD13 SCK (Serial Clock, tso tawm los ntawm tus tswv) ………. SCLD12 MISO (Master in Slave OUT) …………………………… SDOD11 MOSI (Master OUT Slave IN) ………………………….. SDAD9 SSn (Qhib Xaiv) ………… …………………………………………. CSB

Uno pin ……………………………………………………………………………………….. BMP280 (3) pinD13 (SCK Serial Clock, tso tawm los ntawm tus tswv) ………. SCLD12 (MISO Master in Slave OUT) …………………………. SDOD11 (MOSI Master OUT Slave IN) …………………………… SDAD8 SSn (Qhib Xaiv) …………… ……………………………………. CSB

*Txhua VCC thiab GND los ntawm BMP280 txuas hauv 3.3V ntawm Arduino lub zog lossis protoboard zog module.

Rau LCD LCM1602 zaub thiab PCF8574 I2C module, Circuit Court mus raws li hauv qab no:

a Muab LCD thiab PCF8574 tso rau ntawm lub qhov rooj raws li qhia hauv daim duab.

b. Jumper PCF8574 nrog Uno analog pins:

Uno pin ………………………………. PCF8574 pinA4 ……………………………………….. SDAA5 ……………………………………….. SCL

VCC thiab GND los ntawm PCF8574 txuas hauv 5V ntawm Arduino lub zog lossis cov qauv hluav taws xob tiv thaiv.

Nco tseg: Yog tias koj siv tus qauv tiv thaiv lub hwj chim, koj yuav tsum txuas nrog Arduino Gnd nrog lub protoboard Gnd.

Kauj ruam 5: Sketch

Sau ntawv:

  1. - Cov duab no yuav muaj teeb meem nruab nrab.
  2. - Daim Sketch no xav tau cov tsev qiv ntawv hauv qab no los teeb tsa ntawm Arduino:

    • LiquidCrystal_I2C.h
    • Adafruit_BMP280.h
    • Adafruit_Sensor.h
    • SPI.h

Download tau daim duab…

Pom zoo: