i love how you explain the code layer by layers, really good teaching, thanks a lot
@marios_ideas Жыл бұрын
Thanks:) Sorry for a late reply. I just came around to answer all the messages from my viewers:)
@KuyaMagik8 ай бұрын
Can you help me program an arduino with my bill acceptor? TheTB74? is there a way to contact you
@marios_ideas8 ай бұрын
To be able to help you with something like this I would have to have this module, and I don't . Also I looked at the spec. It is quite complex to set up any given currency. It will take a lot of time to figure this out and I have plenty other projects videos I commited to, and very limited time to deliver them:(
@georgijetanasic33573 жыл бұрын
13:08 You put 2 euro inside, but the value increased by only 1. I have Arduino Uno and 16x2 LCD. I will order coin acceptor and try to make it. So, I have one question. I want to have GUI on touchscreen display. So do I need to connect Arduino to Raspberry or I can do everything with Raspberry(To connect coin acceptor directly to Raspberry)?
@marios_ideas3 жыл бұрын
This is a wrap up footage,. At the beginning I had an issue which was fixed. And when I was selecting footage for the conclusion I chose it from a wrong file:) if you work with raspberry pie you should write the code for Rasbery pie. I unfortunately have no experience with that microcontroller
@KuyaMagik8 ай бұрын
Is there way to make a free play button with this type of coinslot?
@marios_ideas8 ай бұрын
Just like the display to show the recignised coin value you can add any other that you want and program its logic, including buttons
@heno_30983 жыл бұрын
An error occurred at time 13:10, after insetr 2€ coin the display shows adding value 1€. The question, then, is whether the Chinese validator is a scrap or is present a bug in the arduino program. I also don't like the fact that the response after inserting a coin after displaying the status takes too long ...
@marios_ideas3 жыл бұрын
Well I think the coin acceptor is ok. I had rare issues when writing the initial code where a single impuls was resulting in runnig the interrupt function more then once . I realised that after filming the footage. This led me to introduce variable "i" to eliminate this. I reshot some of the footage after that change.I had this issues with interrupts on other projects. Now I cannot tell you if the use of "i" did not fully eliminate the error or I used the previously filmed footage that contain the error . Now , knowing more I would do it differently. I would use millis() inside of interrupt function to make sure there is proper time interval between impulses. I already used in my other videos. e.g. kzbin.info/www/bejne/b5KYomCueduNh9U go to 4:55
@heno_30983 жыл бұрын
@@marios_ideas Therefore, I do not use sw arduino, but I write in assember directly. It is very fast and reliable. The point is to measure the time it takes for the finding how long pulse to last after the interrupt is triggered, as MCU can also find some short-term interference as a pulse and it has a short length of log0 (less than 90mS). Consequently, if the pulse (log0) lasts more than 90mS continuously, but a maximum of 110mS (according to the validator setting to 100mS length of one pulse), then the length is checked for how long it lasts (log1) and only then it is decided whether it is 1 pulse in this in the case of a € 1 coin or a further decrease to log0 continues and it will be 2 € 2 pulses, etc. Everything is decided no later than 110mS after the end of the last log0.
@marios_ideas3 жыл бұрын
Heňo _ writing code in assembler is way over my head. Last time I did it back at the university which was a long time ago. I will probably do follow up videos where I wold use millisecond and put the coin acceptor to a test loading large number of coins in sequence to see if I can fix this problem , assuming that it is not the old video footage problem.
@heno_30983 жыл бұрын
@@marios_ideas Long ago in Poland? I've never seen a university from the inside. I graduated from an apprentice high school under socialism in the Czechoslovak Socialist Republic. But these things were already a necessary basis at the time, perhaps then the demands declined.
@markdemasseur Жыл бұрын
Hi this coin acceptor doesnt keep credit for arcade machine. So when you press play then there will be used 1 credit and other credits keeping on the memory. Is it possible to make something with arduino a project like this.?
@laurentiujinga55583 жыл бұрын
Thanks for the info on coin mechanism, exactly what I was looking for. 👌
@marios_ideas3 жыл бұрын
I had some issues at the beginning . I did not use resistor or I had fast impulses chosen on the device. This error is in the wrap up where I used footage that still got an error without realizing . Thanks for subscribing
@laurentiujinga55583 жыл бұрын
@@marios_ideas I have seen on another answer. Thanks
@alirezashirazifard8990 Жыл бұрын
This is the best video to watch for set up coin drop. Others are mute
@StreamMovieYT Жыл бұрын
Thx worked with HX 916 and i wanted to ask how you do the price so for example i have a flipper and when i press start it does -1€ but if its under it doesnt start pls do a tutorial thank you.
@MiguelHernandez-zv8ne Жыл бұрын
could you solve it? ... I also have the same model.
@jamalsaid7158 Жыл бұрын
@@MiguelHernandez-zv8ne yeah it worked I'll send the code when it's done and use it for Arduino it put it on the computer but it still not with start thing if we found a solution we will tell
@pierluigizagaria Жыл бұрын
Thank for the video, I have a question. If the board has built in pull-up resistor, there is no need for the external one right? How does the coin-acceptor signal work? Sends pulses of 5v?
@mtraxx Жыл бұрын
Hi, Can this coin acceptor directly control the cy-822a type circuit?
@marios_ideas Жыл бұрын
I am sure you can but I do not have experience with CY-822a
@kurtiii Жыл бұрын
thank you so much! I searched so long for a video like this!
@marios_ideas Жыл бұрын
You welcome:) Consider supporting my chanell.
@hudabert4074 Жыл бұрын
what the purpose of connecting 5v with the 10k ohm resistor to the coin pin in the D2 pin? isn't the coin pin alone will give the signal (voltage) when inserted coin is detected? please enlight me.
@henrylaredo5 ай бұрын
thanks for the video, just one question, are you assuming the "i" variable inside "loop" function is incremented each 1 milisecond?
@marios_ideas5 ай бұрын
This was just my way of making sure there is a break in between interrupt execution. At that stage I was not aware of millis function. Now I would replace the mechanism with i variable with using millis to check how many ms passed inbetween impulses
@semiplex97278 ай бұрын
Hello Mario, First, great Video! Thank you. I just brought this Coin Acceptor after I watched your Video and today I played around with it. I'm working on a Cady machine for Kids (ofc not for permanent usage. The Kids need to do different Task like collecting trash to get a Coin. It's for an event). So, I trained all my Coins and connected a LED between Ground and the Counter Pin, that was working as expected (Blink Whenever a Coin is inserted and also in different repetitions). But when I connected the LED to Ground and Coin Pin, it just turned the LED on even tho it's on Normally Close. I expected a Consistent Blinking like a Clock where I can Orientate the Counter Pin to. My plan was to use 2x optocoupler. I'm not new in Programming but I'm (very) new to electronic and to be Honest, I didn't understood that much when it came to connection. It seems like you connected the Coin Pin directly to the Arduino, in my Case it would Fry my ESP8266 or I am wrong (that's why I also wanna use optocoupler)? I don't understand, I hope someone can Explain me this in a way that every dummy will understand this.
@samzmann Жыл бұрын
Thx. Very useful video! Any idea how to disable the buzzer/beep that sounds when coins are accepted?
@erickroeger11618 ай бұрын
I remember working on one of these but at the time there was something finicky about it (output value? i think cant remember this was years ago) anyhow had to solder wires to the 6 leds to get the correct feedback rather than detecting the usual impulses, i think its because the impulse were too slow when the user inserted coins quickly and therefore you get mixed of impulse. Like if I had a quarter that had 5 impulses but then I inserted another coin While those impulses were still sending out, I'd get higher amount of impulses. This additive feedback isn't practical for real world usage.
@NicodemusT6 ай бұрын
Hey there, could you explain? I have 6 leeds, too - and most of them seem to carry 12v for some reason. I am also finding the pulses finicky.
@erickroeger11616 ай бұрын
@@NicodemusTSo pules aren't at all reliable because they add on top of each other due to the fact that they're being measured by the m/s (or whatever); this is why, for example, when you insert a penny (1 pulse) and QUICKLY insert a nickle(2 pules) you end of with 3 pules as an output. Its a bad design because your essentially working with one variable when you need 6 distinguished variables for each coin. (idk about the 12v thing but) You'll can hackishly opt to detect the voltage change in the leds themselves by soldering a wire to the pads and use that to distinguish which coin was inserted. Mind that this was a long time ago I can't remember much working with Arduino but maybe I can dig up some links I found; if I can I'll post again later if i find them.
@Lennings82 Жыл бұрын
seems like it counts quite odd if i put in coins too fast. Is it a way ti activate the coin reject between the coin inserts? so if I put it in to fast it will come out again.
@sploopvrdavao463111 ай бұрын
What is the difference between the COIN and COUNTER pin?
@mikawiemers85589 ай бұрын
I think that each accepted coin gives one pulse to COUNTER-pin, that can be connected to a coin counter (counts number of coins, not value) and the COIN-pin gives out the predetermined pulses per different coin inserted. Like in this video 2€ - 1 pulse, 1€ - 2 pulses, 0,50€ - 3 pulses etc. COIN-pin pulses are to determine how much money has been inserted and COUNTER-pin pulses how many coins have been inserted (not sure if it counts all coins or only accepted, probably only the accepted)
@msindisimtengwane94563 жыл бұрын
This was a great video man. Very detailed. Love it. Thank you for making it.
@marios_ideas3 жыл бұрын
Glad you liked it!
@fabi_02027 ай бұрын
Good video! But my coin acceptor beeps with every pulse when a coin is inserted. Is there any way to disable this?
@reamonlinnabary97493 жыл бұрын
Great video!!! It is very helpful, especially since the box doesn't come with any instructions. Thank you!!!
@marios_ideas3 жыл бұрын
Thanks for watching!
@Lennings82 Жыл бұрын
hi.. are trying to get this to work. but if i the setup running for some time i can see that it self trigger on the coin puls. is there a way to fix this??
@gadfay8463 Жыл бұрын
We should add an Eprom (external) ? What happen exactly after 100000 times ?
@rohamtavakkoli7562 Жыл бұрын
Very informative. Do you know if the acceptor outputs RS232? The manual mentions that it does, but I'm not sure if external hardware (a conversion board maybe) is needed if an Arduino is not used
@marios_ideas Жыл бұрын
I cannot really comment on that
@khunden3 жыл бұрын
What is the logic of the counter pin on the coin acceptor? Is it a logic high and drops to logic low when a coin is accepted?
@marios_ideas3 жыл бұрын
This is a GREAT question. When I was researching this topic I couldn’t find anything and Chinese instruction I got was useless. Maybe someone can chip in here:)?
@asllovett5208 Жыл бұрын
I tried programming my coin acceptor and did all that you say but after the programming, the LED displays from E to 0 instantly. I wasn't able to turn off the coin acceptor when the display is at E. What happened here?
@youssefyoussef2517 Жыл бұрын
I have the same in a beverage dispenser but when I unplug the dispenser, I have to redo the configuration from the beginning, will you have a solution? THANKS
@iam7262462 жыл бұрын
when it arrives at the price of the product, how to activate a relay so that it delivers the product? And in case you want to add a hopper to deliver change, what would a code example look like?
@marios_ideas2 жыл бұрын
This is a hobby for me. And you probably are seeking a comercial use. Did not use hoppers so cannot really help here.
@nithinchandran38072 жыл бұрын
Broo can you include a vending moter also into the circuit, so that for a particular fixed total value , the arduino will trigger the vending moter and reset the total value for next count. Can u give code and circuit Diagram for that , it will be so helpful.
@boiyfact4918 Жыл бұрын
Sir i want to contact you . Please. I want help in a project
@peacerobertozitha300811 ай бұрын
Do you think it would be possible for me to add PS4 controllers to a 5V relay module and code the esp32 that each time the Coin collector recieves a R5 coin (ZAR) it switches the PS4 controllers on for 10 minutes ?
@semiplex97278 ай бұрын
I don't think this will be a Problem, whenever a R5 Coin is detected, open the Relay for 10 Minutes.
@gadfay8463 Жыл бұрын
Hi friend! Sensitivity? What is it exactly? How you can set it for 10 cents ( for exemple). Thanks
@johannesrose73243 жыл бұрын
What can you do with the outputs NC and NO? Can the device also count itself and e.g. only give a signal after $ 7 has been inserted? So without an external evaluation?
@marios_ideas3 жыл бұрын
The device just recognises coins and output the defined number of impulses per each coin. Does not have any more built in logic. Any additional behaviour has to be coded, like counting the total, reacting to any particular amunt entered etc
@EC-TPavithiravalavan Жыл бұрын
Really a great video. Greatly explained 👍
@marios_ideas Жыл бұрын
Thanks:) Consider supporting my channel:)
@fuoto2 жыл бұрын
The guide looks perfect. I just don't know how to program if one button on vending is pressed then the program should indemnify the amount specified. What if I have 2 different buttons. Every button should indemnify a different amount. And if there is not enough money machine should not do anything. Please help.
@marios_ideas2 жыл бұрын
Well. I cannot write the code for you. You need to introduce one or multiple buttons and write the code for them.
@spacegoogie Жыл бұрын
My unit will at random & automatically deposit coins into my pinball cab. and I can't figure out why. All my stuff is wired up correctly. Anyone have any input on this for me?
@lisserkc6000 Жыл бұрын
Mine lets some coins trough without it actually seeing the coin, it even does this when the power is out. Do you maybe know how to fix this?
@marios_ideas Жыл бұрын
You mean it goes through like it was recognised and is not returned in the return slot.? In this case it seems to me that there is a problem with your acceptor
@patrycjaferuga9783 Жыл бұрын
Czy dałoby się zaprogramować to jakoś, aby przyjmował złotówki? albo jest może jakiś zamiennik CH-926 który przyjmuje złotówki?
@marios_ideas Жыл бұрын
Czy aby na pewno obejrzałas cały ten film?:) Tam jest cała procedura uczenia tego urządzenia rozpoznawania monet. Jakie to są monety to nie ma znaczenia
@GorkemYildirim4 жыл бұрын
Nice one. I haven't seen this before. Thanks for your efforts.
@marios_ideas4 жыл бұрын
I am glad you enjoyed it:)
@GorkemYildirim4 жыл бұрын
@@marios_ideas subscribed
@marios_ideas4 жыл бұрын
@@GorkemYildirim Thank you
@smappdooda2 жыл бұрын
What voltage does the unit pulse when a coin is inserted? 12v or 5v?
@marios_ideas2 жыл бұрын
5v
@Rippafratta5 ай бұрын
@@marios_ideas I know I'm late: 5 Volts because of the resistor? So, without resistor it would be 12 Volts, right?
@marios_ideas5 ай бұрын
@@Rippafratta No I think it is 5v as there are no 12v microcontrollers . The device requires 12v to work but the signal pin has 5v
@gloryvidalr33132 жыл бұрын
How do I put the price so that it adds up the coins and can be used? I mean, when add coins and get enough to play. How to define it?
@ClbnaVGM2 жыл бұрын
Do you know how to connect it to those cheap "zero lag" usb encoder please ?
@marios_ideas2 жыл бұрын
What would be the role of that encoder? Send me the link to that part webpage
@ClbnaVGM2 жыл бұрын
@@marios_ideas It's pretty generic so I wont be able to find a webpage. Here's a video however : kzbin.info/www/bejne/jYLLZKuoicRnbaM This board/encoder receives impulses from on/off microswitches (arcade buttons). My goal is to put the coin acceptor into a diy Raspberry Pi Arcade Cabinet.
@fuaduddin18113 жыл бұрын
Can someone suggest a coin operated smart plug solution? Would like to make a washing machine coin operated using a smart plug.
@alexherrera7568 Жыл бұрын
Is it possible to replace it with an 16x2 LCD? thank you
@marios_ideas Жыл бұрын
The choice of the display is entirely up to you. The display is for outputing the number . You can also use oled displays e.g like in other project of mine kzbin.info/www/bejne/qZaneGZjlt-Xjq8
@alexherrera7568 Жыл бұрын
@@marios_ideas how it would change the code?
@marios_ideas Жыл бұрын
I can't write the code for you:) @@alexherrera7568 You can find the tutorials on how to use LCD displays. It is really not that complicated.
@honelicious1274 жыл бұрын
how we can add a digital pin to trigger the added relay to turn off when the time is zero? ty
@marios_ideas4 жыл бұрын
Not sure I understand. What time are you talking about.
@honelicious1274 жыл бұрын
@@marios_ideas i mean add some relay to trigger when time is end. Please
@MrWolftamer2 жыл бұрын
Thank you very very much! I now know how to program! Instructions that came with mine were very vague.
@marios_ideas Жыл бұрын
My pleasure:) like the video and subscribe to my channal. Also consider supporting it.
@Apothyxis Жыл бұрын
How would I set impulse if I want two of the same coin to equal one credit?
@marios_ideas Жыл бұрын
The impulses are for recognising the coin. How would the coin be calculated into credits is configured in the code.
@knerduno59423 жыл бұрын
I am revisiting this project after realizing the Arduino is just too slow in response. Even upping the BAUD rate did not help. If you insert the coins in too fast it throws the application way off, and cannot recover. With that, I looked for something faster. I decided to try an ESP32. So looking even closer at your code and the diagram, I have and issue now maybe you can help with. I see you are using Digital Pin 2 connected to 5 volts, 10k resistor, and to the coin accepter. Looking at the code, I see nothing in there checking for pulses on Pin 2. How is the code getting the pulses?
@marios_ideas3 жыл бұрын
I am using interrupts in the code. Arduino nano and uno have 2 pins with interrupt functionality D2 and D3. You would need to check my tutorial kzbin.info/www/bejne/oX7Xg6CgbqmGaKs but also this is mentioned in the coin acceptor tutorial as well
@Jandroverse Жыл бұрын
Nice project however, you will overflow "i" after a certain period of time when no one is using the machine. it would work fine just by adding if(i>=50){ i=0; }; add that at the end of the loop and it will eliminate your problem.
@marios_ideas Жыл бұрын
Well i didn’t know much about anything then :) i i actually not needed. I t would be much better to use millis function instead to measure the delay
@Jandroverse Жыл бұрын
@@marios_ideas yep…that was going to be my other suggestion. Either way great project and very good explanation!
@lyricalworld3603 жыл бұрын
Any idea about coin acceptor with timer control Please help ❤️
@GenreFluid3 жыл бұрын
Would I still need an audino with a raspberry pi 400
@GenreFluid3 жыл бұрын
I want to make my raspberry pi 400 coin-op boot so I have to earn pocket money to run it
@marios_ideas3 жыл бұрын
Rasbery pi is different type of controller so you do not need Arduino but also my code would not work on Rasbery pi. You can apply the concept but I presume you have to write whole new code for rasbery pi. I have never worked with those controllers so cannot really help
@BasitMirzaChannel5 ай бұрын
Hi. Can you program for me for a weight machine kindly?
@ChinoBuchonMX4 жыл бұрын
This video is amazing, outstanding work and very good code, congratulations man
@marios_ideas4 жыл бұрын
Thank you:)
@boutrazaata27144 жыл бұрын
Arduino UNO R3 will it also be compatible with your set-up
@marios_ideas4 жыл бұрын
Yes
@boutrazaata27144 жыл бұрын
@@marios_ideas I'll give it a shot (Thank you)
@knerduno59424 жыл бұрын
I finally got all the parts and have it all assembled. Now in the Arduino code, I see there are five different libraries to pick from. You did not mention which one you are using.
@marios_ideas4 жыл бұрын
In the code at the top I have following library declaration #include #include #include
@knerduno59424 жыл бұрын
@@marios_ideas Yes, but in the Arduino IDE, there are five different libraries. Using the search for TM1637, it shows five and turned out to be #3 in the shown choices.
@marios_ideas4 жыл бұрын
@@knerduno5942 Check my video kzbin.info/www/bejne/fXm5fpWbm92Nqpo where I show which one I installed
@knerduno59424 жыл бұрын
@@marios_ideas thank you kindly
@knerduno59424 жыл бұрын
@@marios_ideas I think a good followup video to this would be using C# or C++ to get the data from the serial port while the Adruino is still connected, and displaying the data in an application
@gennarogrosso21033 жыл бұрын
Hi, I would like to be able to program the coin operated 616, similar to 926, inserting 3 coins from € 0.50 Send a single impulse, is it possible? Thank you.
@gennarogrosso21033 жыл бұрын
Hi, I would like to be able to program the coin operated 616, similar to 926, inserting 3 coins from € 0.50 Send a single impulse, is it possible? Thank you.
@marios_ideas3 жыл бұрын
Do not fully understand the post. “3 coins from € 50”?
@gennarogrosso21033 жыл бұрын
I explain myself better: By entering 1 coin from 2 € Scheduled for a coin for a single impulse. I would like to get a single pulse cumulating insertion of 2 coins from 1 €. it's possible? I can not do it. Thanks for your help.
@marios_ideas3 жыл бұрын
@@gennarogrosso2103 one tyle of coin has a definiendum number of impulses. Yo can program it for 1 Eur to have one impuls or more . It aloes you to program up to 8 coin types
@gennarogrosso21033 жыл бұрын
@@marios_ideas May I cannot explain to me. Help me please. I have a small moon park, a game measures the strength by pulling a fist, every game on the game costs € 2. The programming is done so, I would like to get the same thing if in the coin holder they introduce 2 coins from 1 €, making the sum, 1 € + 1 € = 2 €, I should get a single pulse or, just one fist to measure strength. I am looking for confidence.
@Nico-pb1sr Жыл бұрын
Where is the arduino receiving power from?
@marios_ideas Жыл бұрын
In the video if I am not mistaken I was powering Arduino from USB port of the PC or from the powerbank. However if you want to have a single power supply then you need 12 powere supply which powers the con acceptor but also connects to VIN and GND pins of Arduino. VIN pin is regulated down to 5V. Caution. Do not connect 12V to 5V pin as this will positively fry the microcontroller.
@Nico-pb1sr Жыл бұрын
@@marios_ideas doesn't the coin acceptor have a current spike when a coin goes in? Will this affect the Arduino if on the same power supply?
@laohanme72813 жыл бұрын
why my incomingImpuls always keep increasing without any coin insert?
@marios_ideas3 жыл бұрын
Your device may be faulty. What do you mean by increasing?
@mihaislabutu8146Ай бұрын
Hi guys, can someone please help me? I have this coffee machine, and I want to install a coin acceptor to collect coins for every beverage it produces, but I'm having a hard time trying to understand how to program the coin acceptor to unlock that certain beverage selected. For example, I want to insert 1 coin for a beverage, and by that way, when I select the beverage I want, it will ask for that 1 coin to be inserted to allow for the beverage to me made. I feel like something is mission from this equation.
@feendios5772Ай бұрын
You need an arduino uno
@feendios5772Ай бұрын
For do that you need microcontroller or arduino takes one and program it
@jamalsaid7158 Жыл бұрын
Finally a good video
@marios_ideas Жыл бұрын
Thank you:)
@jamalsaid71586 ай бұрын
Btw how can I get the 3d printed plate? been searching on STL finder and found nothing@@marios_ideas
@sklepa4 жыл бұрын
Dzięki za film, fajnie wszystko objaśnione. Mam tylko taką zagwozdkę: zakładamy że licznik "i" zwiększa się o jeden w każdej pętli, i do póki w pętli nie ma nic innego niż zliczanie monet to jest ok. Później jeżeli dołożymy więcej kodu typu obsługa komunikacji i jakichś peryferii, pętla zacznie zwalniać i mogą pojawić się problemy. Czy dobrze rozumuję?
@marios_ideas4 жыл бұрын
Masz absolutną rację. Niestety uczę się na bieżąco. Zmienna I wykorzystywana byla do zbudowania stworzenia ok 300ms przerwy które mowi nam ze to juz koniec impulsów i można rozpoznać monete. Jesli sprawdzisz moje ostatnie filmy to bedziesz widzial te o wykorzystaniu millis. I tu jest wlasnie idelane zastosowanie. Zmienna i i liczenie do 300 powinno byc zastapione funkcja millis. Czyli wrzucamy monete. Zapamietujemy czas i ponownie sprawdzamy czas z millis w petli i jesli bedzie wiecej niż umowne 300ms to moneta jest rozpoznana
@sklepa4 жыл бұрын
@@marios_ideas I tak też bym to rozwiązał :) też jestem amatorem, tak tylko mówię. Pozdrawiam!
@marios_ideas4 жыл бұрын
@@sklepa Sam fakt ze robilem te filmy o millis pokazuje ze tez dręczyło mnie take zastępcze rozwiazanie. Jak zerkniesz na film o nastawianiu alarmu w budziku tam tez jeszcze nie stosowalem millis:( I teraz bym to chetnie poprawil.
@GeekBoy034 жыл бұрын
What is the purpose of the 10k resistor?
@marios_ideas4 жыл бұрын
From my video you probably got the idea that I come from the IT background and I learn electronics as I go. When I got this coin acceptor I checked online how other connected it and quite a few diagrams I got had that resistor. Since I didin't have a datasheet as such for this part I conencted it through this resistor and it worked. I am not sure if it is needed but didn't want to risk destroing the part I waited one month to arrive:)
@GeekBoy034 жыл бұрын
@@marios_ideas Thanks for the response. I have the 8 coin version. I had also bought a special device which converts the pulses to serial hexidecimal, but it seems to be a bit over complicated, and lacking the ability to connect the coin counter. This Adruino nano makes it a much better choice (and cheaper). Thanks for putting this up.
@TheEPROM93 жыл бұрын
Handy, was able to set up main as the instructions that come with it are about as clear as mud.
@marios_ideas3 жыл бұрын
Glad my video was helpful
@robbiezxc4 жыл бұрын
Hi can you please show how to add a function to the code so something can happen at a certain amount of money like when you have put €2 in an led could light for a set period of time and then turn off but repeats when the next to €2 value was put in thanks 😀
@marios_ideas4 жыл бұрын
Connect LED e.g. to PIN6 #define LED 6 In Setup pinMode(LED, OUTPUT); digitalWrite(LED,LOW); And then in Loop function if(total_amount==2){ digitalWrite(LED,HIGH) You can connect anthing to this pin. E.g. magnetic lock.
@robbiezxc4 жыл бұрын
@@marios_ideas one more thing if you don't mind how do I get the light to stay on for 5 minutes and then turn off but turn back on again once another €2 has been entered
@marios_ideas4 жыл бұрын
@@robbiezxc I will put short code for you tomorrow
@robbiezxc4 жыл бұрын
@@marios_ideas thanks I'll send you a tip when I get payed
@marios_ideas4 жыл бұрын
The code using millis function which return number of milliseconds that passed since the program was started. I have a separate tutorial on this. #define LED 6 long Timestamp_2EUR=0; // records time when 2EUR was reached In Setup pinMode(LED, OUTPUT); digitalWrite(LED,LOW); And then in Loop function if(total_amount==2){ digitalWrite(LED,HIGH) if (Timestamp_2EUR==0) time_past=millis(); // if Timestamp_2EUR is 0 means we just reached 2EUR so we record the timestamp // if it is yet another loop run with 2eur reached Timestamp_2EUR is not changed } if (millis()-time_past>300000){ // 300000ms is 5min. We check if the 5 min was exceeded digitalWrite(LED,LOW) // LED off total_amount==0 //reset the balance
@osamasegh87374 жыл бұрын
Thank you so much for this video, it is great. You helped me a lot to understand the code. Good Continuation ...
@marios_ideas4 жыл бұрын
Thanks. I will be doing more tutorials in the future. If you want to check them out, subscribe to my channel:)
@osamasegh87374 жыл бұрын
@@marios_ideas I'm already subsecribed ... You have a simple and fluent method to explain ... I will fellow your works to learn more about arduino programing ... Best Regards.
@arshathossain80613 жыл бұрын
Same 2 coin use to 1 puls, is it possible
@marios_ideas3 жыл бұрын
Generally it is possible in two cases: First one is if your code is not properly counting impulses. In my code I assumed the impulses are lass then 30ms apart if I am not mistaken , if your device has a different interval. Some have even a switch to control that interval. Fast midum and slow. If code does not correspond to the actual device setup then you can imagine two impulses are interpreted as one. The other case maybe if the learning process was not properly performed e.g you did not use the right sample amount or cheated the process by using the same coin over and over again and you have coin types that are similar. Then the device maybe confusing the types.
@AFerreira19773 жыл бұрын
Olá. Dado que já ando um pouco perdido e desesperado...venho pedir aos entendidos na matéria, solução para instalar corretamente este moedeiro de arcade (JY - 926), com correspondente ligação à placa “Zero delay”. Consigo configurar moedas, contigo, não consigo que adicione créditos (não dá pulso). Eternamente grato! Muito obrigado 🍺
@alperduran554 жыл бұрын
Does this work with LCD DIsplay I2C Module ?
@marios_ideas4 жыл бұрын
The dopłat is used just to display the total. Any display can be used but the code would need to be adjusted. I have not used LCD in the past but i do’t imaginacji this would be complicated. Just a change to few lines of code
@alperduran554 жыл бұрын
@@marios_ideas So u couldnt help me to change these few lines of code :(
@marios_ideas4 жыл бұрын
Optimus Prime I would need to first get my hands on LCD display. And play with it
@alperduran554 жыл бұрын
@@marios_ideas okay, but thanks for your answers
@marios_ideas4 жыл бұрын
Connectity like here: howtomechatronics.com/tutorials/arduino/lcd-tutorial/ You do not have to connect potentiometer Then in code: #include // includes the LiquidCrystal Library LiquidCrystal lcd(1, 2, 4, 5, 6, 7); // Creates an LC object. Parameters: (rs, enable, d4, d5, d6, d7) in setup function lcd.begin(16,2); // Initializes the interface to the LCD screen, and specifies the dimensions (width and height) of the display } And the replace if(total_amount
@skostasx10 ай бұрын
bu güzel videonuz için teşekkür ederim.
@wanzn4717 ай бұрын
please make another adruino coin acceptor video with real life aplication , like controlling kids toy car or anything that based on timer countdown
@richardgarcia59264 жыл бұрын
Can you do a coin counter using a coin hopper?
@marios_ideas4 жыл бұрын
Is this the device where you have different slot sizes through which coin drops and this way it gets recognised? I have many projects already planned so even if I will look into this one it will not be in immediate future
@marios_ideas4 жыл бұрын
Aaaa .. just checked what the coin hopper is. Cool looking device. I will do some research. Currently I have no revenue from this channel so I am scaling down on new items bought. But in the future I may look into it.
@carlosbasques42782 жыл бұрын
Hi. Congratulations for this video. It's possible do convert coin input to rest api? I would like to create a digital wallet to my child.
@GusNando3 жыл бұрын
Thank you, it's very helpful 😁
@marios_ideas3 жыл бұрын
Give it a like if you liked it and found it useful. Would mean a lot to me
@user-be6ls6ox3e10 ай бұрын
please i need the fisrt library in the code
@marios_ideas10 ай бұрын
Which library?
@PawanKumar-ct9qe4 ай бұрын
Great video Can you let me know where i can bough thei coin acceptor
@marios_ideas4 ай бұрын
On Aliexpress. Sample link pl.aliexpress.com/item/1005006080235293.html
@othall9949 Жыл бұрын
Mario i love this idea, i have a project that i would love your help on if you're interested, it involves the coin acceptor you're working with
@danielmiller59673 жыл бұрын
At the sampling phase my coins are not recognized. Can anyone help?
@jbm1682 жыл бұрын
Hello and thank you for your explanations. How can we do a total reset please? Thanks in advance
@marios_ideas2 жыл бұрын
By starting a new setup you reset all previous settings
@和氣-p2x3 жыл бұрын
When the coin is inserted too fast, an error occurs and cannot be judged
@marios_ideas3 жыл бұрын
I did not experience this. This can be an issue with amount of samples when calibrating the device
@knerduno59423 жыл бұрын
After a hiatus, I have come back on working on this. I just recopied the code, and readjusted the pulse counts and total amounts to reflect my needs. i.e. if (i>=30 and impulsCount==2){ total_amount=total_amount+2; Looking at the serial monitor, I can see the total pulses being counted, but the variable "total_amount" is constantly staying "NaN" even before a coin has been inserted, though I do see you have total_amount already set to 0. This means the display goes to 0 when turned on, and never changes from 0. Any ideas on this?
@marios_ideas3 жыл бұрын
Sorry for a late response but I was skiing this week. Before I can answer you have to clarify. Not sure what you mean by "NaN" This is an float type so it should always have a numerical value. And I do set the initial value to 0 ., so this seems strange to me.
@knerduno59423 жыл бұрын
@@marios_ideas Hope you had a good time skiing. NaN is a response from the program, or computer meaning "Not a Number."
@knerduno59423 жыл бұрын
@@marios_ideas Someone in software development shoudl know about "NaN" when the system returns that as a value, or lack of. Here is a line of output from the serial console after just starting the application" i=533 Impulses:0 Total:nan
@solomizan4 жыл бұрын
Thanks! It helped me a lot.
@marios_ideas4 жыл бұрын
Glad you found it useful:)
@ishackfrg52274 жыл бұрын
Sir pls kindly do one video how to connect coin acceptor controll box in to auotomatic front and top load washing machine (how to set with coin acceptor)🙏
@marios_ideas4 жыл бұрын
Weel. you overrate my skills. I would be able to build a simple vending machine but hacking into existing washing machine to introduce coin acceptor is much more complicated
@MSIUser20123 жыл бұрын
I am not sure what exact functionality you want in this control box, but a simple idea that can make integrating this coin acceptor with an automatic washing machine. - You can use a relay module with the Arduino and coin acceptor to turn on the washing machine. For example, to use the machine, user must insert 50 cents in the coin acceptor. Once the coin is inserted and it is equal to 50 cents, then the relay is triggered and the washing machine is turned on for an specific amount of time. After that time passes, the washing machine will automatically turn off and the coin acceptor will reset the amount to ZERO. Again, this is just a simple idea and I haven't tried it practically. But I hope it would help.
@nestormarcelovenece50913 жыл бұрын
Very good work
@marios_ideas3 жыл бұрын
give it a like if you enjoyed it:)
@mdrashadrashad83573 жыл бұрын
My machine is jammed, coin not gat in??
@marios_ideas3 жыл бұрын
It must be mechanical problem which I cannot help you with. In unconnected state the coins pass through with no problem
@rcvtv38582 жыл бұрын
Good day sir can you make tutorials on how to change price in the arduino vendo machine using buttons? God bless ang keep safe always!
@akshaymane90274 жыл бұрын
Sir make a video on coin based water dispenser system👉👉👉
@marios_ideas4 жыл бұрын
I will be doing a wideo to control water pump to water flowers. As to water dispenser I can give you few guidelines. You can get cheap 5v water pumps on Aliexpress pl.aliexpress.com/item/32850821465.html You connect it to GND and the pin you want to control it with. When coin acceptor receives defined amount of coins you recognise it in the code and send the high signal to the water pump pin. You keep it High for as long as you have to to fill the water cup
@elektroaqua76304 жыл бұрын
Good job
@marios_ideas4 жыл бұрын
Thanks:)
@promediag Жыл бұрын
I just need to learn this
@LexGoPH3 жыл бұрын
in the in the incomingImpuls function shouldn't there be a "i = 0" above "impulsCount=impulsCount+1" too? that way, it doesnt read the first impulse as only 1 and add the value you set for 1 impulse?
@marios_ideas3 жыл бұрын
This is one major problem with this code. When I was writing it I was not yet familiar with millis function. The use of i variable is a workarund . each time impuls is detected we reset i to 0 in the interrupt function. Then i gets incremented in the loop function. If we have multiple incoming impulses they are close apart. Inbetween each impuls the loop function is executed less then 30 times and we keep increase impulse count. If all impulsess I read then Loop gets executed more then 30 times and then we know there are no more impulses and then we can positivly finish coin recognition process. If I used millis I can meassure the exact interval between impulses and this way I would not need I variable at all.
@4x4Tobi3 жыл бұрын
@@marios_ideas do we know the cycle time of your Arduino to get a feeling what these 30 times trough the loop stands for or even better do we know the exact interval time between impulses by now?
@marios_ideas3 жыл бұрын
@@4x4Tobi When I was creating this video I was not familiar with Millis function. This can replace this whole thing with counting cycles. Check my millies tutorial and you can then check the video I created for Eggtimer where I use millies in the interrupt functions to make sure I am not reacting to a single button press twice. This is the same concept I would use in corrected coin acceptor code if I was writing it now. I will be creating some Q&A videos and I may include it in it providing corrected code.
@smert_okupantam Жыл бұрын
10:42 why in the world total_amount is a floating point variable!? at which unholy point the amount turns into non integer ? why two other variable are "int" when they shold be "unsighned int" ? and variable "i" and "impulsCount" must be both declared as "volatile". Mario, you are such newbie.
@marios_ideas Жыл бұрын
I hear you... mind you this video is 3 years old and 3,5years ago I did not know what Arduino was. I learn as I go. Apart from the mistakes you pointed , using "i" variable to make sure the impulses are measured in a proper way is a complete disaster. I should have used millis instead. I would need one explanation from you though. Can you let me know why I and ImpulsCount need to be declared as volatile. Did not use that before so would be great if you could share some info on this
@smert_okupantam Жыл бұрын
@@marios_ideas variables which used within an interrups funktion schould be declared as volatile, because they may be removed by optimisator
@marios_ideas Жыл бұрын
Does it matter that they are also used in the main code
@smert_okupantam Жыл бұрын
@@marios_ideas yes, but you are not a newbie any more, so should do how it is right to give your visitor good learning
@steamplay294 жыл бұрын
Fajny filmik :)
@marios_ideas4 жыл бұрын
Dzięki:)
@chandandas20413 жыл бұрын
Awesome
@marios_ideas3 жыл бұрын
Give it a like if you enjoyed it
@Striyka3 жыл бұрын
Brilliant
@marios_ideas3 жыл бұрын
Give video a like if you liked it:)
@simpasmarykimberly.28742 жыл бұрын
can I have the components please? thank you :)
@marios_ideas2 жыл бұрын
All info is in the description . Go to the code link.
@Nkanyiso942 жыл бұрын
Hi I have 2 questions 1)Can I add a servo motor? 2)Does coin acceptor work with Arduino UNO?
@marios_ideas2 жыл бұрын
Yes and Yes:)
@Nkanyiso942 жыл бұрын
Can we chat privately via email, I'm struggling with programming functions. I would really appreciate your collaboration 🙏
@abeltiguaavellan11567 ай бұрын
link is down
@troymcdonald Жыл бұрын
Thanks
@khellafsamy3 жыл бұрын
THANK U
@marios_ideas3 жыл бұрын
You are welcome
@romekatomek21594 жыл бұрын
zainstaluj fizyczną blokadę po wrzuceniu monety "zasówka / zaślepka " - nie będziesz miał monet wrzuconych "so far"
@marios_ideas4 жыл бұрын
Nie wiem czy rozumiem. Wyjasnisz? Jesli wrzucam do pewnej kwoty to chce dorzucac kolejne monety i je zliczac