What to use to make coin counter

Hi. I'm currently working on a project. I'm building a bill to coin changer. I have 3 tubes that stores different types of coins. I need to count the coins in each tube and display it.

What device should I use for the counting?

Thanks in advance.

Do you mean that you need to count the coins while they are at rest in the tube; OR while they are entering the tube; OR while they are leaving the tube.

It may be easier to count them entering or leaving (or both).

If you need to know how many coins are at rest in the tube then maybe weighing the tube (with a load cell) would be an option - but I suspect it would require a complex mechanical system that was simultaneously robust and sensitive.

...R

I did this in July 1994, see this link:- http://www.doc.mmu.ac.uk/STAFF/A.Wiseman/Acorn/BodyBuild/BB94.html

If you can get away with knowing when a tube is full, and when the last coin has been dispensed, that’s pretty easy to keep track of the in-between.

Use an led and opto, looking across the top of the tube.
When it’s blocked, the tube has ‘n’ coins loaded.

Software counts each coin as it’s dispensed.
A second led/opto looking down the tube will see the tube is empty, and confirm/notify there are no more coins left.

Mechanical fingers with microswitches may have some benefits with lint/dust etc.

There are quite a few options as Robin suggested, now it depends on budget, space and skill.

You’re in a fortunate place because you already know what the coins are - the job is just keeping track of them.

Like @GrumpyMike, i did something similar 20 years ago...
Using an optical bar - looking at coin diameter and coins/washers with the centre punched out....
The second step was also interesting, using an electromagnetic field to measure the reluctance/inductance of the metal slug as it passed the scan-point.
Each metal/mass has a different signature - so it was possible to detect lead, copper or other materials - even if they matched the geometry.

Fun project!