HOME ARCADE CHANGE MACHINE BUILD - BUILD YOUR OW CHANGE MACHINE - PT2

  Рет қаралды 1,529

Inside the Arcade - Nick the Arcade Expert

Inside the Arcade - Nick the Arcade Expert

Күн бұрын

Пікірлер: 11
@InsidetheArcade
@InsidetheArcade 4 жыл бұрын
CODE FOR ARDUINO: ----------------------- START CODE------------------------------- //Replace (Open angled bracket) and (Close angled bracket) with Angled Brackets Respectively.. #include #include int credit = 0; int creditdisplay = 0; const int hopperInt = 10; byte hopperDebounceDelay = 100; long lastHopperDebounceTime = 0; int previousMillis; int interval = 500; LiquidCrystal_I2C lcd(0x27, 2, 1, 0, 4, 5, 6, 7, 3, POSITIVE); void setup() { digitalWrite (8,HIGH); Serial.begin(9600); pinMode(10, INPUT_PULLUP); pinMode(8, OUTPUT); pinMode(9, INPUT_PULLUP); lcd.begin(20, 4); lcd.setCursor(1,0); lcd.print("CHANGE MACHINE v1.0"); lcd.setCursor(2,2); delay(1000); lcd.print("INSIDE THE ARCADE"); delay(3000); lcd.clear(); lcd.setCursor(3,4); lcd.print("INITIALISING..."); delay(3000); lcd.clear(); lcd.setCursor(3,1); lcd.print("INSERT COIN(S)"); lcd.setCursor(3,2); lcd.print("FOR 10p CHANGE"); } void loop() { //lcd.print("1"); int CoinVal = digitalRead(9); int HopperSense = digitalRead(7); //Serial.println(SensorVal); if (CoinVal == HIGH) { } else { credit = credit + 1; creditdisplay = creditdisplay + 1; Serial.println(credit); Serial.print(creditdisplay); Serial.println(" Credits"); lcd.clear(); lcd.setCursor(1,1); lcd.print("Coins to Pay:"); lcd.setCursor(14,1); lcd.print(creditdisplay); delay(20); } if(credit > 0) { digitalWrite(8, LOW); if (digitalRead(hopperInt) == LOW && ((millis() - lastHopperDebounceTime) > hopperDebounceDelay)) (Open Angled Bracket) lastHopperDebounceTime = millis(); Serial.println("CoinPaid"); credit = credit - 1; lcd.setCursor(1,2); lcd.print("Coins Paid"); lcd.setCursor(14,2); lcd.print(creditdisplay - credit); if(credit == 0) { creditdisplay = 0; digitalWrite(8, HIGH); delay(2000); lcd.clear(); lcd.setCursor(3,1); lcd.print("INSERT COIN(S)"); lcd.setCursor(3,2); lcd.print("FOR 10p CHANGE"); } } } ]
@maggajames
@maggajames 2 жыл бұрын
Should this code not be digitalRead(10) rather than digitalRead(7) since there is nothing connected to input 7?
@JuanFunQi
@JuanFunQi 3 жыл бұрын
planning to build this thank you for sharing your skills, new fan from UAE
@InsidetheArcade
@InsidetheArcade 4 жыл бұрын
🚨🎰🚨Subscribe to Get More Amazing Videos ➡️ @t 🚨🎰🚨
@loseruken
@loseruken 4 жыл бұрын
Some good skills there buddy
@InsidetheArcade
@InsidetheArcade 4 жыл бұрын
Thank you
@DJNESSY.
@DJNESSY. 4 жыл бұрын
I love it 😍
@InsidetheArcade
@InsidetheArcade 4 жыл бұрын
Thank you
@WorldwideArcades
@WorldwideArcades 4 жыл бұрын
Hi, would you be able to help me do this with a different hopper? I have an asahi seiko sh400
@djpaulbailey
@djpaulbailey 3 жыл бұрын
Hi I’m struggling to get this code to work on my arduino mega 2560, am I doing something stupid?! Could you help if possible please? I’m using an asahi seiko coin hopper. How does your code sense the hopper coin count and how does it determine what coin has been put in?
@TheNightjaguar
@TheNightjaguar 3 жыл бұрын
Hello I really like your video is awesome I have try to replicate your code but I keep getting an error with the LiquidCrystal_I2C.h library I downloaded added to my library Mist of them but keep getting No such file or directory Plz help
Who would pay $120 for a Raspberry Pi?
9:31
Jeff Geerling
Рет қаралды 288 М.
MAKE A CHANGE MACHINE  - MAKE YOUR OWN COIN CHANGER MACHINE - PT3
5:50
Inside the Arcade - Nick the Arcade Expert
Рет қаралды 1,3 М.
Непосредственно Каха: сумка
0:53
К-Media
Рет қаралды 12 МЛН
«Жат бауыр» телехикаясы І 30 - бөлім | Соңғы бөлім
52:59
Qazaqstan TV / Қазақстан Ұлттық Арнасы
Рет қаралды 340 М.
Маусымашар-2023 / Гала-концерт / АТУ қоштасу
1:27:35
Jaidarman OFFICIAL / JCI
Рет қаралды 390 М.
How to have fun with a child 🤣 Food wrap frame! #shorts
0:21
BadaBOOM!
Рет қаралды 17 МЛН
Stepper Motors with Arduino - Controlling Bipolar & Unipolar stepper motors
50:22
The BEST Mechanical Display You've EVER Seen!!!
13:51
Tin Foil Hat
Рет қаралды 560 М.
Seafront Arcade 10p Coin Hunt 1.1
17:18
Coins 2 Collect
Рет қаралды 13 М.
How does a USB keyboard work?
34:15
Ben Eater
Рет қаралды 3,3 МЛН
This small CRT monitor is less than 2" thick
31:45
Adrian's Digital Basement
Рет қаралды 354 М.
lucky day at 2p pushers machine
14:37
I'm just Greg
Рет қаралды 27 М.
This Damascus Knife Is Amazing , It'll Drill Its Way Into Your Heart
21:08
Photolithography on Silicon with PCB Chemicals
25:31
ProjectsInFlight
Рет қаралды 61 М.
The MOST Broken Computer? The 1986 Sinclair Spectrum+2
50:19
Mend It Mark
Рет қаралды 258 М.
Непосредственно Каха: сумка
0:53
К-Media
Рет қаралды 12 МЛН