Axiomatic Design of an automatic card dealing robot

When you’re playing card games with friends, a problem often occurs, at some point, no one wants to be the dealer. We propose an automatic card dealing robot. There are a few products on the market today that are expensive or missing critical functionality to fulfill the role of a card dealer. Our product will be more affordable and more portable than existing systems. The robot can be used in a variety of applications, for education, for the physically challenged, and of course for fun. The goal was to build a robot using Axiomatic Design methodology, with faster card dealing capabilities than a human.


Introduction
The robot described in this paper includes everyone in each game so that no one has to be the dealer. We believe there is a market for this novelty product since this is a reoccurring problem. The robot sits in the middle of a table, senses all players and deals cards. The robot will have a variety of games, ranging from Texas Hold'em to 52 pickup for up to eight players. The target customers are Millennials and card-playing enthusiasts. However, the robot can also function as an educational tool and for the physically challenged. Card games have been a part of human history since 800 AD [1]. We want to bring card playing into the 21st century with new technology.

Customer Needs and Constraints
The device should have a variety of games and execute each game correctly. The software for choosing games should be user-friendly. There are four main Customer Needs (CNs), they are described here below.    These CNs should solve the initial problem of the game coming to a stop because no one wants to be left out. Since this should be a marketable product, some constraints were implemented. For the device to be portable, it should weigh under 1 kg. For the product to sell, it should retail at a max value of 399 EUR. This max value was chosen because of the price of a similar product mentioned in section 3. e-mail: antonsigmars@gmail.com

Prior Art
There are not a lot of similar products on the market, although there are many home and school projects online. One product that is on the market is "Jack The Dealer" [2], see fig. 1. Jack The Dealer costs 399 EUR. It is hand operated from a control panel on the front of the device and has the added feature of card shuffling. There are also simpler devices like "The card dealing hand" [3] that shoots one card at a time, see fig. 2. There are a few patents related to the automatic dealing of cards. Most of them are attached to tables, e.g. US patent US6361044B1 [4]. None of them are similar to our device. The goal is to design a card dealer more automatic and cheaper than other products on the market. The retail price for the finished product should be between 250-280 USD. The idea is to sell it as a Do It Yourself kit (DIY). Making a DIY kit allows the buyer to assemble the device and in turn, brings down the manufacturing cost.

Design
The Axiomatic Design methodology [5] allows for a breakdown of complicated projects into smaller, manageable The card dealing hand [3] chunks. Axiomatic Design can be divided into two separate axioms. The first axiom is the Independence Axiom, which is used to maintain the independence of each Functional Requirement (FRs). The second axiom is the information axiom, which is used to minimize the complexity. While designing the device, the complexity level was kept at a minimum using the Information Axiom. By taking the four CNs mentioned in section 2, the corresponding FRs and Design Parameters (DPs) were created. The FRs and DPs are listed in The goal with this matrix is to detect dependencies between different elements that can cause complications; in other words, modularity is essential. The matrix shows a decoupling of the DPs, which means there is only one element dependent on another (FR 4 is dependent on DP 2 ). This dependency is because of counting the players at the table is done with a sensor. This sensor is fastened to the main housing of the device which rotates using a stepper motor. If the stepper motor is not working, the device will not be able to count the players. If the elements had been coupled, they would be dependent on each other [6]. A more visual and detailed representation of how the FRs and DPs function concerning each other is in the flow diagram in fig. 3. The flow diagram includes both the first level and second level FRs and DPs. With the diagram, we can narrow down the dependency between FR 4 and DP 2 into FR 4.2 and FR 2.2 , which makes it easier to solve. The arrow in the diagram represents the dependency.    Stepper motor range of rotation angle

FR 1 : Dispense cards
The DC motor needs to be able to dispense cards with close to 100 % accuracy, meaning that when the device is supposed to deal one card, only one is dealt. For this to work, you need a sticky rubber wheel (DP 1 ), and cards of a specific type. According to experiments, paper cards will not work well since the friction between them is relatively significant. Heavier plastic cards with a smoother surface have a lower friction coefficient. Using plastic cards increases the accuracy of dispensing the cards correctly from 80 %, with paper cards, to 99.03 % with plastic cards. The cards were tested by gliding them on a smooth surface, the further they the glide the better. A suitable deck of cards would be included with the device. The DC motor with the rubber wheel is used to push out the cards. If the cardholder is parallel to the ground, the whole deck may move forward when the motor is running and subsequently fall out on the table. This problem is solved by having the cardholder at an incline of 25°-30°, which will keep the deck in place. When a card is dealt out, the DC motor has to quickly rotate back so that the next card will not leave the deck because of the friction between cards.

FR 2 : Turn to each player
The ability to turn to each player is crucial to allow them to participate. For this requirement, a stepper motor is located at the bottom of the robot (DP 2 ). The motor is positioned so that the drive shaft is pointed down. That is so that no wires will get tangled in the drive shaft when it rotates FR 2.2 . Because of the positioning of the motor, all electronics can be on the same side of the drive shaft, simplifying the power distribution. Since the driveshaft is the only thing holding the device upright, a base plate is located at the bottom of the shaft for stability FR 2.1 .

FR 3 : Choose game
For the player to be able to choose what game to play, we created a simple web page interface (DP 3 ). The web page is hosted on the Raspberry Pi and can be accessed when the player is connected to the WiFi access point the Raspberry Pi is broadcasting. The website is straightforward to use and minimalist to avoid confusing the player. By keeping the website simple, it also makes it easier to upload more games in the future.

FR 4 : Count players
The sensor used to count the players is an Infrared (IR) array camera module (DP 4 ). The camera is accurate for up to two meters, which will then be the maximum distance a player may be stationed from the robot. The camera is fastened to the housing of the stepper motor and is therefore decoupled with FR 2 . The device turns in a circle, and meanwhile, the camera counts the number of players. This is done by counting the pixels in the temperature range of 32-40°C (FR 4.1 ). If the amount of pixels in a cluster exceeds a specific number, it will be considered a human. The Raspberry Pi then has to assign a specific location in degrees to each player (FR 4.2 ).

Testing
Testing was done with guidance from the independence axiom, i.e., to focus on each component. All the required components were tested independently. The speed and torque on the DC motor are enough to shoot the cards out 45 cm from the device (FR 1 ). The cards then slide a little further, depending on the table surface. The stepper motor is fast enough to turn in a whole circle (360°) in 0.91 seconds (FR 2 ). The encoder on the DC motor was confirmed to be functional and have the required precision. It allows the rubber wheel to repeat the same amount of rotations. After designing the cardholder and the DC motor arm, the software to shoot out individual cards was tested. It had to be calibrated to get the best results. Testing showed that the best results were when the cardholder was at a 30°incline. It takes 0.79 seconds to deal out five cards. Human testing showed that the fastest recorded time of dealing out five cards was around twice that of the device. The deck can be emptied, in less than three seconds, by putting the DC motor on maximum. All speed tests were done using a slow-motion featured smartphone camera and a smartphone stopwatch in the video frame.
There was a slight hiccup with the IR camera (FR 4 ), it only had drivers available from the manufacturer written in C++. The rest of the project software was written in Python. The solution was to create a Python code to wrap around the C++ code to make it work with the rest of the Python code. After prototyping all the electronics on a breadboard, a Printed Circuit Board (PCB) was designed with Altium Designer [8]. The PCB was milled with a desktop PCB miller. After soldering on all the components, the board was checked for shorts, and every component tested again to make sure no errors had occurred during the soldering process.

Future work and cost
Now that the prototype is ready, next up is to make the design more suitable for production and marketing. The idea is to streamline the design and sell it as a DIY kit. These kinds of products well known on the market [9], where you can order kits online and get assembly instructions and software with the package. The kit would include a lasercut casing, PCB and all components necessary for the assembly of the device. By laser cutting the case, so that the kit can be in a flat package, the shipping cost goes down. Getting a third party to manufacture the PCB would further decrease the production cost. Because there is minimal labor involved in the assembly of the product, it being a DIY kit, the production cost will decrease. The estimated production and parts cost is around 180 USD. That includes all components and parts of the device, the Raspberry Pi Zero, battery pack, the laser cut acrylic casing, and the PCB manufacturing. For this to be a feasible business, the retail price should be between 250-280 USD, which fits within the constraint of under 399 EUR in retail price. This margin should take care of unexpected additional cost and shipping of parts.

Conclusion and Discussion
All FRs for this project were met. By choosing the appropriate plastic cards, the device will perform with an accuracy of correct dealing in 99.03 % cards dealt, which is suitable for a prototype. The device dispenses cards at the speed of 5 cards in 0.79 seconds and is, therefore, faster than the average human, who takes about twice as long (FR 1 ). It turns to each player easily because of how the stepper motor is positioned (FR 2 ). Players can choose from a variety of games from a web page interface (FR 3 ). The IR camera is sufficient in detecting and counting the players (FR 4 ). However, the camera is sensitive to noise from external heat-sources and lights, which caused some false positives. These false positives can be fixed with an improved algorithm. To be able to sell this product on the market, we found that the easiest way is to make a DIY kit that includes the casing and PCB with all necessary components. The estimated production and parts cost is 180 USD, and the estimated retail price is around 250-280 USD, which should also cover all additional costs related to manufacturing.