Cov txheej txheem:

Ntse Romote Tsheb Raws Arduino: 5 Kauj Ruam
Ntse Romote Tsheb Raws Arduino: 5 Kauj Ruam

Video: Ntse Romote Tsheb Raws Arduino: 5 Kauj Ruam

Video: Ntse Romote Tsheb Raws Arduino: 5 Kauj Ruam
Video: Yog ntuj tsis pab ntshe kuv tuag lawm 8/6/2018 2024, Lub Xya hli ntuj
Anonim
Ntse Romote Tsheb Raws Arduino
Ntse Romote Tsheb Raws Arduino

Txoj haujlwm no yog ua raws Arduino UNO pawg thawj coj txhim kho los ua lub tsheb ntse. Lub tsheb muaj Bluetooth tswj tsis tau, ua kom tsis txhob muaj teeb meem, tswb tswb thiab lwm yam haujlwm, thiab nws yog plaub-lub tsheb tsav tsheb, yooj yim tig.

Kauj Ruam 1: Yuav Cov Khoom Uas Koj Xav Tau

Peb yuav tsum tau yuav Arduino core board thiab nthuav lub rooj tsavxwm, ntxiv rau lub suab nrov, L298N lub cev muaj zog tsav tsav, BT-04A Bluetooth module, DC lub cev muaj zog, tus tuav lub roj teeb, thiab lwm yam. Acrylic daim hlau kom zoo rau lub tsheb no tsis yooj yim nrhiav, yog li ntawv txuas hauv qab no. Koj tuaj yeem nrhiav lwm yam yooj yim hauv khw.

Nov yog qhov txuas rau acrylic board hauv Taobao:

Lub software siv Bluetooth debugging tus pab tswj lub tsheb, thiab cov peev txheej tseem yuav txuas nrog.

Kauj Ruam 2: Tsim Cov Qauv Kho Vajtse

Tsim Cov Qauv Txheej Txheem
Tsim Cov Qauv Txheej Txheem
Tsim Cov Qauv Txheej Txheem
Tsim Cov Qauv Txheej Txheem

Peb yuav tsum tau teeb tsa tus qauv hauv txoj haujlwm raug ntawm daim phaj acrylic. Raws li cov phaj acrylic yuav muaj ntau qhov ntau tshaj qhov peb xav tau, tsuas yog them nyiaj rau yuav ua li cas txhawm rau txhim kho nws hauv txoj hauv kev yooj yim tshaj plaws kom tsis txhob rov ua dua.

Vim tias kev teeb tsa lub cev muaj zog yog qhov yooj yim thiab tsau, peb tsom mus rau kev teeb tsa ntawm kev tswj hwm Circuit Court saum toj no. Bluetooth thiab lub rooj tsav xwm tseem ceeb yuav tsum tau siv los txais cov cim. Nws yog qhov tsim nyog tshaj kom muab lawv tso rau tom qab ntawm lub tsheb. Lub hauv paus roj teeb thiab roj teeb siv qhov chaw loj. Txhawm rau kom ntseeg tau lub tsheb sib npaug, lawv tau muab tso rau hauv txoj haujlwm nruab nrab, thiab lub tshuab tsav lub cev muaj zog thiab cov teeb meem zam kev zam tau muab tso rau pem hauv ntej raws li qhia hauv daim duab.

Daim duab hauv qab no qhia pom cov qauv teeb tsa los ntawm hauv qab thiab sab saum toj feem. Thawj daim duab qhia pom qhov xwm txheej ntawm Circuit hauv qab thaum lub cav tsis tau teeb tsa. Them sai sai rau kev yuav ntau cov ntsia hlau thiab cov ncej tooj liab nrog qhov siab sib txawv, yog li txhawm rau txhawm rau los ntawm qhov chaw. Daim duab thib ob yog qhov xwm txheej ntawm lub tsheb thaum nws tau teeb tsa tiav. Koj tuaj yeem pom qhov pom kev tsav lub cev muaj zog, roj teeb, thiab lwm yam.

Kauj Ruam 3: Tham Txog Bluetooth

Tham Txog Bluetooth
Tham Txog Bluetooth

Bluetooth module feem ntau siv hauv thaj tsam ntawm kev tswj hwm wireless nyob deb. BT-04A Bluetooth module tau xaiv hauv txoj haujlwm no. Zoo li HC series Bluetooth module, BT series Bluetooth module feem ntau siv, tab sis nws tus nqi pheej yig dua.

Cov qauv no feem ntau yog siv hauv thaj chaw luv luv cov ntaub ntawv xa xov wireless. Nws tuaj yeem txuas tau yooj yim nrog Bluetooth ntaus ntawv ntawm PC, thiab tseem tuaj yeem sib txuas lus cov ntaub ntawv ntawm ob tus qauv. Kev siv tus qauv no tuaj yeem zam kev sib txuas cable txuas thiab tuaj yeem hloov pauv ncaj qha chaw nres nkoj cable.

Cov qauv no tau tswj hwm los ntawm 'AT' cov lus txib teeb tsa zoo li Esp8266 WIFI module, GSM module. Txhawm rau pab txhawb kev sib txuas ntawm cov khoos phis tawj sib txawv, peb ua lub tsheb ua lub hom phiaj tseem ceeb, thiab khoos phis tawj thiab xov tooj ntawm tes nrog Bluetooth ntawm lub tsheb kawg ua haujlwm kom tau txais kev tswj hwm ntawm lub tsheb ntse. Lub khoos phis tawj sab Bluetooth debugging tus pab yog zoo heev, ntau cov lus qhia ua haujlwm tau raug kaw rau hauv cov nyees khawm, peb tsuas yog xav tau cov lus qhia tswj. Nco ntsoov tias ua ntej xa cov lus txib tswj hwm, lub khoos phis tawj yuav tsum txuas nrog lub tsheb Bluetooth ua ntej. Cov txheej txheem no yuav raug kaw. Sim ob peb zaug ntxiv, thiab lub xov tooj ntawm tes tau yooj yim dua.

Lub xov tooj ntawm tes tau txuas nrog cov theem no rau kev siv nkaus xwb, thiab khoos phis tawj bluetooth chaw nres nkoj debugging software tau pom zoo.

Kauj ruam 4: Software Coding

Software Coding
Software Coding
Software Coding
Software Coding
Software Coding
Software Coding

Arduino kev txhim kho ib puag ncig yog qhib qhov chaw thiab tuaj yeem rub tawm ncaj qha los ntawm Is Taws Nem. Cov kauj ruam tseem ceeb hauv txoj haujlwm yog piav qhia hauv qab no.

Ua ntej tshaj plaws, peb piav qhia tus lej tseem ceeb ntawm lub rooj tswj hwm macroscopically kom nkag siab yooj yim thiab ua haujlwm tom ntej.

Tom qab ntawd pib lub cav ua haujlwm, raws li qhia hauv daim duab hauv qab no, yog kev ua haujlwm pib ua ntej. Nco ntsoov tias lub cav tau tsav los ntawm ob tus ncej, ib qho siab thiab ib qho qis, thiab rov ua dua. Peb feem ntau siv txoj cai no los tswj lub cav.

Kev txav sab laug-sab xis yog qhov tshwj xeeb. Txhawm rau ua kom tig sab laug-sab xis kom lub tsheb yuav tsis txav mus tom ntej ntau, peb taug txoj kev ntawm lub log sab laug rov qab thiab lub log sab xis rau pem hauv ntej kom tig sab laug. Tib yam mus rau txoj cai tig. (txij li cov txiaj ntsig ntawm kev siv cov teeb liab analog tsis zoo heev, nws xav tau kev debugging tas li, thiab cov khoom siv digital ncaj qha siv ntawm no.)

Tom qab tau txais cov lus txib los ntawm chaw nres nkoj txuas, lub tsheb tuaj yeem ua haujlwm sib xws raws li cov lus txib. Daim duab qhia pom kev ua haujlwm kom tau txais cov lus txib ua ntej. Ib qho laj thawj vim li cas peb xaiv BT-04A Bluetooth module yog tias nws tau muab kaw rau hauv USART, nrog tsuas yog plaub tus pin ntawm TX, Rx, VCC thiab GND, uas yooj yim heev rau kev debugging thiab nkag mus

Kauj ruam 5: Txheej txheem cej luam

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

Thaum kawg, xa cov program program code thiab cov duab ntawm lub tsheb hauv cov xwm txheej sib txawv. Nov yog daim phiaj xwm ntawm txoj haujlwm, zoo siab los sib tham ua ke thiab txhim kho txoj haujlwm no.

Pom zoo: