Cov txheej txheem:
- Kauj Ruam 1: Qhov Yuav Tsum Tau
- Kauj ruam 2: Tsim Circuit Court
- Kauj Ruam 3: Txoj Cai
- Kauj ruam 4: Cov ntawv thov
Video: Kev Tshawb Nrhiav Xim Siv RGB LED: 4 Cov Kauj Ruam
2024 Tus sau: John Day | [email protected]. Kawg hloov kho: 2024-01-30 09:31
Koj puas tau xav tau txoj hauv kev kom pom xim ntawm ib yam khoom? Los ntawm lub teeb ci ntawm ib qho xim ntawm cov khoom thiab saib ntau npaum li cas lub teeb pom kev rov qab, koj tuaj yeem qhia qhov xim ntawm cov khoom yog dab tsi. Piv txwv li, yog tias koj ci lub teeb liab ntawm ib yam khoom liab, lub teeb ntawd yuav pom rov qab. Yog tias koj ua lub teeb xiav rau ntawm cov khoom liab, cov khoom yuav nqus qee lub teeb ntawd thiab tsawg dua ntawm nws yuav rov pom dua.
Kauj Ruam 1: Qhov Yuav Tsum Tau
Kuv siv PIC 16F887 Microcontroller, tab sis yuav luag txhua yam nrog lub plawv dhia-dav-kev hloov kho lub peev xwm yuav ua haujlwm. 1 RGB LED1 Microcontroller1 Txuj ci liab LED1 1k ohm resistor1 Photoresistor (hloov kev ua haujlwm nyob ntawm qhov pom ntawm lub teeb ci rau nws) Qee cov xov hlau Kuv tsuas xav tau microcontroller thiab RGB LED kom muaj ntau yam xim ntsuas, tab sis yog tias koj tsuas xav tau lub Circuit Court uas kuaj pom ib qho xim, koj tsis xav tau lub microcontroller - koj tsuas xav tau lub teeb ci ci ntawm cov xim uas koj xav paub. Tus txheej txheem liab liab yog "qhov taw qhia LED" - nws teeb thaum pom cov xim raug.
Kauj ruam 2: Tsim Circuit Court
Schematic yog qhov yooj yim dua, thiab hauv daim ntawv dav dav, tau qhia hauv qab no. RGB LED yog lub zog sab nraud los ntawm PWM teeb liab. Kuv muab cov kab hluav taws xob nyob ib puag ncig lub photoresistor yog li cov teeb pom kev ib puag ncig tsis nkag mus - tsuas yog lub teeb ncaj qha saum nws yuav pom.
Kauj Ruam 3: Txoj Cai
Cov cai no tau sau rau Microchip PIC 16F887, tab sis cia siab tias koj tuaj yeem tau txais lub tswv yim dav. Kuv siv lub zog ntsuas hluav taws xob built-in ntawm kuv lub rooj tsav xwm txhim kho kom sib txawv xim ntawm RGB LED (thiab nws tsis dhau mus rau tag nrho cov spectrum vim tias kuv tsis muaj 3 PWM modules, tab sis nws zoo txaus) Cov lus suav nrog. #suav nrog #suav nrog #suav nrog "ncua.c" #suav nrog #suav nrog #siv ncua (moos = 4000000) #FUSES INTRC, NOWDT, NOPUT, NOMCLR, NOPROTECT, NOCPD, NOBROWNOUT, NOIESO, NOFCMEN, NOLVP #byte CCP1CON0 byte CCP2CON = 0x1D#byte PWM1CON = 0x9Bint tus nqi = 128; int p1 = 0; int p2 = 0; void my_setup_ccp1 (int8 value) {output_low (PIN_C2); CCP1CON = value; PWM1CON = 0;} void my_setup_ccp2 (int8 value) {output_low (PIN_C1); CCP2CON = tus nqi;} // =================================== void main () {// A4 = qhov chaw muaj zog rau photodiodeoutput_high (PIN_A4); output_high (PIN_B1); teeb tsa_adc (ADC_CLOCK_INTERNAL); set_adc_channel (0); teeb tsa_adc_ports (sAN0); // Timer/cuam tshuam teeb tsa teeb tsa_interrupts (INT_TIM2) my_setup_ccp2 (CCP_PWM); teeb tsa_timer_2 (T2_DIV_BY_1, 128, 1); // teeb tsa_compare (2, COMPARE_PWM | COMPARE_TIMER2); thaum (1) {// Tiv thaiv PIC tsis txhob tsaug zog.//SET PWM DUTY CYCLE output_high (PINA) // Pin A3 yog qhov txuas photodiode yog (input (PIN_A3) == 1) output_high (PIN_A4); lwm qhov output_low (PIN_A4); // Nyeem tus nqi ntawm lub hwj chim hloov xim ntawm LED tus nqi = read_adc (); hloov (tus nqi) {rooj plaub 0: p1 = tus nqi; output_low (PIN_C0); p2 = tus nqi; tawg; rooj plaub 50: p1 = tus nqi; output_high (PIN_C0); p2 = tus nqi; tawg; rooj plaub 100: p1 = tus nqi; output_high (PIN_C0); p2 = tus nqi; tawg; rooj plaub 150: output_high (PIN_C0); p1 = 50; p2 = tus nqi; tawg; rooj plaub 200: output_low (PIN_C0); p1 = 0; p2 = tus nqi; tawg; rooj plaub 250: p1 = 0; p2 = tus nqi; output_low (PIN_C0); tawg; } p1 = tus nqi; p2 = 128 - p1; set_pwm1_duty (p1); set_pwm2_duty (p2);}}
Kauj ruam 4: Cov ntawv thov
Lub tshuab ntsuas xim yooj yim zoo li no tuaj yeem siv rau hauv cov neeg hlau, lossis rau cov haujlwm txias xws li sib cais legos los ntawm xim, txheeb M & Ms, lossis raws li kev pab rau qhov muag tsis pom xim. Vam tias cov lus qhia no tau pab txhim kho txoj haujlwm uas koj tau xav!:) LEDs zoo rau ntau yam….
Pom zoo:
Siv Kev Cia Siab Lub Hauv Paus txuas ntxiv txhawm rau Nrhiav Lub Tuam Tsev Tsis Ua Haujlwm Txoj Cai Ua Haujlwm Hauv Koj Tsev Neeg Tsob Ntoo ntawm Kev Tshawb Nrhiav Tsev Neeg: 11 Kauj Ruam
Siv Kev Cia Siab Lub Hauv Paus Txuas Ntxiv kom Nrhiav Lub Tuam Tsev Tsis Ua Haujlwm Ua Haujlwm Hauv Koj Tsev Neeg Tsob Ntoo ntawm Kev Tshawb Nrhiav Tsev Neeg: Lub hom phiaj ntawm cov lus qhia no yog los qhia seb yuav tshawb nrhiav koj tsev neeg tsob ntoo li cas hauv Tsev Neeg Nrhiav rau cov poj koob yawm txwv nrog kev ua haujlwm hauv lub tuam tsev tsis tiav siv Kev Cia Siab lub hauv siab txuas ntxiv. Siv Kev Cia Siab Lub Hauv Paus tuaj yeem ua rau koj qhov kev tshawb nrhiav tsis tiav
Kev Tshawb Nrhiav Xim hauv Python Siv OpenCV: 8 Cov Kauj Ruam
Kev Tshawb Nrhiav Xim hauv Python Siv OpenCV: Nyob Zoo! Cov lus qhia no yog siv los qhia nrog yuav ua li cas rho tawm cov xim tshwj xeeb los ntawm cov duab hauv nab nab siv openCV lub tsev qiv ntawv. Yog tias koj tshiab rau cov txheej txheem no ces tsis txhob txhawj xeeb, thaum kawg ntawm phau ntawv qhia no koj yuav tuaj yeem ua haujlwm rau koj tus kheej xim
Kev Tshawb Nrhiav Xim Raws Li Lub Hom Phiaj Taug Kev: 10 Kauj Ruam
Kev Tshawb Nrhiav Xim Raws Li Lub Hom Phiaj Nrhiav: Zaj Dab Neeg Kuv tau ua qhov haujlwm no kom kawm paub ua duab siv Raspberry PI thiab qhib CV. Txhawm rau ua txoj haujlwm no kom zoo dua Kuv tau siv ob lub SG90 Servo motors thiab teeb lub koob yees duab rau nws. Ib lub cav siv txav mus rau kab rov tav thiab lub cav thib ob siv txav lub kaum sab xis
Visuino Tsim Kev Tshawb Fawb Kev Tshawb Fawb Siv Arduino: 8 Cov Kauj Ruam
Visuino Tsim Kev Tshawb Fawb Kev Tshawb Fawb Siv Arduino: Hauv qhov kev qhia no peb yuav siv XYC-WB-DC Microwave Radar Motion Sensor txuas nrog Arduino UNO thiab Visuino txhawm rau txheeb xyuas txhua qhov txav hauv ib puag ncig 5m suav nrog cov phab ntsa nyias
Kev Ntsuas Tus Qauv Ntsuas Siv Kev Tshawb Nrhiav Lub Neej Nyob: 11 Kauj Ruam (nrog Duab)
Kev Txheeb Tus Qauv Cuam Tshuam Siv Kev Tshawb Nrhiav Lub Caij Nyoog: Hauv lub ntiaj teb niaj hnub no, cov teeb pom kev yog qhov tseem ceeb rau txoj kev nyab xeeb. Txawm li cas los xij, ntau zaus, cov teeb liab tuaj yeem cuam tshuam rau qhov xwm txheej uas ib tus neeg tab tom nce lub teeb ib yam li nws tab tom tig liab. Qhov no nkim sijhawm, tshwj xeeb tshaj yog tias lub teeb yog pr