Cov txheej txheem:

RPIEasy - RPI Raws Tus Ntaus Multisensor: 6 Kauj Ruam
RPIEasy - RPI Raws Tus Ntaus Multisensor: 6 Kauj Ruam

Video: RPIEasy - RPI Raws Tus Ntaus Multisensor: 6 Kauj Ruam

Video: RPIEasy - RPI Raws Tus Ntaus Multisensor: 6 Kauj Ruam
Video: Часы G-Shock до 250 долларов-15 лучших часов Casio G до 250 доллар... 2024, Kaum ib hlis
Anonim
RPIEasy - RPI Raws Li Multisensor Device
RPIEasy - RPI Raws Li Multisensor Device

Yog tias leej twg npaj los tsim qee qhov DIY sensors, tom qab ntawd dhau mus rau nrov ESP8266 qhov pheej yig thiab qis noj "Raspberry Pi Zero W" qauv kuj yog qhov kev xaiv ntau.

RPI Zero W tus nqi kwv yees li 10USD thiab nws lub zog siv yuav luag yog 1W. Txawm li cas los nws tsuas muaj ib tus tub ntxhais CPU tab sis nws muaj ntau dua li txaus rau tuav ntau lub cim ntawm nws 40 tus pin GPIO uas zoo ib yam li ntawm RPI2/3/4. Nws kuj tseem muaj kev sib txuas WiFi thiab Bluetooth 4.0 cov qauv, yog li piv txwv li lub rooj vag BLE tuaj yeem tsim nrog nws.

Yog tias koj tuaj yeem txuas qee lub ntsuas hluav taws xob mus rau GPIO tab sis tsis muaj ntau qhov txuj ci los yog koj tsis xav sau cov cai tshiab rau txhua lub cuab yeej tshiab, muaj cov lus daws yooj yim, hu ua RPIEasy.

RPIEasy yog Python3 raws txoj haujlwm rau Debian/Raspbian raws cov khoos phis tawj, feem ntau yog tsom rau Raspberry Pi, tab sis qee qhov haujlwm kuj tseem muaj nyob hauv PC yooj yim. RPIEasy sau cov ntaub ntawv los ntawm cov cuab yeej txuas rau nws thiab xa mus rau ib tus neeg siv khoom siv hluav taws xob hauv tsev hauv tsev, dhau los ntawm HTTP/UDP/MQTT - txoj hauv kev tuaj yeem xaiv hauv Cov Ntawv Qhia Tswj. RPIEasy tau sib xws nrog ESPEasy nto moo (rau ESP8286) firmware, thiab GUI kuj zoo ib yam rau nws, qhov tseeb RPIEasy tuaj yeem koom nrog ESPEasy P2P UDP phooj ywg network.

Tam sim no cov cuab yeej/ntsuas hom hauv qab no tuaj yeem raug ntxiv los ntawm kev siv tus phooj ywg webGUI rau RPIEasy:

  • Cov hloov pauv digital (PIR, Lub qhov rooj qhib lub ntsej muag, thiab lwm yam …)
  • DS18b20 kub
  • DHT22 kub thiab av noo
  • PCF8591 ADC/DAC
  • Wiegand RFID nyeem ntawv
  • MCP23017 GPIO txuas ntxiv
  • BH1750 lub teeb pom kev zoo
  • LCD zaub (I2C)
  • HC-SR04 ultrasonic ntau yam sensor
  • Si7021/HTU21D kub thiab av noo
  • TLS2561 lub teeb pom kev zoo
  • PN532 Mifare/NFC nyeem ntawv (I2C)
  • PCF8574 GPIO txuas ntxiv (I2C)
  • PCA9685 PWM extender (I2C)
  • OLED zaub (I2C)
  • MLX90614 IR ntsuas kub (I2C)
  • INA219 DC qhov ntsuas tam sim no (I2C)
  • ADS1015/ADS1115 ADC
  • BMP280/BME280 kub
  • NeoPixel/WS2812 addressable LED
  • MH-Z19 CO2 sensor
  • AM2320 kub
  • MPR121 capacitive kov sensor (I2C)
  • 7 ntu TM1637 zaub
  • RF433Mhz RX/TX (yooj yim GPIO)
  • APDS9960 piav tes piav taw
  • VL53L0X LIDAR ntau qhov ntsuas
  • MAX44009 kub
  • MCP9808 kub
  • MCP4725 DAC
  • Stepper lub cev muaj zog (28BYJ-48)
  • (V-) USB Txuas
  • USB Temper kub sensor
  • Xiaomi BLE Mijia ntsuas kub thiab av noo
  • Xiaomi BLE Mi Flora paj saib xyuas
  • DS18b20 los ntawm serial-USB

Kauj ruam 1: Sib dhos

Los ua ke
Los ua ke
Los ua ke
Los ua ke

Cia peb pib nrog teeb tsa yooj yim, siv ntsuas kub thiab lub teeb pom kev zoo:

  • Raspberry Pi Zero W.
  • 8GB/16GB Class10 microSD nco daim npav
  • Micro USB 5V2A Phab Ntsa Charger
  • DHT22 ntsuas kub thiab av noo
  • 4.7 kOhm resistor
  • BH1750 lub teeb pom kev zoo
  • qee cov jumper cables
  • lub thawv yas

Sib sau ua ke raws li qhov fritzing.

Kauj ruam 2: Nruab OS

Kev teeb tsa OS
Kev teeb tsa OS
  1. Rub tawm Raspbian Lite cov txheej txheem ua haujlwm duab
  2. Rub tawm Etcher
  3. Sau Lite OS duab nrog Etcher rau 8-16GB SD card

Tom qab txheej txheem ua tiav hloov cov ntaub ntawv ntawm SD card "etc/wpa_supplicant/wpa_supplicant.conf" kom zoo ib yam:

ctrl_interface = DIR =/var/run/wpa_supplicant GROUP = netdevupdate_config = 1country = HUnetwork = {ssid = "YOUR_OWN_WIFI_AP_NAME" scan_ssid = 1 psk = "YOUR_WIFI_AP_PASSWORD" key_mgmt = WPA-PSK}

4. Muab daim npav SD tso rau hauv RPI lub cim xeeb, ntsaws MicroUSB lub zog txuas hluav taws xob rau nws "PWR IN" txuas thiab yog tias peb ua txhua yam raws li txoj cai, dua li RPI pib thiab nkag tau los ntawm SSH. (IP chaw nyob yog sib sau los ntawm DHCP server, yog li txheeb xyuas koj lub router DHCP xaum rau qhov siv IP chaw nyob)

5. Thaum xub pib lub npe siv yog pi thiab tus password yog raspberry.

Kauj Ruam 3: RPIEasy Installation

RPIEasy Installation
RPIEasy Installation
RPIEasy Installation
RPIEasy Installation

Thawj (yeem) kauj ruam yog hloov kho koj li system:

sudo apt-tau hloov tshiab sudo apt-tau hloov tshiab

Tom qab ntawd teeb tsa cov pob khoom xav tau:

sudo apt install python3-pip screen alsa-utils wireless-tools wpasupplicant zip unzip gitsudo pip3 install jsonpickle

Yog tias koj lub system tsis muaj "ifconfig" hais kom ua nruab nws kuj:

sudo apt nruab net-cuab yeej

Tom qab ntawd rub tawm RPIEasy los ntawm github rau cov npe tiag thiab pib:

git clone https://github.com/enesbcs/rpieasy.gitcd rpieasysudo./RPIEasy.py

Yog tias tsis muaj dab tsi siv chaw nres nkoj 80 tseem tsis tau, tam sim no GUI muaj los ntawm chaw nres nkoj 80 nrog lub vev xaib, yog tias nws tsis muaj qhov program yuav sim siv 8080 ces 8008. (nws sau tus lej chaw nres nkoj ntawm lub console thaum pib)

Kauj Ruam 4: RPIEasy Hardware Settings

RPIEasy Kho Vajtse Chaw
RPIEasy Kho Vajtse Chaw
RPIEasy Kho Vajtse Chaw
RPIEasy Kho Vajtse Chaw
RPIEasy Kho Vajtse Chaw
RPIEasy Kho Vajtse Chaw

Ntawm nplooj ntawv kho vajtse nplooj ntawv koj tuaj yeem pab kom "RPIEasy autostart pib ntawm khau raj" xaiv nrog lub npov yooj yim ces nias lub pob Xa.

Daim ntawv thov no yog nab hab sej raws li muaj ntau qhov kev cia siab uas tuaj yeem pom thiab teeb tsa ntawm Plugin & tswj kev vam khom nplooj. Kev teeb tsa tuaj yeem pib los ntawm txhaj rau kab ntawv kab ntawv, thov ua siab ntev, cov txheej txheem yuav siv sijhawm ob peb feeb nyob ntawm cov lej thiab qhov nyuaj!

Tom qab ntawd nws yuav yog lub tswv yim zoo los tshuaj xyuas cov cuab yeej teeb tsa ntawm Pinout & Ports. Nco ntsoov tias I2C tau qhib (rau lub teeb pom kev zoo) thiab GPIO 22 tus pin hom yog "Cov tswv yim" rau DHT. (Reboot hais kom ua muaj nyob ntawm Cov cuab yeej ntawv qhia zaub mov)

Kauj Ruam 5: RPIEasy Controllers

RPIEasy Tswj
RPIEasy Tswj

Raws li koj tab tom ua lub ntsuas koj yuav xav teeb tsa qee yam ntawm Tus Tswj ntawm Cov Tswj Cov Ntawv Qhia: nws tuaj yeem yog Domoticz HTTP/MQTT, Generic UDP, ESPEasy P2P lossis Generic MQTT (rau HA, OpenHab, thiab lwm yam..)

Kauj Ruam 6: RPIEasy Devices

RPIEasy Devices
RPIEasy Devices
RPIEasy Devices
RPIEasy Devices

Thiab thaum kawg: cov cuab yeej tuaj yeem ntxiv ntawm Devices menu, muaj 48 lub cuab yeej muaj peev xwm ua tau, yog tias nws tsis txaus thov qhib qhov teeb meem github thiab nws yuav raug tsa.:)

Nyem rau Kho kom raug khawm, xaiv qhov tsim nyog DHT22 thiab BH1750 plugins thiab teeb tsa tsis raws li qhov fritzing. DHT22 1st GPIO yog GPIO22 thiab kev txheeb xyuas feem ntau yog lub tswv yim zoo vim tias qhov ntsuas no zoo heev ntawm lub sijhawm raug. (nco ntsoov tias DHT sib txuas lus nrog ib lub xov hlau, tab sis nws tsis yog 1-Hlau sib xws!) BH1750 yog I2C sensor, I2C chaw nyob tuaj yeem xaiv los ntawm kev xaiv, lub neej ntawd yog 0x23, kev txheeb xyuas tsis tas yuav tsum tau raws li I2C kev sib txuas lus yog khov heev

Nws tuaj yeem raug xaiv uas tus tswj hwm twg, uas IDX thiab qhov sib nrug ntawm qhov nyeem ntawv yuav tsum tau xa. Daim teb Formula yog sib xws nrog EasyFormula, thiab ESPEasy cov cai hauv cheeb tsam tuaj yeem teev nyob rau ntawm Cov Cai Ntawv qhia zaub mov.

Nov yog zaj dab neeg luv luv ntawm kev ua RPI raws tus lej ntsuas, muaj ntau txoj kev xaiv thiab kev sib txuas, tsis txhob sim sim lawv hauv lub siab ntawm DIY!

Pom zoo: