Cov txheej txheem:

EAL - SmartStorage: 3 Kauj Ruam
EAL - SmartStorage: 3 Kauj Ruam

Video: EAL - SmartStorage: 3 Kauj Ruam

Video: EAL - SmartStorage: 3 Kauj Ruam
Video: Subway Surfers in REAL LIFE. 🤣😂 #shorts 2024, Kaum ib hlis
Anonim
EAL - SmartStorage
EAL - SmartStorage
EAL - SmartStorage
EAL - SmartStorage

Nov yog qhov haujlwm rau SmartStorage los ntawm Kasper Borger Tulinius

Kauj Ruam 1: Txoj Kev

Txoj kev
Txoj kev

Rau qhov haujlwm no kuv tau siv ob peb qhov program sib txawv.

Lub tshuab nws tus kheej yog tsim hauv 123D Tsim thiab luam tawm ntawm DaVinci jr. tshuab luam ntawv

Tsis yog qhov zoo tshaj plaws tab sis yooj yim heev thiab siv tus phooj ywg.

Nws tau ua los ntawm Arduino programmed hauv C.

Kuv tau siv Visual Studio 2017 los ua WindowsFormApp (C#).

Kauj ruam 2: Code rau Arduino

Code rau Arduino
Code rau Arduino
Code rau Arduino
Code rau Arduino

Rau lub tshuab nws tus kheej Kuv tau siv Arduino Mega. Nws yog programmed hauv C. Lub tshuab yooj yim heev. Nws ua ntu ntu yooj yim kom tau txais lub txee thiab nthuav tawm rau tus neeg teb xov tooj.

Cov motors kuv tau siv yog 2 lub cav me me stepper tsav los ntawm 2 SBT0811.

Txhawm rau tswj lub tshuab kuv tau ua ib qho app uas sib txuas lus los ntawm com chaw nres nkoj.

#suav nrog "Stepper.h"

#define KAUJ RUAM 32 // Tus naj npawb ntawm cov kauj ruam rau kev hloov kho ntawm sab hauv lub cev // 2048 cov kauj ruam rau ib qho kev hloov pauv ntawm sab nrauv sab nraud cmd; // Fra WinApp int posZero = 0; int posOne = 1000; int posTwo = 1500; int posThree = 2000; int luas = 100; int xa = -100; int steps_extractor_out = 512; int steps_extractor_back = -512; Stepper hoist (STEPS, 8, 10, 9, 11); Stepper extractor (STEPS, 2, 3, 4, 5); teeb tsa tsis muaj dab tsi () {} tsis muaj dab tsi voj () {Serial.begin (9600); cmd = Serial.read (); yog (cmd == 1) {Serial.end (); ncua (1000); } lwm yog (cmd == 0) {hoist.setSpeed (600); hoist.step (posOne); ncua (200); extractor.setSpeed (300); extractor.step (steps_extractor_out); ncua (200); hoist.setSpeed (100); hoist.step (lob); ncua (200); extractor.step (steps_extractor_back); ncua (200); hoist.setSpeed (600); hoist.step (-posOne-grab); ncua (200); extractor.step (steps_extractor_out); ncua (5000); // EVT CMD FRA WINaPP extractor.step (steps_extractor_back); ncua (200); hoist.step (posOne+lob); ncua (200); extractor.step (steps_extractor_out); ncua (200); hoist.setSpeed (100); hoist.step (-grab); ncua (200); extractor.step (steps_extractor_back); ncua (200); hoist.setSpeed (600); hoist.step (-posOne); Serial.begin (9600); Serial.println (0); Serial.end (); } lwm yog (cmd == 2) {hoist.setSpeed (600); hoist.step (posTwo); ncua (200); extractor.setSpeed (300); extractor.step (steps_extractor_out); ncua (200); hoist.setSpeed (100); hoist.step (lob); ncua (200); extractor.step (steps_extractor_back); ncua (200); hoist.setSpeed (600); hoist.step (-posTwo-grab); ncua (200); extractor.step (steps_extractor_out); ncua (5000); // EVT CMD FRA WINaPP extractor.step (steps_extractor_back); ncua (200); hoist.step (posTwo+lob); ncua (200); extractor.step (steps_extractor_out); ncua (200); hoist.setSpeed (100); hoist.step (-grab); ncua (200); extractor.step (steps_extractor_back); ncua (200); hoist.setSpeed (600); hoist.step (-posTwo); Serial.begin (9600); Serial.println (0); Serial.end (); } lwm yog (cmd == 3) {hoist.setSpeed (600); hoist.step (posThree); ncua (200); extractor.setSpeed (300); extractor.step (steps_extractor_out); ncua (200); hoist.setSpeed (100); hoist.step (lob); ncua (200); extractor.step (steps_extractor_back); ncua (200); hoist.setSpeed (600); hoist.step (-posThree-grab); ncua (200); extractor.step (steps_extractor_out); ncua (5000); // EVT CMD FRA WINaPP extractor.step (steps_extractor_back); ncua (200); hoist.step (posThree+lob); ncua (200); extractor.step (steps_extractor_out); ncua (200); hoist.setSpeed (100); hoist.step (-grab); ncua (200); extractor.step (steps_extractor_back); ncua (200); hoist.setSpeed (600); hoist.step (-posThree); Serial.begin (9600); Serial.println (0); Serial.end (); }}

Kauj ruam 3: App

App
App

Lub app kuv tau tsim yog ua hauv VisualStudio 2017.

Nws yog lub Windows ua daim ntawv thov uas hauv qhov no suav nrog SQL-database.

Cov ntaub ntawv muaj 3 lub rooj uas muaj cov ntaub ntawv ntawm tus neeg siv, qhov chaw ntawm txhua lub tshuab thiab cov ntsiab lus ntawm txhua lub tshuab.

Thaum pib lub app koj nkag mus nrog koj lub npe thiab pw.

Tom qab ntawd koj yuav xaiv lub tshuab twg los ua haujlwm thiab cov ntsiab lus ntawm txhua lub tub rau khoom yuav muab rau koj.

Tom qab ntawd koj tuaj yeem yooj yim nias "tau txais tub rau khoom" thiab lub tshuab yuav tau txais lub tub rau khoom thiab koj tuaj yeem hloov kho tus nqi ntawm cov khoom uas koj tau coj lossis xa hauv.

Pom zoo: