Cov txheej txheem:
- Kauj Ruam 1: Tshooj Kho Vajtse
- Kauj ruam 2: Software Tshooj
- Kauj Ruam 3: Kauj Ruam 3: Cov ntawv txuas nrog
Video: Lub Teeb Xyoob (Txuas Teeb): 3 Kauj Ruam
2024 Tus sau: John Day | [email protected]. Kawg hloov kho: 2024-01-30 09:27
Nyob zoo thiab txais tos!
Lub teeb xyoob yog lub teeb sib txuas uas teeb thaum lub ceeb toom tau txais ntawm lub xov tooj Android uas nws tau txuas nrog. Lub hom phiaj ntawm cov lus qhia no yog los qhia koj txog theem tsim ntawm txoj haujlwm: los ntawm cov cuab yeej kho vajtse, mus rau Bluetooth Tsawg Zog (BLE) txuas thiab Android daim ntawv thov tsim.
Rau peb lub teeb, peb xaiv cov yas cog rau qhov tsim kom zoo nkauj tsim. Txog qhov haujlwm no, cov ntawv ceeb toom uas tau tshwm sim yog los ntawm cov ntawv thov hauv qab no: hu, sms/mms, facebook, tub txib, instagram, whatsapp ang gmail. Ib lub teeb xim yog ntaus nqi rau txhua hom kev ceeb toom.
Rau qhov haujlwm no, koj yuav xav tau:
- UC nrog kev sib xyaw BLE module: nFR51822 RedBearLab
- 3 NeoPixel Nplhaib (12 RGB LEDs)
- Ib lub Android smartphone
- Hauv Studio
Txhua qhov kev ceeb toom muaj qhov tshwj xeeb tshwj xeeb, nyob ntawm nws qhov tseem ceeb. Piv txwv li, kev ceeb toom hu tuaj yog qhov tseem ceeb tshaj li kev ceeb toom Facebook. Hauv qhov xwm txheej ntawd, LEDs xim yuav cuam tshuam nrog kev ceeb toom hu tuaj.
Lub xov tooj ntawm tes uas peb tsim daim ntawv thov yog Samsung Galaxy A5.
Kauj Ruam 1: Tshooj Kho Vajtse
Peb architecture yog yooj yim heev.
Txuas NeoPixel Ring pins rau nRF51822 pawg thawj coj raws li hauv qab no:
- Inout Cov ntaub ntawv tus pin ntawm NeoPixel Ring rau qhov chaw nres nkoj 3 ntawm uC.
- Vcc ntawm NeoPixel Ring rau 3.3V ntawm uC.
- GND ntawm NeoPixel Ring rau GND ntawm uC.
Koj tuaj yeem pom tias peb tsis siv Cov Ntaub Ntawv Tso Tawm tus pin ntawm NeoPixel Ring. Qhov ntawd yog vim cov ntaub ntawv Input pins ntawm peb NeoPixel Rings peb siv hauv txoj haujlwm no txhua tus txuas nrog tib lub chaw nres nkoj ntawm nRF51822 board (tus pin 3).
Kauj ruam 2: Software Tshooj
1. Kev Sib Txuas Bluetooth Tsawg Zog:
Hauv kev sib txuas lus BLE, tus neeg rau zaub mov (uas yog nyob rau hauv peb cov ntaub ntawv uC) thiab cov neeg siv khoom (lub xov tooj ntawm tes) sib pauv cov ntaub ntawv siv GATT kev sib pauv. Hauv cov kev lag luam ntawd, cov ntaub ntawv tau teeb tsa hierarchically hauv ntu hu ua cov kev pabcuam, uas pab pawg cov tswv yim cuam tshuam nrog cov neeg siv cov ntaub ntawv hu ua yam ntxwv. Hauv peb qhov xwm txheej, cov ntaub ntawv ntim khoom tau yooj yim vim peb tsuas muaj ib cov ntaub ntawv dhau los ntawm tus neeg siv khoom mus rau server (saib daim duab saum toj no).
- ntawm tus neeg rau zaub mov: Txhawm rau siv tau nrf51822 pawg thawj coj los ua BLE server, xub nruab "BLEPeripheral.h" lub tsev qiv ntawv ntawm Arduino IDE. Lub tsev qiv ntawv no muab kev npaj ua kom siv tau zoo rau kev tsim cov kev pabcuam thiab tus yam ntxwv thiab tshaj tawm.
- ntawm cov neeg siv khoom: Txhawm rau pib BLE kev sib txuas lus hauv Android Studio, xub teeb tsa BLE kev tso cai hauv Manifest file. Tom qab ntawd, hauv cov ntaub ntawv activity_main.xml, ntxiv 4 khawm: luam theej duab, nres luam theej duab, txuas thiab txiav tawm uas yuav tso cai rau daim ntawv thov txhawm rau tshuaj xyuas BLE cov cuab yeej nyob ze, nres qhov scan, txuas thiab txuas mus rau lub cuab yeej. Hauv cov ntaub ntawv main_activity.java, siv cov haujlwm uas cuam tshuam nrog cov nyees khawm yav dhau los: startScanning (), stopscanning (), connectToDeviceSelected (), disconnectDeviceSelected (). Thaum kawg, siv cov haujlwm rov qab uas tau hu thaum lub xeev hloov pauv tus neeg siv khoom..
2. Kev ceeb toom kev tswj hwm
- ntawm cov neeg siv khoom (ntawm Android Studio): Txhawm rau mloog cov ntawv ceeb toom los ntawm lub xov tooj ntawm tes, siv lub mloog lus ceeb toom uas tau qhib thaum muaj kev ceeb toom tshwm sim hauv kab xwm txheej. Tus neeg mloog daim ntawv ceeb toom no yuav xa "lus", hu ua lub hom phiaj, mus rau lub luag haujlwm tseem ceeb thaum ceeb toom tshaj tawm lossis tshem tawm. Qhov "xov xwm" no muaj cov cai ceeb toom uas pab txheeb xyuas daim ntawv thov uas tshaj tawm qhov kev ceeb toom. Txhawm rau ua cov ntawv ceeb toom hauv lub luag haujlwm tseem ceeb, tsim kom muaj tus txais xov tooj cua uas yuav tau txais cov lus los ntawm tus neeg mloog ceeb toom. Tom qab ntawd, nyob ntawm tus lej ceeb toom, tus yam ntxwv sib txawv raug xa mus rau tus neeg rau zaub mov.
- ntawm tus neeg rau zaub mov (ntawm Arduino IDE): kev ceeb toom uas muaj qhov muaj txiaj ntsig tshaj plaws tau tshwm sim.
Kauj Ruam 3: Kauj Ruam 3: Cov ntawv txuas nrog
Ntawm no, koj yuav pom txhua qhov chaws qhov chaws.
Pom zoo:
Ua Kev Sib Txuas Hauv Is Taws Nem Txuas Txuas Lub Stereo: 6 Kauj Ruam (nrog Duab)
Ua Internet Txuas Txuas Lub Koob Yees Duab: Thaum kuv qhib lub xov tooj cua thaum tsav tsheb kuv tig mus rau kuv lub tsev kawm ntawv qib siab hauv xov tooj cua chaw nres tsheb 90.7 KALX. Dhau xyoo thiab ntau qhov chaw kuv tau nyob kuv ib txwm mloog cov xov tooj cua hauv tsev kawm qib siab. Ua tsaug rau lub zog hauv internet tam sim no kuv tuaj yeem mloog
Txuas Txuas Txuas Txuas: 5 Cov Kauj Ruam
Txuas Txuas Lub Sijhawm: Nyob Zoo! Hauv qhov kev qhia no koj yuav pom yuav ua li cas txuas nrog ib qho khoom siv Arduino sib xws, nruab nrog WiFi, rau REST APIs! Qhov no siv GitKraken Glo Board webapp los tsim cov laug cam, kab & daim npav los npaj khoom! Qee qhov kev paub ntawm yuav ua li cas pej xeem
Kev Sib Txuas Txuas Txuas Txuas Siv Bluefruit: 4 Cov Kauj Ruam
Kev Sib Txuas Tsis Sib Txuas Siv Bluefruit: Nov yog cov lus qhia yooj yim los ntawm kauj ruam qhia los hloov koj cov xov hlau nrog bluetooth tsis muaj zog txuas: Nws coj kuv ib pliag los daws qhov no vim tias tsis muaj cov ntaub ntawv hais txog kev ua qhov no nrog bluetooth niaj hnub tsis muaj zog thev naus laus zis raws li Bluefrui
EZ Kev Sib Txuas Txuas Txuas Txuas Ntxiv - Tsis Muaj Tus Kheej! (CSRC-311): 7 Kauj Ruam
EZ Kev Sib Txuas Txuas Txuas Txuas Ntxiv - Tsis Muaj Tus Kheej! (CSRC-311): Tsis ntev dhau los ntawm Azamom.com (thov txim, tam sim no tau muag tawm) Kuv tau hla qhov kev pom zoo zoo ntawm Common Sense RC CSRC-311 tus qauv-siv servos.Noj zoo, Kuv xav hloov qee yam ntawm tsis tu ncua kev sib hloov. Txoj kev kuv tuaj nrog yog yooj yim heev thiab xav tau
PoochPak: Lub Xov Tooj Txuas Txuas Txuas Ntse Ntse Dog: 4 Kauj Ruam
PoochPak: Cellular Connected Smart Dog Vest: Hauv kev siv tshuab, peb feem ntau tsom mus rau engineering tib neeg-hauv-tus-lub voj kom tau txais txiaj ntsig ntawm kev paub zoo ntawm lub khoos phis tawj thiab tib neeg lub siab. Tab sis cov dev muaj cov txuj ci ua rau lawv zoo heev rau qee yam haujlwm uas tib neeg ua tsis tau zoo