Cov txheej txheem:

Arduino Digital Code Lock Project Siv Matrix Keypad: 9 Kauj Ruam
Arduino Digital Code Lock Project Siv Matrix Keypad: 9 Kauj Ruam

Video: Arduino Digital Code Lock Project Siv Matrix Keypad: 9 Kauj Ruam

Video: Arduino Digital Code Lock Project Siv Matrix Keypad: 9 Kauj Ruam
Video: Using Keypads with Arduino - Build an Electronic Lock 2024, Kaum ib hlis
Anonim
Arduino Digital Code Lock Project Siv Matrix Keypad
Arduino Digital Code Lock Project Siv Matrix Keypad

Tsim cov lej ntsuas phoo digital nrog Arduino thiab Qwiic system siv Zio M Uno thiab Hex 4x3 Matrix Keypad.

Txheej txheem cej luam

Rau qhov haujlwm no, peb yuav tsim kom yooj yim digital chaws ntsuas phoo uas cov neeg siv nkag tau thiab nkag tau rau hauv. Hauv qhov kev qhia no, peb yuav qhia cov neeg siv li cas cov lej kaw qhov system ua haujlwm hauv Arduino Interface.

Thaum kawg ntawm qhov kev qhia no koj yuav muaj peev xwm:

  • Teeb tsa tus lej xauv nrog Zio thiab yooj yim 12 tus yuam sij keypad
  • Muaj peev xwm cuam tshuam nrog Arduino IDE rau program Zio nrog cov keyboard
  • Tsim ib qho program uas nug cov neeg siv kom nkag mus rau tus lej rau tus lej nkag mus qhib
  • Muaj peev xwm tsim tus lej tshiab rau tus lej tshiab

Cov peev txheej pab tau

Rau qhov yooj yim lub hom phiaj, qhov kev qhia no xav tias koj muaj kev nkag siab tag nrho thiab paub txog kev teeb tsa Zio kev txhim kho cov laug cam.

Txog qhov haujlwm no, peb xav tias koj twb tau teeb tsa Zuino M Uno los cuam tshuam nrog Arduino IDE. Yog tias koj tsis tau ua li ntawd peb muaj cais cais tawm ntawm peb cov phiaj xwm kev txhim kho. Xyuas lawv tawm hauv qab no:

Zuino M Uno Qwiic Pib Qhia

Kauj ruam 1: Schematic Layout

Schematic Layout
Schematic Layout

Kauj ruam 2: Teeb & Configuration

Koj yuav xav tau cov qauv hauv qab no los tsim txoj haujlwm no:

  • Zuino M Ib
  • Zio Qwiic 0.91 "OLED Zaub
  • Hex Matrix Keypad (4 x 3)
  • Qwiic Cables 200 hli
  • Breadboard Cables Jumper xov hlau (Txiv neej rau Poj Niam)
  • Micro USB Cable

Kauj ruam 3:

Duab
Duab

Daisy saw cov qauv ua ke raws li qhia hauv kab duab Schematics saum toj no.

Kauj ruam 4:

Duab
Duab
Duab
Duab
Duab
Duab
Duab
Duab

Txuas tus Keypad siv Txiv neej rau Poj Niam Jumpers, rau koj Zuino M Uno

Kauj ruam 5:

Rub tawm thiab teeb tsa cov tsev qiv ntawv hauv qab no rau koj Arduino IDE:

  • Adafruit GFX Lub Tsev Qiv Ntawv
  • Adafruit SSD1306 Lub Tsev Qiv Ntawv
  • Arduino Keypad Library

Kauj Ruam 6:

Txuas koj Uno rau lub khoos phis tawj. Rub tawm thiab nyem qhov chaws rau koj Uno siv Arduino IDE.

Koj tuaj yeem rub tawm cov cai los ntawm peb nplooj Github.

Kauj Ruam 7: Demo: Nkag Mus Nkag Mus

Demo: ID nkag mus xeem
Demo: ID nkag mus xeem
Demo: ID nkag mus xeem
Demo: ID nkag mus xeem
Demo: ID nkag mus xeem
Demo: ID nkag mus xeem

Nkag mus rau tus lej lej tom qab tus lej "#". Txhawm rau nrhiav tus lej 6 tus lej uas khaws cia hauv tus lej program, qhib lub serial monitor thiab nws yuav qhia tus password rau lub xauv.

Yog tias koj ua tiav kev nkag mus nrog tus lej nkag mus raug koj yuav pom lub vijtsam Txais tos.

Kauj Ruam 8: Hloov Kev Xeem Tus Kheej

Hloov Kev Xeem Password
Hloov Kev Xeem Password
Hloov Kev Xeem Password
Hloov Kev Xeem Password

Thaum koj tswj hwm tus ID nkag mus, koj yuav tuaj yeem hloov tus password rau tus tshiab. Txhawm rau hloov tus password, lees paub nws nrog tus lej "*".

Hauv qhov piv txwv no, Kuv hloov tus password los ntawm 123456 rau 000000 raws li qhia hauv Serial monitor.

Kauj Ruam 9: Kev Xeem Tsis Nkag Nkag Siab Sim

Ua Tsis Tau Tus Kheej Nkag Siab Teem Kuaj
Ua Tsis Tau Tus Kheej Nkag Siab Teem Kuaj
Ua Tsis Tau Tus Kheej Nkag Siab Teem Kuaj
Ua Tsis Tau Tus Kheej Nkag Siab Teem Kuaj

Nrog qhov ua piv txwv no, peb kuj suav nrog qhov ua haujlwm uas, nrog 3 qhov kev sim ua tsis tiav los nkag tus password kom raug, lub cuab yeej yuav xauv nws tus kheej. Txhawm rau sim nws, rov pib dua koj Uno. Sim thiab sau tus password tsis raug 3 zaug.

Koj yuav raug kaw tam sim tom qab 3 qhov kev sim ua tsis tiav.

Pom zoo: