Cov txheej txheem:
- Kauj ruam 1: Tsim kom muaj Servo Bracket
- Kauj Ruam 2: Hlau Servos rau Arduino Uno
- Kauj Ruam 3: Arduino Code…
Video: Arduino Servo Nruas Tshuab: 4 Cov Kauj Ruam
2024 Tus sau: John Day | [email protected]. Kawg hloov kho: 2024-01-30 09:28
Nov yog qhov yooj yim ob lub micro-servo thiab Arduino Uno tswj lub tshuab nruas lossis neeg hlau. Cov servos tau teeb tsa ntawm L-zoo li tus ntoo uas tau tuav rau lub nruas nruas nrog 4 tus hlau nplaum muaj zog. Lub caj npab servo tau muab khi rau ob txoj hlua uas ua haujlwm ua lub nruas-pas. Nws nrov heev tab sis tsis nrov heev. Ntau qhov nrov nrov tuaj yeem tau txais los ntawm kev siv tus qauv loj servos thiab cov nruas tiag uas yog hnyav dua me ntsis. Tab sis qhov ntawd tseem yuav xav tau lub zog cais cais rau cov servos. Los ntawm kev siv micro-servos Arduino cov khoom siv txaus txaus tam sim no rau lub zog lawv ncaj qha yam tsis muaj lub zog sib cais.
Cov vis dis aus qhia kuv qhov kev sim ntawm kev ua haujlwm yooj yim ntawm Wipeout nruas solo. Yog lawm nws tsis yog qhov tseeb 160 ntaus ib feeb tab sis qhov ntawd tuaj yeem yooj yim tau los ntawm kev ntxiv lwm qhov kev pabcuam uas yuav zoo nkauj heev. Kuv tsis tau suav qhov dab tsi saum toj kawg nkaus bpm uas tuaj yeem tau txais los ntawm kev siv servo thiab nws xav tau qee qhov qeeb hauv kev tau txais cov nruas los ntawm nws qhov chaw nres tsheb mus rau lub nruas taub hau.
Cov lus sib dhos uas koj tuaj yeem tsim tsuas yog txwv los ntawm koj lub tswv yim thiab lub tshuab nruas yog cov phooj ywg zoo tshaj plaws los ua si nrog ntau dua li lub tshuab nruas digital, yog tias koj yog tshuab raj.
Tsuas yog qhov poob qis yog lub suab nrov servo uas tsis yog qhov pom tau tiag tiag txawm hais tias lub koob yees duab suab zoo li tuaj tos nws qhov tsim nyog.
Kauj ruam 1: Tsim kom muaj Servo Bracket
Cov khoom siv no yog tsim los ntawm qee daim kab xev ntawm kev nyiam plywood uas kuv muaj ntawm tes. Kuv tsim L-puab los ntawm bolted ob daim ua ke nrog hlau L-bracket. Tom qab ntawd ib qho me me ntawm cov ntoo tau lo rau saum kab txaij los tuav ob lub servos.
Kuv muaj ob lub tswv yim pab ua ke uas kuv tau ntsia rau ntawm cov ntoo.
Kuv siv 4 lub hlau nplaum neodymium los tuav lub bracket rau lub nruas nruas.
Kauj Ruam 2: Hlau Servos rau Arduino Uno
Cov servos vcc (nruab nrab xaim) mus rau Arduino 5 v pins.
Cov av hauv av mus rau Arduino av.
Cov xov hlau teeb liab mus rau tus pin 6 thiab 7.
Cov ntaub thaiv npog servo yuav ua rau nws yooj yim dua yog tias koj muaj.
Kauj Ruam 3: Arduino Code…
Hauv qab no yog daim duab yooj yim los ua si Wipeout. Koj tsuas yog yuav tsum hloov kho txoj haujlwm servo rau koj teeb tsa tshwj xeeb.
Muaj kev lom zem!
///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
#suav nrog "servo.h"
// servo nruas Jim Demello Lub Rau Hli 2018
Servo myservo1, myservo2;
int servoPin6 = 6; // servo cov
int servoPin7 = 7;
tsis muaj dab tsi myServo (int servoPosition, int servoNumber) {
yog (servoNumber == 1) {
myservo1.write (servoPosition);
}
yog (servoNumber == 2) {
myservo2.write (servoPosition);
}
}
void doOneEighthNote (int servoNumber, int tuav) {
int delayVal = 60;
yog (servoNumber == 1) {
yog (ntaus) {yeej = 10; // yog tuav = 1 ces ntxiv me ntsis ntxiv servo nqis rau thump zog
}
myServo (150 + yeej, servoNumber); // lej
ncua (delayVal);
myServo (100, servoNumber); // nce
ncua (delayVal);
}
yog (servoNumber == 2) {
yog (ntaus) ntaus = -10;
myServo (60 + yeej, servoNumber); // lej
ncua (delayVal);
myServo (80, servoNumber); // nce
ncua (delayVal);
}
}
void teeb tsa ()
{
// Serial.begin (9600);
myservo1.attach (servoPin6, 1000, 2000); // txuas cov servo ntawm tus pin 9 rau cov khoom siv servo
myservo1.write (100);
myservo2.attach (servoPin7, 1000, 2000); // txuas cov servo ntawm tus pin 9 rau cov khoom siv servo
myservo2.write (90);
}
void voj () {
rub tawm (); // rub tawm lub nruas niaj hnub
// doOneEighthNote (2, 0);
ncua (40);
}
tsis muaj dab tsi rub tawm () {
doOneEighthNote (2, 1); doOneEighthNote (1,0); doOneEighthNote (2, 0); doOneEighthNote (1,0); // thawj parm yog tus lej servo thiab parm thib ob raug ntaus (1 = ntaus, 0 = tsis ntaus)
doOneEighthNote (2, 1); doOneEighthNote (1,0); doOneEighthNote (2, 0); doOneEighthNote (1,0);
doOneEighthNote (2, 1); doOneEighthNote (1,0); doOneEighthNote (2, 0); doOneEighthNote (1,0);
doOneEighthNote (2, 1); doOneEighthNote (1,0); doOneEighthNote (2, 0); doOneEighthNote (1,0);
doOneEighthNote (2, 1); doOneEighthNote (1,0); doOneEighthNote (2, 0); doOneEighthNote (1,0);
doOneEighthNote (2, 0); doOneEighthNote (1,0); doOneEighthNote (2, 1); doOneEighthNote (1,0);
doOneEighthNote (2, 0); doOneEighthNote (1,0); doOneEighthNote (2, 0); doOneEighthNote (1,0);
doOneEighthNote (2, 1); doOneEighthNote (1,0); doOneEighthNote (2, 0); doOneEighthNote (1,0);
doOneEighthNote (2, 1); doOneEighthNote (1,0); doOneEighthNote (2, 0); doOneEighthNote (1,0);
doOneEighthNote (2, 1); doOneEighthNote (1,0); doOneEighthNote (2, 0); doOneEighthNote (1,0);
doOneEighthNote (2, 1); doOneEighthNote (1,0); doOneEighthNote (2, 0); doOneEighthNote (1,0);
doOneEighthNote (2, 1); doOneEighthNote (1,0); doOneEighthNote (2, 0); doOneEighthNote (1,0);
doOneEighthNote (2, 1); doOneEighthNote (1,0); doOneEighthNote (2, 0); doOneEighthNote (1,0);
doOneEighthNote (2, 0); doOneEighthNote (1,0); doOneEighthNote (2, 1); doOneEighthNote (1,0);
doOneEighthNote (2, 0); doOneEighthNote (1,0); doOneEighthNote (2, 1); doOneEighthNote (1,0);
doOneEighthNote (2, 0); doOneEighthNote (1,0); doOneEighthNote (2, 0); doOneEighthNote (1,0);
}
Pom zoo:
Tshuab Nruas Yooj Yim Nrog Arduino Uno thiab Mozzi: 4 Kauj Ruam
Lub Tshuab Nruas Yooj Yim Nrog Arduino Uno thiab Mozzi: Nyob hauv Argentina txhais tau tias kev xa ntawv thoob ntiaj teb yuav raug nyiag lossis raug kaw hauv kev lis kev cai. Ntxiv Coronavirus cais tawm thiab koj txoj haujlwm tom ntej raug txwv rau pawg thawj coj Arduino Uno. Xov xwm zoo? Raws li tus kws sau paj huam zoo los ntawm Rolling Stones hais tias "Lub sijhawm nyob ntawm kuv
YUAV UA LI CAS YUAV TSHUAB TSHUAB TSHUAB NROG NROG ARDUINO: 8 Kauj Ruam
YUAV UA LI CAS YUAV TSUM TSHUAB TSHUAB TSHUAB NROG ARDUINO: QHOV TSEEB Lub tshuab sau ntawv tau tsim los ntawm cov ntaub ntawv uas tuaj yeem tau yooj yim hauv tsev; nws ua rau siv rau lub cav hluav taws xob uas yog lub hauv paus tseem ceeb ntawm nws txoj haujlwm. Nws tuaj yeem siv hauv Kev kos duab Engineering thiab kos duab kos duab. Nws tuaj yeem yog
HX1 -DM - Upcycled Arduino DUE Powered DIY Nruas Tshuab (ua Nrog Tuag Maschine MK2): 4 Cov Kauj Ruam
HX1 -DM - Upcycled Arduino DUE Powered DIY Nruas Tshuab (ua Nrog Tuag Maschine MK2): Qhov Tshwj Xeeb. Hybrid Midi maub los / tshuab nruas: Arduino DUE powered! 16 Tshaj tawm qhov ntsuas qhov nrawm nrog qis qis heev 1 > ms 8 pob qhov rooj siv rau ib qho Midi #CC hais kom ua 16ch Ua-hauv ntu (tsis xav tau lub computer !!) MIDI hauv/tawm/hla kev ua haujlwm
Lub Tshuab Raspberry Pi Siv Lub Tshuab Nruas Tsis Zoo: 15 Cov Kauj Ruam (nrog Duab)
Raspberry Pi Powered Junk Drum Machine: Cov lus qhia no yuav qhia koj yuav ua li cas thiaj ua tau Raspberry Pi siv lub tshuab nruas neeg hlau. Nws yog qhov kev lom zem, muaj tswv yim, sib tham sib tham. Kuv yuav qhia koj yuav ua li cas txhawm rau ua haujlwm sab hauv, tab sis lub nruas tiag yuav nyob ntawm koj, muab rau koj
Nruas Hnav: Nruas hauv Koj Cov Khaub Ncaws!: 7 Kauj Ruam
Nruas Hnav: Nruas hauv Koj Cov Khaub Ncaws!: Saib cov neeg caij tsheb npav hauv nroog. Coob leej ntawm lawv tau ntsaws rau hauv lawv cov nkauj ntaus suab paj nruag, ntaus nrog rau kev ntaus, ua piv txwv tias lawv muaj nruas ntawm lawv qhov pov tseg. Tam sim no tsis tas yuav ua txuj ua! Nruas hnav muab cov neeg ntaus nruas nqa tau yooj yim thiab siv tau