10-30-2015 03:39 AM
Hello,
For our project at my school (2nd year electronics engineering) we are making a Blackjack dealer robot. Using LabVIEW and a webcam we would like to take a picture of the card he is going to deal, and then compare it to a database we made beforehand so the program knows what card it is dealing.
So what we actually want him to do is
-scan the card he is gonna deal (take a picture of it)
-compare it with our premade database of pictures of all the playing cards
-once he has the right info is obtained, channel it through to our program so we can count and whatnot with that number of card.
-he only needs to recognize the value of the card, not the type (i.e. has to know that it's a 4, not that it's a 4 of diamonds)
I haven't found a good solution yet, can anybody help us with out project? Any tips are kindly appreciated 🙂
Kind regards,
Vincent
Solved! Go to Solution.
10-30-2015 07:26 AM
Do you have access to the NI Vision Toolkit?
Positioning and alignment of the card will be key. From there you should be able to use standard OCR functions to read the numbers.
Sounds like a fun project.
10-30-2015 08:46 AM
I do have access to the NI Vision Toolkit. We have a pretty good system for the positioning of the card using a wheel that deals them out 1 at a time. It's comparable to this example YouTube - Robotic card dealer
After installing the NI Vision Toolkit, getting the webcam and the cards, what would be my next best move?
Thanks for the fast reply
10-30-2015 02:14 PM
From there, get some practice acquiring still shots using your webcam and defining ROIs. I don't have the Vision Toolkit installed at the moment but I believe it has a whole palette for OCR where you can send it your ROI and it will give you the text.
10-30-2015 06:08 PM
10-31-2015 05:04 AM
What SnowMule said.
My thinking process would be:
- ensure the card positioning is consistent
- create a ROI around the corner of the card, which usually contains the number and the symbol, with enough additional space to accommodate positioning tolerance
- pattern match on the suit symbol (you might as well!)
- OCR on the card number/letter, which will require a bit of teaching
With access to the Vision toolkit, have a look at Vision Assistant for your initial efforts. For more control, you could then move to Vision VIs.
10-31-2015 06:08 AM
Thanks for the replies!
Working with the Vision Assistant goes fine, I was able to implement the OCR on the numbers and letters to a point that it is reliable for our case.
I do have a software problem: for the Vision and Motion functions in LabVIEW (currently using 2015 version) I downloaded these drivers which my University provided http://www.ni.com/download/ni-vision-acquisition-software-august-2012/2975/en/
But the Vision and Motion functions still don't show inside of my LabVIEW? I re-installed them to make sure they are installed in the same directory, but it still didn't work..
Any help on this matter?
Vincent
10-31-2015 12:24 PM
Edit: I installed all the latest software and now everything works like a charm 🙂
10-31-2015 04:48 PM
So what I can do for now is:
In Vision Assistant:
-load in an image
-put it in a greyscale so i can apply OCR
-recognize the card that is in place
How can I automate this process/ put it in a LabVIEW VI? What is the best way to organize this?
The only thing I can do for the moment is snapping pictures with a VI...
Thanks in advance 🙂
11-01-2015 08:19 AM
@vincentmees wrote:
So what I can do for now is:
In Vision Assistant:
-load in an image
-put it in a greyscale so i can apply OCR
-recognize the card that is in place
How can I automate this process/ put it in a LabVIEW VI? What is the best way to organize this?
The only thing I can do for the moment is snapping pictures with a VI...
Thanks in advance 🙂
Learn how to program in LabVIEW.