Cov txheej txheem:

Hlau Tswj Cov Neeg Hlau Caj Npab: 31 Kauj Ruam
Hlau Tswj Cov Neeg Hlau Caj Npab: 31 Kauj Ruam

Video: Hlau Tswj Cov Neeg Hlau Caj Npab: 31 Kauj Ruam

Video: Hlau Tswj Cov Neeg Hlau Caj Npab: 31 Kauj Ruam
Video: Tus Neeg Ruam - R-Lin Thoj | New Song [ Official MV ] Nkauj Tawm Tshiab 2023 Hmong Song 2023 2024, Kaum ib hlis
Anonim
Hlau Tswj Cov Neeg Hlau Caj Npab
Hlau Tswj Cov Neeg Hlau Caj Npab

Nov yog kev qhia yuav ua li cas thiaj ua tau cov neeg hlau caj npab tswj los ntawm cov xov hlau. Qhov zoo ntawm kev siv xov hlau yog tias koj txhais caj npab sib zog thiab koj tuaj yeem muaj tag nrho koj lub cav nyob hauv qab ntawm koj txhais caj npab, ua kom lub tsev thiab kho kom yooj yim dua. Nov yog daim vis dis aus ntawm caj npab hauv kev nqis tes ua. Kuv npaj yuav ntxiv ib tus claw rau yav tom ntej yog li nws tuaj yeem khaws cov khoom thiab tsis yog thawb lawv ib puag ncig.

3D Luam Ntawv:

Ntawm no thiab Ntawm no

Khoom siv

6 Servo Motors (MG995)

Arduino Ib

Kwv yees li 6 meters ntawm cov yas coated hlau xaim (0.5mm)

Lub thawv 23x33x10 (tej zaum yuav nqaim, yuav tsum tsis txhob luv)

Ntoo ntoo 33x10

Ceev thiab Bolts

Cov yeeb nkab 14 cm (qhov no xav tau los qhia cov hlua)

4 L-Khawm

5-volt adapter

27-txoj kev davhlau ya nyob twg

Creadboard xov hlau

Cov Ntawv Sau 3D (Tsis yog tsim los ntawm kuv, txuas rau cov ntsiab lus hauv qhov kev piav qhia):

3 “Bolts”

2 “Qeb 1”

1 "Ntu 2"

2 “Ntu 3”

1 Base Connector

Kauj Ruam 1: Luam tag nrho 3D Cheeb Tsam

Tej zaum koj yuav xav tau kev txhawb nqa rau qhov ntsia liaj qhov rooj thiab arches tab sis nco ntsoov tsis ntxiv kev txhawb nqa rau lub cev ntawm koj cov khoom; qhov no yuav kaw qhov xaim me me thiab koj yuav tsum tau ua qhov tshiab

Kauj Ruam 2: (Tsis teb los tau) Txuas Cov Ntoo Ntoo rau hauv qab ntawm koj lub thawv kom ntxiv dag zog rau nws

Kuv lub thawv tau zoo nkauj tsis muaj zog, koj li yuav tsis yog

Kauj Ruam 3: Ntsuas thiab Txiav Ntoo Ntoo kom haum rau lub thawv

Kauj Ruam 4: Kos rau Txoj Haujlwm ntawm Cov Tsav Tsheb

xyuas kom tsis muaj caj npab kov ib leeg

Kauj Ruam 5: Kos rau Txoj Haujlwm ntawm Cov Khawm thiab Cov Yeeb Nkab

Kos rau Txoj Haujlwm ntawm Cov Khawm thiab Cov Yeeb Nkab
Kos rau Txoj Haujlwm ntawm Cov Khawm thiab Cov Yeeb Nkab

Cov yeeb nkab yuav tsum tau muab tso rau ib ncig ib centimeter pem hauv ntej ntawm lub qhov

Kauj Ruam 6: Laum Lub Qhov rau Cables Los Ntawm Koj Lub Box (USB thiab Lub Hwj Chim)

Laum Lub Qhov rau Cov Cables Los Ntawm Koj Lub Box (USB thiab Lub Hwj Chim)
Laum Lub Qhov rau Cov Cables Los Ntawm Koj Lub Box (USB thiab Lub Hwj Chim)

Kauj Ruam 7: Laum thiab Pom Txhua Qhov Cim Cim

Laum thiab Pom Txhua Qhov Cim Cim
Laum thiab Pom Txhua Qhov Cim Cim

Kauj Ruam 8: Txuas cov Motors thiab Yeeb Nkab rau Plank

Kauj Ruam 9: Txuas Plank rau Lub Thawv Nrog L-Brackets

Kauj Ruam 10: Coj Koj Cov Terminal Blocks thiab Muab Cov Hluav Taws Xob Ua Ke

Coj koj lub davhlau ya nyob twg thaiv thiab txuas cov hlua ua ke
Coj koj lub davhlau ya nyob twg thaiv thiab txuas cov hlua ua ke

Kauj Ruam 11: Txiav Qhov Kawg Ntawm Cov Hluav Taws Xob Hluav Taws Xob thiab Tshem Cov Hluav Taws Xob

Kauj Ruam 12: Txheeb Xyuas thiab Kos Npe Ntxiv thiab Raug Tshem Tawm

Kauj Ruam 13: Txuas Cov Hluav Taws Xob mus rau Terminal Blocks Yog li Txhua Qhov + Servo Cov Xov Tooj thiab + Hlau Los Ntawm Cov Hluav Taws Xob Hluav Taws Xob tau txuas nrog, Tib yam mus rau - Cov Hluav Taws Xob

Txuas Cov Hluav Taws Xob mus rau Qhov Chaw Nres Tsheb kom Thiaj Li Txhua Qhov + Servo Cov Hluav Taws Xob thiab + Hlau Los Ntawm Cov Hluav Taws Xob Hluav Taws Xob tau txuas nrog, Tib yam mus rau - Cov Hluav Taws Xob
Txuas Cov Hluav Taws Xob mus rau Qhov Chaw Nres Tsheb kom Thiaj Li Txhua Qhov + Servo Cov Hluav Taws Xob thiab + Hlau Los Ntawm Cov Hluav Taws Xob Hluav Taws Xob tau txuas nrog, Tib yam mus rau - Cov Hluav Taws Xob

Kauj Ruam 14: Txiav Lub Taub Hau Tawm Ntawm Lub Caij Nyoog Hlau

Txiav Lub Taub Hau Tawm ntawm Breadboard Hlau
Txiav Lub Taub Hau Tawm ntawm Breadboard Hlau

Txuas qhov kawg ntawm daim kab xev xaim rau lub rho tawm lub dav hlau thaiv thiab tus pin kawg rau hauv tus pin hauv av hauv koj li arduino. Yog tias koj tsis ua qhov no lub cav yuav txav mus tsis raug yam tsis muaj kev tawm tswv yim.

Kauj Ruam 15: Laum Peb Qhov Hauv Qab Hauv Lub Thawv rau Cov Hluav Taws Xob Los Ntawm Koj Sab caj npab

Cov qhov yuav tsum sib phim mus txog qhov nyob hauv lub hauv paus txuas.

Kauj Ruam 16: Txuas lub hauv paus txuas rau lub thawv

Txuas lub hauv paus txuas rau lub thawv
Txuas lub hauv paus txuas rau lub thawv

Kauj Ruam 17: Siv Riam lossis Ntsia Cov Ntaub Ntawv los Ua Tus Hlau Grooves Deeper

Siv Riam lossis Ntsia Cov Ntaub Ntawv los Ua Tus Hlau Grooves Deeper
Siv Riam lossis Ntsia Cov Ntaub Ntawv los Ua Tus Hlau Grooves Deeper

Cov kab xaim rau cov ntsiab lus 2 thiab 3 yog ntiav dhau.

Kauj Ruam 18: Ua Lub Caj Npab

Tsim caj npab
Tsim caj npab

Ua caj npab raws li cov lus qhia ntawm no koj yuav xav tau ua cov ntu kom lawv haum

Kauj Ruam 19: Txhim Kho Kev Ua Haujlwm thiab Arduino

Ua thiab Arduino

Kauj Ruam 20: Muab Tshuaj Txhuam Cov Cai

Cov cai nyob hauv qab ntawm nplooj ntawv no

Kauj Ruam 21: Txuas Servo Control Pins rau Arduino

Txuas qhov Servo Control Pins rau Arduino
Txuas qhov Servo Control Pins rau Arduino

Kuv txuas thawj lub cav mus rau tus lej thib peb, lub cav thib ob mus rau tus lej thib plaub thiab lwm yam. Xyuas kom tseeb tias tus pin hauv av tseem txuas nrog rau lub davhlau ya nyob twg.

Kauj Ruam 22: Nias Tus Khawm Pib dua hauv Kev Ua, Qhov No Yuav Teeb Txhua Lub Caj Npab mus rau 90 Degrees

Kauj Ruam 23: Txhim Kho Lub Caj Npab Servo rau Lub Cev Tsav Tsheb

Kauj Ruam 24: Thim Cov Xov Tooj Los Ntawm Cov Caj Npab Kom Thiaj Li Tsis Muaj Kev Nyuaj Siab

Nco ntsoov tias koj xaim xov hlau hla ntau qhov raws li koj tuaj yeem ua tau, qhov no yuav tuav nws ib ntus thiab tshem tawm tau yooj yim.

Kauj Ruam 25: Xeem Caj Npab thiab Ceev lossis Loosen Cov Hlau Raws Li Xav Tau

Kauj Ruam 26: Kub Kov Cov Hluav Taws Xob rau Cov Cuab Yeej Siv Hluav Taws Xob kom nws ruaj khov

Kauj ruam 27: Sau ntawv

Sau ntawv
Sau ntawv

Kuv siv 0.5mm cov hniav nyiaj hniav kub hlau tab sis 0.4mm yuav tsum zoo. Tus qauv tsim thawj siv PVC hlau tab sis qhov tawg yooj yim heev thiab nyuaj rau ua haujlwm nrog.

Yog tias koj yuav txav caj npab hauv lub tsheb lossis tsheb kauj vab qhwv caj npab sib txuas hauv kab xev kom ntseeg tau tias lawv tsis tawm. Qhov no yog qhov tshwj xeeb tshaj yog rau ntu 1.

Thaum kuv pib qhov haujlwm no kuv xav tsis thoob vim li cas kuv tsuas tuaj yeem pom ib qho kev qhia yuav ua li cas thiaj ua caj npab tswj los ntawm cov xov hlau. Tam sim no kuv nkag siab tias vim li cas qhov no tsis yog txoj hauv kev ntau tshaj los ua caj npab nyiam ua haujlwm. Cov xov hlau qee zaum poob tawm ntawm lawv cov zawj thiab txhua yam zoo ib yam. Kuv tsis paub yog tias muaj teeb meem vim tias kuv tsis muaj kev paub ntau lossis yog tias tag nrho lub tswv yim muaj teeb meem txawm hais tias kuv paub tseeb tias nws yuav khov dua yog tias kuv paub tias kuv tau ua dab tsi.

Kauj ruam 28: Teeb meem

Cov hlau xaim raug kaw hauv cov ntawv luam tawm 3D:

Koj tau ntxiv kev txhawb nqa rau tag nrho cov ntsiab lus tsis yog tsuas yog lub qhov ntsia liaj qhov rooj. Ob qho rov sau cov ntsiab lus lossis qhib lub qhov nrog rab koob kub tiag tiag.

Qhov chaw nres nkoj COM raug kaw, koj tsis tuaj yeem sib tham nrog arduino:

Koj tus arduino yuav tsis lees txais USB 3 cov chaw nres nkoj (kuv tsis tau), koj tuaj yeem yuav lub USB 2 txuas txuas txuas lossis siv lub khoos phis tawj uas muaj USB 2 chaw nres nkoj

Txoj cai tsis ua haujlwm:

Ua raws cov ntawv qhia no thiab hloov kho nws kom ua koj tus lej

Ib feem ntawm caj npab tsis txav mus:

Cov xov hlau yuav tau tangled, txhawm rau txheeb xyuas qhov no tshem tawm cov servo caj npab tawm ntawm servo thiab sim rub cov xov hlau los ntawm txhais tes. Tshem cov xov hlau thiab yog tias nws tseem nyuaj rau rub cov xov hlau sim siv qee qhov WD-40 lossis cov roj nplua nyeem kom txav tau yooj yim dua

Kauj ruam 29: Txuas

Tsis Siv Neeg Caj Npab:

Caj Npab 3D Luam Ntawv:

Kuv caj npab 3D Luam tawm:

Arduino thiab Ua:

Kauj ruam 30: Code

Hloov los ntawm cov cai no

Arduino Txoj Cai:

#include // Tshaj tawm cov motors Servo myservo1; Servo myservo2; Servo myservo3; Servo myservo4; Servo myservo5; Servo myservo6; // Txhua lub tshuab hluav taws xob tau teeb tsa ntawm 90 degrees los ntawm default int current1 = 90; int tam sim no 2 = 90; int tam sim no 3 = 90; int tam sim no 4 = 90; int tam sim no5 = 90; int tam sim6 = 90; // Yam tsawg kawg thiab Qib Siab tshaj plaws lub cav tuaj yeem ncav cuag int mini1 = 0; int maxi1 = 180; int mini2 = 0; cov maxi2 = 180; int mini3 = 0; int maxi3 = 180; int mini4 = 0; cov max4 = 180; koj mini5 = 0; int maxi5 = 180; int mini6 = 0; int maxi6 = 180; // Cov qib yuav raug ntxiv lossis rho tawm ntawm txoj haujlwm tam sim no int degreesFoward = 5; // Ncua li ob txoj haujlwm tsis tshwm sim hauv qhov kev txiav txim tsis raug int delayBetweenSteps = 100; teeb tsa tsis muaj dab tsi () {// Teeb tsa tus pin rau txhua lub cav myservo1.attach (3); myservo2.attach (4); myservo3.attach (5); myservo4.attach (6); myservo5.attach (7); myservo6.attach (8); // Teeb tsa txhua lub cav mus rau qhov teeb tsa qub myservo1.write (current1); myservo2.write (tam sim no2); myservo3.write (current3); myservo4.write (current4); myservo5.write (current5); myservo6.write (tam sim no 6); // pib kev sib txuas lus sib txuas @9600 bps Serial.begin (9600); } void loop () {if (Serial.available ()) {// yog tias cov ntaub ntawv muaj los nyeem char val = Serial.read (); // muab tso rau hauv daim ntawv no // Lub Cev Muaj Zog Tswj yog (val == 'a' && current1 + degreesFoward mini1) {myservo1.write (current1 - degreesFoward); current1 = tam sim no1 - degreesFoward; ncua (delayBetweenSteps); } yog (val == 'c' && current2 mini2) {myservo2.write (current2 - degreesFoward); current2 = tam sim no2 - degreesFoward; ncua (delayBetweenSteps); } yog (val == 'e' && current3 mini3) {myservo3.write (current3 - degreesFoward); current3 = tam sim no 3 - degreesFoward; ncua (delayBetweenSteps); } yog (val == 'g' && current4 mini4) {myservo4.write (current4 - degreesFoward); current4 = tam sim no4 - degreesFoward; ncua (delayBetweenSteps); } yog (val == 'kuv' && current5 mini5) {myservo5.write (current5 - degreesFoward); current5 = tam sim no 5 - degreesFoward; ncua (delayBetweenSteps); } yog (val == 'k' && current6 mini6) {myservo6.write (current6 - degreesFoward); current6 = tam sim no 6 - degreesFoward; ncua (delayBetweenSteps); } // Kev tswj nrawm yog tias (val == 'w') {// Yog tias nrawm 1 khawm nias degreesFoward = 1; ncua (delayBetweenSteps); } yog (val == 'x') {// Yog tias nrawm 5 khawm nias degreesFoward = 5; ncua (delayBetweenSteps); } yog (val == 'y') {// Yog tias nrawm 10 khawm nias degreesFoward = 10; ncua (delayBetweenSteps); } yog (val == 'z') {// Yog tias nrawm 20 khawm nias degreesFoward = 20; ncua (delayBetweenSteps); } yog (val == 'r') {// Yog tias nrawm 20 khawm nias myservo1.write (90); tam sim no1 = 90; myservo2.write (90); tam sim no2 = 90; myservo3.write (90); tam sim no3 = 90; myservo4.write (90); tam sim no4 = 90; myservo5.write (90); tam sim no5 = 90; myservo6.write (90); tam sim no6 = 90; ncua (delayBetweenSteps); }}}

Ua Txoj Cai:

ntshuam ua.serial.*; ntshuam tswjP5.* // ntshuam ControlP5 lub tsev qiv ntawv Serial chaw nres nkoj; ControlP5 cp5; // tsim ControlP5 yam PFont font; teeb tsa tsis muaj dab tsi () {// zoo ib yam li arduino program loj (300, 700); // qhov loj me, (dav, qhov siab) printArray (Serial.list ()); // luam tawm txhua qhov muaj nyob hauv cov chaw nres nkoj // Yog tias koj muaj teeb meem nws zaum los ntawm no Cov hlua portName = Serial.list () [0]; port = Serial tshiab (qhov no, portName, 9600); // Kuv tau txuas nrog arduino rau com3, nws yuav txawv hauv linux thiab mac os // cia ntxiv khawm kom khoob qhov rai cp5 = ControlP5 tshiab (qhov no); font = createFont ("Arial", 13); // kev cai fonts rau cov nyees khawm thiab npe // Ceev Control Buttons cp5.addButton ("Ib") // "Ib" yog lub npe ntawm khawm.setPosition (50, 50) // x thiab y tswj hwm ntawm kaum sab laug ntawm lub pob.setSize (55, 25) // (dav, qhov siab).setFont (font); cp5.addButton ("Tsib").setPosition (110, 50).setSize (55, 25).setFont (font); cp5.addButton ("Kaum").setPosition (170, 50).setSize (55, 25).setFont (font); cp5.addButton ("Nees nkaum").setPosition (230, 50).setSize (55, 25).setFont (font); cp5.addButton ("Reset").setPosition (110, 2).setSize (55, 25).setFont (font); cp5.addButton ("Servo_1_Foward").setPosition (50, 90).setSize (190, 40).setFont (font); // Motor Control Buttons cp5.addButton ("Servo_1_Back").setPosition (50, 140).setSize (190, 40).setFont (font); cp5.addButton ("Servo_2_Foward").setPosition (50, 190).setSize (190, 40).setFont (font); cp5.addButton ("Servo_2_Back").setPosition (50, 240).setSize (190, 40).setFont (font); cp5.addButton ("Servo_3_Foward").setPosition (50, 290).setSize (190, 40).setFont (font); cp5.addButton ("Servo_3_Back").setPosition (50, 340).setSize (190, 40) // (dav, siab).setFont (font); cp5.addButton ("Servo_4_Foward").setPosition (50, 390).setSize (190, 40).setFont (font); cp5.addButton ("Servo_4_Back").setPosition (50, 440).setSize (190, 40) // (dav, siab).setFont (font); cp5.addButton ("Servo_5_Foward").setPosition (50, 490).setSize (190, 40).setFont (font); cp5.addButton ("Servo_5_Back").setPosition (50, 540).setSize (190, 40).setFont (font); cp5.addButton ("Servo_6_Foward").setPosition (50, 590).setSize (190, 40).setFont (font); cp5.addButton ("Servo_6_Back").setPosition (50, 640).setSize (190, 40).setFont (font); } void kos () {// tib yam li lub voj hauv keeb kwm yav dhau arduino (192, 215, 249); // keeb kwm yav dhau xim ntawm lub qhov rais (r, g, b) lossis (0 txog 255) // Ntxiv cov ntawv hais tias kev tswj ceev yog tswj ceev (0, 10, 25); // ntawv xim (r, g, b) textFont (font); ntawv ("Kev Tswj Ceev", 50, 40); // ("text", x coordinate, y coordinat)} // cia ntxiv qee qhov haujlwm rau peb cov nyees khawm // yog li thaum koj nias ib lub pob, nws xa cov ntawv tshwj xeeb tshaj qhov chaw nres nkoj txuas // Kuv paub tseeb tias nws muaj peev xwm xa cov hlua hloov cov ntawv, thiab nws yuav ua rau muaj kev nkag siab ntau dua tab sis kuv tsis paub yuav ua li cas // Kev tswj ceev hais kom ua tsis muaj dab tsi Ib () {port.write ('w'); } void Tsib () {port.write ('x'); } void Kaum () {port.write ('y'); } void Nees nkaum () {port.write ('z'); } // Lub Cev Tsav Tsheb Tswj cov lus txib tsis muaj txiaj ntsig Servo_1_Foward () {port.write ('a'); } tsis muaj dab tsi Servo_1_Back () {port.write ('b'); } tsis muaj dab tsi Servo_2_Foward () {port.write ('c'); } tsis muaj dab tsi Servo_2_Back () {port.write ('d'); } tsis muaj dab tsi Servo_3_Foward () {port.write ('e'); } tsis muaj dab tsi Servo_3_Back () {port.write ('f'); } tsis muaj dab tsi Servo_4_Foward () {port.write ('g'); } tsis muaj dab tsi Servo_4_Back () {port.write ('h'); } void Servo_5_Foward () {port.write ('kuv'); } tsis muaj dab tsi Servo_5_Back () {port.write ('j'); } tsis muaj dab tsi Servo_6_Foward () {port.write ('k'); } tsis muaj dab tsi Servo_6_Back () {port.write ('l'); } void Reset () {port.write ('r'); }

Kauj Ruam 31: Duab Ntxiv

Pom zoo: