Cov txheej txheem:

DIY Ua Haujlwm Tus Tsim Nrog STC MCU Yooj Yim: 7 Cov Kauj Ruam (nrog Duab)
DIY Ua Haujlwm Tus Tsim Nrog STC MCU Yooj Yim: 7 Cov Kauj Ruam (nrog Duab)

Video: DIY Ua Haujlwm Tus Tsim Nrog STC MCU Yooj Yim: 7 Cov Kauj Ruam (nrog Duab)

Video: DIY Ua Haujlwm Tus Tsim Nrog STC MCU Yooj Yim: 7 Cov Kauj Ruam (nrog Duab)
Video: yuav tau tsim kho tus kheej lub neej thiaj yuav vam meej tau 2024, Hlis ntuj nqeg
Anonim
DIY Ua Haujlwm Tus Tsim Nrog STC MCU Yooj Yim
DIY Ua Haujlwm Tus Tsim Nrog STC MCU Yooj Yim

Nov yog Lub Tshuab Hluav Taws Xob Ua Haujlwm nrog STC MCU. Xav tau tsuas yog ob peb yam khoom thiab kev sib txuas yog yooj yim.

Kev qhia tshwj xeeb

  • Cov Zis: Ib Leeg Channel
  • Square Waveform Zaus: 1Hz ~ 2MHz
  • Sine Waveform Zaus: 1Hz ~ 10kHz
  • Amplitude: VCC, txog 5V
  • Muaj peev xwm thauj khoom: Tsis muaj
  • MCU: STC15W4K32S4 @24 MHz
  • Zaub: LCD1602
  • Xws li: EC11 Encoder

Kauj ruam 1: Saib Video

Image
Image

Hauv cov vis dis aus no, kuv yuav qhia koj yuav ua li cas DIY no Tus Ua Haujlwm Tus Kheej Ua Ntej ib kauj ruam.

Kauj ruam 2: Npaj Koj Qhov

Scheme thiab Circuit!
Scheme thiab Circuit!

Daim Ntawv Teev Npe

  • MCU: STC15W4K32S4 x 1 Tau txais los ntawm AliExpress
  • Zaub: LCD1602 x 1 Tau txais los ntawm AliExpress
  • Row Pin Poj Niam: Tau txais nws los ntawm AliExpress

    • 16-Pin x 1
    • 2-Pin x 1
  • Potentiometer: Tau nws los ntawm AliExpress

    • 10k1x wb
    • 200 x 1 po
    • 500 x 1 po
  • IC Socket 40-Pin x 1 Tau txais los ntawm AliExpress
  • Inductor 1mH x 1 Tau txais los ntawm AliExpress
  • Capacitor:

    • 220nF x 1 Tau txais los ntawm AliExpress
    • 10 nxf 1
    • 47x1 wb
  • EC11 Encoder x 1 Tau txais los ntawm AliExpress
  • Lithium Polymer Roj teeb x 1 Tau txais los ntawm AliExpress
  • 5V lub zog x 1 Tau txais los ntawm AliExpress
  • Terminal 2-Pin x 2 Tau txais los ntawm AliExpress
  • Laub Hloov x 1 Tau nws los ntawm AliExpress
  • Capacitor 1uF (yeem) x 1 Tau txais los ntawm AliExpress

Kauj ruam 3: Scheme thiab Circuit

Scheme thiab Circuit!
Scheme thiab Circuit!
Scheme thiab Circuit!
Scheme thiab Circuit!

Thov xa mus rau lub Circuit Court thiab cov kauj ruam hauv video, koj tuaj yeem npaj cov khoom siv ntawm lub rooj tsav xwm yooj yim.

Kauj ruam 4: Rub tawm Txoj Cai

Rub tawm Txoj Cai!
Rub tawm Txoj Cai!
Rub tawm Txoj Cai!
Rub tawm Txoj Cai!
Rub tawm Txoj Cai!
Rub tawm Txoj Cai!

Rub lub pob hauv qab no. Muaj qhov chaws thiab suav ua cov ntaub ntawv hex.

Yog tias koj tsis xav nyeem cov lej, tsuas yog hlawv cov ntawv.hex rau hauv MCU. Siv USB rau TTL downloader thiab STC-ISP software rub tawm cov cai rau MCU. Txuas TXD, RXD thiab GND.

Rub tawm STC-ISP software ntawm no:

Yog tias lub interface ntawm STC-ISP yog Suav, koj tuaj yeem nyem lub cim sab laug sab saud kom hloov cov lus rau lus Askiv. Txog qhov teeb tsa kev teeb tsa ntawm STC-ISP thov xa mus rau cov vis dis aus hauv Kauj Ruam 1.

Cov lej tau sau rau hauv C. Siv Keil software txhawm rau kho thiab sau nws.

Kauj ruam 5: Ua tiav

Ua tau zoo!
Ua tau zoo!
Ua tau zoo!
Ua tau zoo!
Ua tau zoo!
Ua tau zoo!
Ua tau zoo!
Ua tau zoo!

Koj tuaj yeem siv qhov DIY Function Generator los tso tawm Square waveform lossis Sine waveform teeb liab.

Interface:

  • Hauv qab sab laug qhia hom kev hloov pauv (Square/Sine) thiab cov xwm txheej tso tawm (ON/OFF)
  • F: Zaus
  • D: Lub luag haujlwm ntawm Square Waveform
  • CD: Clock Division Coefficient (Rau cov ntaub ntawv nkaus xwb)
  • P: PWM zaus rau kev tsim Sine Waveform (Rau cov ntaub ntawv nkaus xwb)
  • Pt: Tus naj npawb ntawm cov ntsiab lus rau kev tsim Sine Waveform (Rau cov ntaub ntawv nkaus xwb)

Kev Ua Haujlwm:

  • Nyem Nyem Encoder: Hloov Zaus thiab Ua Haujlwm hauv Square Waveform Interface
  • Ob Nyem Nyem Encoder: Pib/Nres Teeb Meem Tso Tawm
  • Ntev Xovxwm Encoder: Hloov ntawm Square Waveform/Sine Waveform/Voltage Information
  • Rotate Encoder: Kho Parameters

Kauj Ruam 6: Cov Lus Qhia

Lub teeb liab tso tawm tsis muaj peev xwm thauj khoom. Yog tias koj xav tsav lwm qhov kev tivthaiv, thov qhia rau koj tias siv lub tshuab ua haujlwm zoo los txhim kho lub peev xwm thauj khoom.

Kauj Ruam 7: Npaj Yav Tom Ntej

Txoj Kev Npaj Yav Tom Ntej
Txoj Kev Npaj Yav Tom Ntej

Kuv npaj yuav ua lwm Lub Chaw Tsim Khoom nrog STM32.

Cia siab rau nws

  • Muaj peev xwm tsim daim duab peb sab thiab Pom waveform ntxiv.
  • Qhov zaus ntawm Sine waveform tuaj yeem siab dua 10kHz.

Yog tias koj muaj lus qhia lossis xav tau txog txoj haujlwm no, thov ua siab zoo qhia kuv.

Vam tias koj nyiam.

Zoo siab los tshuaj xyuas kuv li YouTube Channel:

Pom zoo: