Cov txheej txheem:
- Kauj Ruam 1: Cov Cheeb Tsam Yuav Tsum Tau
- Kauj Ruam 2: Qhia rau Dynamixel 12A
- Kauj Ruam 3: Sib Tham/tswj Dynamixel 12A
- Kauj Ruam 4: Sau Lub Hom Phiaj Txoj Haujlwm rau Dynamixel Motor
- Kauj Ruam 5: PYTHON CODE
Video: Tswj Dynamixel 12A los ntawm Kev Xa Pob Ntuas: 5 Cov Kauj Ruam
2024 Tus sau: John Day | [email protected]. Kawg hloov kho: 2024-01-30 09:24
DYNAMIXEL 12A
Kauj Ruam 1: Cov Cheeb Tsam Yuav Tsum Tau
HARDWARE:
1. Dynamixel 12A lossis Dynamixel lub cev muaj zog
2. USB rau Dynamixel.
SOFTWARE:
1. Robotis Dynamixel wizard
2. Python --- Serial pob ntsia
Kauj Ruam 2: Qhia rau Dynamixel 12A
Dynamixel motors yog qhov tseeb thiab feem ntau siv hauv Robotics. Txhua lub tshuab Dynamixel muaj STM microcontroller sab hauv. Koj tuaj yeem nyeem lub zog tam sim no, qhov hluav taws xob, kos tam sim no, ntsuas kub, txoj haujlwm, thiab lwm yam.., Los ntawm Dynamixels Motors.
Cov lus qhia tshwj xeeb ntawm Dynamixel 12A:
Ua haujlwm Voltage -12v
Qhov hnyav-55g
Max tam sim no -900mA
Stall Torque-15.3 Kg.cm
Kauj Ruam 3: Sib Tham/tswj Dynamixel 12A
- Dynamixel 12A tsis zoo li lub cav servo uas muaj 3pin GND, PWM, VCC, muab lub zog hluav taws xob thiab PWM teeb liab thiab tswj lub cav.
- Peb tuaj yeem tswj hwm Dynamixel cov tshuab siv Half Duplex UART kev sib txuas lus raws tu qauv.
Half Duplex Communication Protocol yog dab tsi?
Ib nrab-duplex cov ntaub ntawv xa mus txhais tau tias cov ntaub ntawv tuaj yeem xa mus rau ob qho kev qhia ntawm lub teeb liab, tab sis tsis yog tib lub sijhawm.
Tam sim no peb kawm txog Protocol 1.0 rau Dynamixels los ntawm Robotis los tswj Dynamixel cov motors.
- Koj tuaj yeem sib txuas lus nrog Dynamixel lub cev muaj zog los ntawm kev xa pob ntawv los ntawm koj lub laptop/microcontroller zoo li Arduino, r-pi, thiab lwm yam.., mus rau lub microcontroller uas muaj tam sim no hauv Dynamixel motors.
- Txhua Dynamixels muaj ID uas tuaj yeem hloov kho.
- Ib pob ntawv tsis muaj dab tsi tab sis Teeb ntawm bytes.
Incase of Dynamixel raws tu qauv 1.0 koj yuav muaj ob hom pob ntawv
- Cov ntawv qhia
- Cov xwm txheej pob ntawv
Pob ntawv qhia yog cov ntaub ntawv hais kom ua xa mus rau Ntaus Ntawv.
Cov ntawv qhia zoo li no:
Header1, Header2, ID, Ntev, Qhia, Param 1… Param, NChecksum
0xFF, 0xFF, ID, Length, Instruction Param 1… Param, NCHKSUM
Cov lus qhia byte qhia yuav ua li cas, seb puas yuav nyeem cov ntaub ntawv lossis sau rau Dynamixel lub cev muaj zog.
TABLE CONTROL NTAWM DYNAMIXEL MOTOR.-Lub Rooj Tswjhwm yog cov qauv uas muaj ntau yam Cov Ntaub Ntawv los khaws xwm txheej lossis tswj lub cuab yeej.
Nyeem ntxiv txog Tswj rooj Ntawm noControl Table Robotis.
Peb tuaj yeem nkag mus saib cov ntaub ntawv hauv lub rooj tswj hwm los ntawm nws qhov chaw nyob thiab peb kuj tuaj yeem sau.
Kauj Ruam 4: Sau Lub Hom Phiaj Txoj Haujlwm rau Dynamixel Motor
Cov Ntawv Qhia Qhia Kom Sau Lub Hom Phiaj txoj haujlwm
txhua pob ntawv pib nrog lub taub hau
H1 H2 ID LEN INST P1 P2 P3 CKSM
0xFF, 0xFF, 0x01, 0x05, 0x04, 0x1E, 0xF4, 0x01, 0xE2
LEN-kev qhia byte+p1+p2+p3+chk sum = 5 bytes
ID = Dynamixel lub cev ID 1-koj tuaj yeem teeb tsa dynamixel id siv neeg hlau dynamixel wizard software
INST = reg sau-qhia meej tias koj tau sau rau lub tshuab.
P1 = Pib qhov chaw nyob ntawm Cov Ntaub Ntawv-Hauv lub rooj tswj lub hom phiaj Txoj haujlwm muaj qhov chaw nyob 30 (0x1E hauv hexadecimal).
P2 = qis dua byte ntawm cov ntaub ntawv
P3 = ntau dua byte ntawm cov ntaub ntawv
Checksum xam yuav piav sai sai ………………….
Yog tias koj xa cov pob ntawv saum toj no mus rau Dynamixel Ua ntu zus siv USB2Dynamixel, Dynamixel lub hom phiaj lub hom phiaj yuav teeb tsa rau 500.
Kauj Ruam 5: PYTHON CODE
#Developed los ntawm Madhu. Qhov hloov tshiab kawg ntawm 2019-07-19
ntshuam Serial
lub sij hawm ntshuam
ser = serial. Serial ('com36', '57142')
#hloov com chaw nres nkoj raws li, kuv lub tshuab dynamixel baud tus nqi yog 57142, koj tuaj yeem teeb nws siv Dynamixel wizard software.
thaum (1):
gp1 = input ('nkag mus ID1 txoj haujlwm lub hom phiaj (0-1023)')
l = gp1 & 255 #low byte
h = (gp1 >> 8) & 255 #high byte
li = [0xff, 0xff, 0x01, 0x05, 0x04, 0x1e, l1, h1]
#txheeb xyuas cov lej suav
crc = sum (li [2:])
tsawg1 = crc & 255
txq = 255-low1
li.append (chksum) #adding check sum
a = bytearray (li) #hloov pauv cov npe rau hauv bytearray
ser.write (a) #Serially xa siv usb2dynamixels.
sijhawm.s pw (0.5)
#Luam theej code muab tso rau hauv nab nab IDE. Nruab pob pyserial. txuas usb2dynamixel sab USB rau lub laptop USB chaw nres nkoj thiab lwm qhov kawg rau Dynamixel lub cev muaj zog. Muab lwm 12v muab rau USB2DYNAMIXEL.
RUN cov cai, nkag mus rau lub hom phiaj txoj haujlwm tus nqi. Saib lub cav khiav.
Pom zoo:
Kev Ncaws Pob Ncaws Pob Cov Lus Qhia los ntawm Arduino: 5 Kauj Ruam
Kev Ncaws Pob Goalie Kev Qhia Ua Haujlwm los ntawm Arduino: Nqe lus piav txog kuv li Arduino Project: Reflect Trainer - Ntsuas koj qhov nrawm thiab ua tau zoo rau sab laug, sab xis. pem hauv ntej thiab nraub qaum; simulate cov tshuaj tiv thaiv ntawm tus neeg ncaws pob. Muab tsib lub laug cam ntawm cov xim sib txawv rau hauv av; ib daim ntawv dawb yog nyob hauv
Dual 7 -ntu Cov Lus Qhia Tswj los ntawm Potentiometer hauv CircuitPython - Qhia tawm ntawm Kev Ua Phem Tsis Pom Kev: 9 Kauj Ruam (nrog Duab)
Dual 7-ntu Cov Lus Qhia Tswj los ntawm Potentiometer hauv CircuitPython-Qhia tawm ntawm Kev Ua Phem Tsis Pom Kev: Qhov haujlwm no siv lub zog ntsuas los tswj cov zaub ntawm ob peb ntawm 7-ntu LED qhia (F5161AH). Raws li lub pob qhov ntsuas hluav taws xob tau tig lub teeb pom kev hloov pauv hauv thaj tsam 0 txog 99. Tsuas yog ib qho LED tau teeb nyob rau txhua lub sijhawm, luv luv, tab sis
Arduino Neeg Hlau Nrog Kev Nyob, Kev Qhia thiab Qib Kev Sib Hloov (Sab Hnub Poob, Sab Hnub Poob, Sab Qaum Teb, Sab Qab Teb) Tswj los ntawm Lub Suab Siv Bluetooth Module thiab Kev Siv Tus Neeg Siv Hluav Taws Xob: 6 Kauj Ruam
Arduino Neeg Hlau Nrog Kev Nyob, Kev Qhia thiab Qib Kev Sib Hloov (Sab Hnub Poob, Sab Hnub Poob, Sab Qaum Teb, Sab Qab Teb) Tswj los ntawm Lub Suab Siv Bluetooth Module thiab Kev Siv Tus Neeg Siv Hluav Taws Xob: Cov lus qhia no piav qhia yuav ua li cas thiaj tsim tau Arduino Robot uas tuaj yeem txav mus raws qhov xav tau (Forward, Backward) , Sab laug, Txoj Cai, Sab Hnub Poob, Sab Hnub Poob, Sab Qaum Teb, Sab Qab Teb) xav tau Kev nrug deb hauv Centimeters siv lub suab hais kom ua. Neeg hlau kuj tseem tuaj yeem txav tau tus kheej
Kev tswj hwm tus kheej ntawm RPM ntawm Lub Cav Siv Lub Tswv Yim Los Ntawm IR Raws Li Tachometer: 5 Cov Kauj Ruam (nrog Duab)
Kev Tswj Tus Kheej ntawm RPM ntawm Lub Cav Siv Lub Tswv Yim Los Ntawm IR Raws Lub Tachometer: Muaj ib txwm xav tau rau kev siv tshuab txheej txheem, ua nws yooj yim/tsis txaus ntseeg. cov txheej txheem rau dej/siv dej rau peb daim av me me.Qhov teeb meem ntawm tsis muaj kab khoom siv tam sim no
Txhim Kho Hauv Pob Ntseg Pob Ntseg (Pob Ntseg-Pob Nyiaj): 6 Cov Kauj Ruam
Txhim Kho Pob Ntseg Hauv Pob Ntseg (Pob Ntseg Pob Ntseg): Cov pob ntseg pob ntseg tsis haum rau kuv pob ntseg. Tab sis muaj kev daws teeb meem yooj yim rau qhov ntawd