• No results found

The Claw Machine Tivoliautomaten

N/A
N/A
Protected

Academic year: 2021

Share "The Claw Machine Tivoliautomaten"

Copied!
54
0
0

Loading.... (view fulltext now)

Full text

(1)

IN

DEGREE PROJECT MECHANICAL ENGINEERING, FIRST CYCLE, 15 CREDITS

,

STOCKHOLM SWEDEN 2020

The Claw Machine

Tivoliautomaten

DELAL ACAR

(2)
(3)

Claw Machine

DELAL ACAR KARIN SVENSSON

Bachelor’s Thesis at ITM Supervisor: Nihad Subasic

Examiner: Nihad Subasic

(4)
(5)

Abstract

Claw machines have been around for about a century spread-ing joy and entertainment to people of all ages. They are usually seen in amusement parks and malls.

In this Bachelors Thesis, one version of a claw machine will be constructed. Different constructing solutions and motors will be discussed for an easy and optimal claw ma-chine that meet all the requirements given in the project.

This report is divided into four parts, consisting of in-troduction, theory, construction of the machine and results. The first part is an introduction where some background information and delimitations of the project are presented. The second part of the report deals with the theory be-hind various selectable motors for this project as well as solutions for the design itself. The third part of the dis-sertation gives a detailed overview of how this particular Claw Machine was designed. Selection of materials, motors and how everything is connected and how the various parts harmonize with each other are also presented in this part. In the fourth and final part, the results are presented and a discussion of future improvements is provided.

Keywords: Claw, DC-motor, Servomotor, Arduino, Joy-stick.

(6)

Referat

Tivoliautomaten

Tivoliautomater har snart funnits i ett ˚arhundrade och har under flera ˚artionden varit en stor n¨ojesattraktion f¨or s˚av¨al gammal som ung. De ¨ar vanligt f¨orekommande i n¨ojes-parker och k¨opcentrum.

I detta kandidatexamensarbete kommer en s˚adan tivo-liautomat att konstrueras. Diskussioner kring olika motorer och konstruktionsl¨osningar kommer att f¨oras, f¨or att slut-ligen uppn˚a en konstruktion som uppfyller de givna direk-tiven f¨or projektet.

Denna rapport ¨ar uppdelad i fyra delar, best˚aende av introduktion, teori, byggandet av maskinen och resultat. F¨orsta delen ¨ar en introduktion d¨ar grund-l¨aggande fakta samt av-gr¨ansningar f¨or projektet presenteras. Andra delen av rap-porten behandlar teorin bakom olika valbara motorer f¨or detta projekt samt l¨osningar f¨or sj¨alva konstruktionen. I avhandlingens tredje del ges en detaljerad genomg˚ang av hur just denna tivoliautomat konstruerats. Val av material, motorer samt hur allt ¨ar sammankopplat och hur de olika delarna harmoniserar med varandra presenteras ¨aven i den-na del. I den fj¨arde och sista delen presenteras resultatet och en diskussion kring framtida f¨orb¨attringar tillhandah˚alls. Nyckelord: Klo, DC-motor, Servomotor, Arduino, Joy-stick.

(7)

Acknowledgements

We would like to thank Nihad Subasic for being a good mentor and setting the mood in the course MF133X. The teaching assistants also deserve a great hand for their great willingness to help and their answers to our questions.

We would also like to thank Thomas ¨Ostberg for handing us materials and KTH for financial support for the project. Last but not least we would like to thank Stob AB for supplying carpentry tools, material and knowlegde about construction dur-ing the social distancdur-ing era due to Covid-19.

Delal Acar, Karin Svensson Stockholm, 2020-05-26

(8)

Contents

1 Introduction 3 1.1 Background . . . 3 1.2 Purpose . . . 3 1.3 Scope . . . 4 1.4 Method . . . 4 2 Theory 5 2.1 Electrical Theory . . . 5 2.1.1 Motor Comparison . . . 5

2.1.2 DC, Servo or Stepper motor? . . . 6

2.1.3 Arduino . . . 8

2.2 Mechanical Construction . . . 9

2.2.1 Constructing the Coordinate System . . . 9

2.2.2 Shape of the Gripping Claw . . . 10

2.2.3 Formation of the controller . . . 10

3 Building the Machine 13 3.1 Mechanics . . . 13

3.1.1 The Coordinate System . . . 14

3.1.2 The Claw . . . 14 3.1.3 The Framework . . . 15 3.2 Electronics . . . 16 3.3 Software . . . 17 4 Results 19 4.1 Final Result . . . 19

4.2 Discussion and Future Improvements . . . 21

4.2.1 Obstacles due to Covid-19 . . . 21

Bibliography 23

Appendices 23

(9)

B Circuit Diagram 27

C Program Code 29

D Photographs 33

(10)

List of Figures

2.1 The rotor and the stator creates a force that makes the motor shaft rotate. Picture: [12] . . . 6 2.2 The four motors used in this project. Photo: by author. . . 8 2.3 Arduino UNO. Photo: by author. . . 9 2.4 Image presenting the 3D-printers that inspired our construction, using

belts for transmission. Photo: by author . . . 10 2.5 The claw from thingiverse.se that was the inspiration for the claw used

in the Claw Machine. Picture: [10]. . . 11 3.1 The three partial systems of he construction. The coordinate system in

blue, the claw in red and the framework in yellow. Picture: CAD by author. . . 13 3.2 The construction of the coordinate system. Picture: CAD by author. . . 14 3.3 The claw when it goes from closed to open. The figure also emphasises

the names of the different components, of which the claw is constructed. Picture: CAD by author. . . 15 3.4 The framework that stabilizes the construction. Picture: CAD by author. 16 4.1 Rendered photo of the finished CAD. The electronics is not shown in the

CAD version, but can be seen in the real photography of the construc-tion. More pictures of the Claw Machine can be found in Appendix D. Picture: CAD by author. . . 19 4.2 Photography of the finished Claw Machine. More photos are presented

(11)

Abbreviations

DC - Direct current

PWM - Pulse width modulation Rpm - Revolutions per minute

KEXPO - Exhibition for the bachelors work in mechatronics at KTH IDE - Integrated development environment

CAD - Computer-aided design KTH - Royal Institute of Technology

(12)
(13)

Chapter 1

Introduction

This chapter will discuss the fundamental idea of what is to be accomplished during this mechatronics project. It will present the Background, Purpose, Scope and

Method of the project.

1.1

Background

Claw machines are usually seen in places like amusement parks, movie theaters and shopping malls where the users get a chance to win a prize in exchange for money. The prize varies but the most common prize is probably stuffed animals. The claw machine’s main function is to bring money to the owner while it gives entertainment and suspense to people of all ages that uses the machine. The construction can vary and on the internet different solutions can be found, from homemade hydraulic pow-ered claw machines to electric power reliant solutions. They are often very colourful and equipped with blinking lights and sound effects. Instead of stuffed animals this Claw Machine will be filled with small chocolate bars. The final construction will be presented at KEXPO, which is the exhibition at KTH where the mechatronics work is presented and hopefully bring an entertaining atmosphere.

1.2

Purpose

The purpose of this project was to analyze in what way the Claw Machine can be constructed by using a microcontroller, which will be discussed further in the theory chapter in this report. The best suited motors and components for creating a simple machine that fulfills the basic functions of a claw machine is to be investigated. Throughout this report the following questions will be analysed and answered:

• What kinds of motors are best suited for this kind of machine’s different parts? • How will the mechanical parts be constructed for an easy and reliable

(14)

CHAPTER 1. INTRODUCTION

• What is the optimal shape and configuration of the claw for easy manufactur-ing and good grippmanufactur-ing abilities?

1.3

Scope

The instructions given for this project demonstrated three different requirements. Those included one mechanical part, one electrical part and a software. The given requirements reduced the possible solutions that did not include those three parts. Due to the limited time frame of four months, the Claw Machine was enabled to execute the basic functions, as picking up objects from the container via a control system controlled by the user of the machine. Playful effects like blinking lights was to be added if time allowed. An automated processes for the claw, from lowering itself til dropping the prize in the prize box, would also be evaluated and added if there was time. Otherwise the machine was to be steered manually with direct response from the user.

The budget for purchases of supplementary parts was 1000 SEK. Except for the time frame the budget also limited the amount of extra effects that could be built in. The Claw Machine was to be a miniature of the machines found in amusement parks to facilitate the building process and provide an easy storage. It also helped to not exceed the budget. The results of this project were to be shown at the KEXPO-exhibition in May 2020. Due to the Covid-19 pandemic, the KEXPO-exhibition was moved to an online website where all the projects were presented. The website can be accessed at: https://www.kth.se/itm/kexpo/mf133x. An oral presentation and a video of the construction was also made.

1.4

Method

The project was initiated by formulating questions that were to be researched during the project. A prototype of an existing claw was 3D-printed and after analysing the result a new one was made in Solid edge with improvements. Other parts like the different mounting were also made and 3D-printed to fit the required dimensions while the joystick, buttons and similar parts were ordered. When all the parts were gathered and ready, the construction of the machine could begin. The programming was then initiated to enable the desired movements, and finally the electrical wires were connected. After that the Claw Machine could be tested and used.

(15)

Chapter 2

Theory

In this chapter the theory behind the concept of the Claw Machine will be discussed and some of the questions brought up in the section 1.2 Purpose will be answered.

2.1

Electrical Theory

To enable the motion of the Claw Machine, motors were required to convert electri-cal energy into mechanielectri-cal energy [1]. In this project we could choose from different electric motors. There were three types presented in the beginning of the course -DC motors, servo motors and stepper motors [2]. The factors that were taken into consideration when choosing the motors were mainly cost, speed, torque, acceler-ation and ability to regulate the motion. By using an Arduino the different parts and motors were connected and controlled by programming the Arduino hardware.

2.1.1 Motor Comparison

A DC motor consists of a rotor and a stator. The co-operation between the magnetic field of the stator and the current through the rotor generates a force that creates the rotation of the motor[3]. A simple visualization of the mechanics of an electric motor is shown in Figure 2.1. Because of it’s simple construction the DC motor is the most common type used in tools, toys and other appliances. To alter the speed of the motor the current can be adjusted, but to regulate the desired movement a feedback function would be required. This function could for example consist of buttons, switches or a joystick. Another profit from using a DC motor would be that it is cheap and has a high starting torque.

Servo motors are fundamentally a DC motor with a control circuit, a gearing set and a potentiometer. This gives the motor the ability to give a high precision in position feedback [4]. Hence, the major difference between a servo motor and a DC motor is that the former allows a more precise control of the position, which makes it more expensive than the regular DC motor. It is often used in areas where the tasks require a motor position that is more precise, like in robotic arms. The motor

(16)

CHAPTER 2. THEORY

Figure 2.1. The rotor and the stator creates a force that makes the motor shaft

rotate. Picture: [12]

shaft of a servo motor can rotate either 180 or 360 degrees. With a servo motor you can specify what position you want it to go to, and it will go there with full power no matter what obstacles you put in front of it.

Stepper motors utilizes multiple notched electromagnets arranged around a cen-tral equipment to describe the machines position. In other words the stepper motor has the ability to know it’s own position[5]. This makes the stepper motors superior of the DC motors and the servo motors in this area. Stepper motors are mainly used in appliances where the position needs to be exact, for instance in 3D-printers. Because of it’s preciseness it is the most expensive of the three options mentioned in this report.

2.1.2 DC, Servo or Stepper motor?

For a fully functioning Claw Machine four motors were required. One motor for the motion in the X- and Y-axis respectively, which would move the claw backward and forward, as well as right and left. The third motor would control the motion in Z-axis, meaning the lowering and hoisting of the claw to reach the prize. The fourth motor would be in charge of the opening and closing of the claw.

For this project there was no need to control the position of the claw very precisely since the only purpose of the Claw Machine was to bring amusement to people. Since the user of the Claw Machine would be in control of the movement in

(17)

2.1. ELECTRICAL THEORY

the X- and Y-led, and give orders with direct response from the motors, the motors themselves did not need to know their position. Also, the precision in the X- and Y-directions were not fundamental. The user could start and stop the movement of the claw as it pleased by pushing the joystick in the direction the claw should be moved. Hence, the vital characteristic of the motor required for the positioning of the claw in the X- and Y-axis was that it responds quickly to the commands made with the joystick. For those reasons, the price was what determined the choice and the most suitable motors for this project were two DC motors - one for each direction, X- and Y-axis.

If an automated process for the claw was to be realized, the movement in Z-axis would be more significant since the controlling of how far the claw drops and how far it rises on the way up had to be limited. That gave two options: either using a servomotor that would be able to control the length of the drop, or a DC motor that would stop with direct response from the user. In the claw machines that are found on the market there are often a scam built in, which makes the claw drop the prize on the way to the opening. This also gave the option to automatize the process by using a DC-motor and program the number of rotations the motor should do before it stops and starts going the other direction. This would give an uncertainty in the movement of the claw, which would serve the purpose of a scam and make the game more exciting. This was why the DC motor was preferred, even if the process was to be automatized or not.

For the claw to open and close a more precise motor was needed since the claw required a smaller moving range and was more fragile than the other parts. In other words, there were no room for float. The motor also had to be able to work with a slower rpm so that the opening and closing of the claw was at a stable pace. The slower pace would also give an excitement for the user while waiting to see if the machine catches a prize. With all this in mind there were two options available: the servomotor or the stepper motor. The servo motor was chosen since it serves the purpose without any redundant attributes.

Motor Characteristics

The next step was to estimate what capacity the chosen DC motors and the servo motor had to possess to have the power to lift the prize. The weight of the prize was very light - the chocolate bars we aimed to use weighed somewhere between 10 and 50 grams. The claw, that was 3D-printed, was also very light. Likewise, the servo motor that drove the claw was very light. This all allowed the assumption that the motors did not have to have a high torque to be able to move the claw, since the torque was calculated by the following equation:

M = F · r = g · m · r

where M is the torque, F is the force measured in Newton and r is the radius of the motor shaft in meters. The motors inertia was neglected. The force was calculated by multiplying the weight, m, and the gravitational constant, g. [6]

(18)

CHAPTER 2. THEORY

When gathering information about DC motors in general, the torque for similar motors to the ones available at school was approximated to 0,5-15 kgcm. Since the radius of the motor shaft would not exceed 1 cm, and the weight would most definitely not exceed 15 kg, the motors torque capacity was more than enough.

The DC motors used in this project had a capacity of 24 V and a speed of 123 rpm. The servo motor required 5 V and the motor shaft could rotate up to 180 degrees. The motors are shown in Figure 2.2.

Figure 2.2. The four motors used in this project. Photo: by author.

2.1.3 Arduino

Arduino, that is the microcontroller used in this project, is an open-source electron-ics platform consisting of both a hardware and a software that complement each other. The Arduino hardware that was used for this project was the Arduino Uno, see Figure 2.3. Arduino Uno has 14 digital in- and outputs that were used for plugging in the motors, joystick, buttons and lights if wanted. Six of these could be used as PWM-outputs which ment that the motor’s rpm could be adjusted by lowering the current. [7]

The Arduino was programmed via the software Arduino IDE. The program code determined whether the output pins should be set to HIGH or LOW - i.e. if they should transmit current or not. The PWM-outputs could also be set somewhere in between for a desired rpm [8]. Feedback from the joystick and the buttons was processed in the code and set a combination of HIGH’s and LOW’s. Depending on the combinations of HIGH’s and LOW’s the motors would perform different

(19)

2.2. MECHANICAL CONSTRUCTION

Figure 2.3. Arduino UNO. Photo: by author.

movements. The orders were made made via the joystick and the buttons mounted on the steering platform. The program code steered what happened when a certain button was pushed or if the joystick was moved in a certain direction.

2.2

Mechanical Construction

In this section the construction plan for the Claw Machine will be described. Al-ternative solutions that were not chosen will also be discussed.

2.2.1 Constructing the Coordinate System

In the search for inspiration for the construction of the movement in the X- and Y-plane an observation of machines with similar performance and motion was made. This included 3D-printers, printers and other homemade claw machines, mainly on YouTube. One of the observed 3D-printers is shown in Figure 2.4. A relevant previously made bachelor thesis was a Braille-printer made in 2018 [9], also inspired by 3D-printers using belts for transmission.

The main decision was if belts or wheels were to be used to transmit the motor power to plane motion of the claw. Since the Claw Machine would be in a smaller size and many parts would be 3D-printed the construction was fairly light. This might not have given enough friction for the wheels to drive the claw without starting to spin. Spinning wheels would not make the correspondence as good as desired. This lead to the decision of using belts for the transmission.

As can be seen in Figure 2.4 the motors rotation were transmitted to the billets via shorter belts and gears. The longer belts in turn transferred the motion to the other billets and made them move synchronized. The crossing billets, which hold the mounting of the claw, and can be seen in the left picture in Figure 2.4, were attached to the longer belts running along the sides. The movement of the belts therefore enabled the motion of the claw in the X- and Y-led.

(20)

CHAPTER 2. THEORY

Figure 2.4. Image presenting the 3D-printers that inspired our construction, using

belts for transmission. Photo: by author

The inspiration for the motion in Z-axis was not taken from the 3D-printer since the Claw Machine required a faster motion, with less precision than the 3D-printer. Instead the claw was to be hoisted by a wire that was rolled up on a cylindrical construction, almost like a thread roll, directly connected to the motor shaft. This seemed to be the most common solution for existing home made claw machines.

2.2.2 Shape of the Gripping Claw

The shape of the gripping claw had to be adapted to the purpose of picking up small candy bars. Previously made constructions of claws were found at the website

Thingiverse.com [10], see Figure 2.5. After test printing and analyzing one of the

constructions on the site, a claw was made in Solid Edge with improvements to be more 3D-printer friendly and scaled for candy bars. The final version of the claw used in this project can be seen in section 3.1.2.

The claw consisted of four arms connected to a main hub which in turn connected via a stick to an upper hub that could glide up and down to generate the opening and closing motion of the claw. The servomotor that created the movement for gripping was attached to the upper hub. The motor shaft could then rotate to a maximum of 180 degrees, or stop when the claw was fully opened or closed. The number of degrees could be specified in the Arduino program code.

2.2.3 Formation of the controller

To be able to control the motion of the claw, inputs would have to be given to the Arduino. This could be given either via the computer, buttons or a joystick. Since the Claw Machine was supposed to be a toy the decision came to be a joystick for the steering in X- and Y-axis, and buttons to manage the vertical movement as well as the gripping of the claw.

The joystick would be controlling the X- and Y-movement with instant feedback, which meant that when the user stopped pushing the joystick the claw would stop.

(21)

2.2. MECHANICAL CONSTRUCTION

Figure 2.5. The claw from thingiverse.se that was the inspiration for the claw used

in the Claw Machine. Picture: [10].

The movement in the Z-axis would be controlled by two buttons, one for each direction. These buttons would have the same function as the joystick, meaning that the motion would stop once the button was released. Likewise, the claw would be steered by two buttons, one for opening and one for closing it.

(22)
(23)

Chapter 3

Building the Machine

In this chapter the approach for building the Claw Machine will be demonstrated and discussed.

3.1

Mechanics

The Claw Machine could be divided into three partial systems - the coordinate system, the claw and the framework, Figure 3.1. The following sections will go deeper into the methods used to produce them.

Figure 3.1. The three partial systems of he construction. The coordinate system in

(24)

CHAPTER 3. BUILDING THE MACHINE 3.1.1 The Coordinate System

As in section 3.1, the inspiration for the construction of the coordinate system was taken from existing 3D-printers. The motion in the X- and Y-axis was made possible with a set of billets driven by belts that were connected to the motors with gears, see Figure 3.2 below.

Both sides of the machine were synchronised through another pair of belts. Four side mountings would glide on the billets along the sides which drove the two inner billets attached to the mountings. Where the inner billets crossed a box was placed, which was moved according to the side mountings. The box held the third motor that controlled the motion of the claw in Z-axis by rolling in and out the wire the claw was attached to.

Figure 3.2. The construction of the coordinate system. Picture: CAD by author.

3.1.2 The Claw

The claw was, as mentioned in the previous chapter, developed from an existing 3D-printed model, but to adjust it to this projects aim some changes had to be made. The most prominent change was the formation of the arms of the claw. To be able to pick up small candy pieces or bars, the arms had to be made wider and in a slightly different shape.

The original claw, where inspiration was obtained from, turned out not to be optimal for the chosen manufacturing method, which was 3D-printing. This was because it had many curved surfaces that required unnecessary work post production such as removing support from areas hard to reach. Therefore, the remade parts of the claw was made to have at least one straight surface to lie on during the printing process.

(25)

3.1. MECHANICS

The remaining parts of the claw was also redesigned in CAD in a suitable size and shape to fit in this Claw Machine. The dimensions of the mountings for the servomotor on the upper hub had to be customized to fit the motor available for this project. The shape of the lever arms, which linked the upper hub with the arms of the claw, was also redesigned. These were made in a curved shape, instead of straight, to get a shorter total length of the claw and to avoid collisions with the lower hub. The final result of the entire claw construction can be seen in Figure

3.3. A more detailed view of how the different parts are connected can be seen in Appendix A.

Figure 3.3. The claw when it goes from closed to open. The figure also emphasises

the names of the different components, of which the claw is constructed. Picture: CAD by author.

3.1.3 The Framework

To connect the different mechanical parts of the construction a solid framework had to be built. Different ways to construct it were discussed and evaluated before the final method and materials were decided. Among the contemplated materials were plywood, plexiglass and steel.

The final choice of construction came to be a wooden frame in shape of a rectan-gular cube. The frame’s purpose was to create a stable surface where the four walls made out of plexiglass could be attached. The decision to use plexiglass was based on the willingness to display all the electronics, and make it more comprehensible to the user. The rest of the components, such as mountings for the motors and billets, were then either attached to the frame or directly to the plexiglass. A picture from CAD can be seen in Figure 3.4.

(26)

CHAPTER 3. BUILDING THE MACHINE

Figure 3.4. The framework that stabilizes the construction. Picture: CAD by author.

3.2

Electronics

The next step was to connect all the different parts. The joystick, the buttons, the motors, the Arduino and the claw had to connect through electricity to deliver the proper entertainment. For the machine to work as desired and to react when a certain move was made with the joystick for example, all the parts had to be connected to the Arduino since the Arduino was the part that could be programmed. The Arduino Uno, that was used in this case, had 14 digital pins and 6 analog pins, that were distrubuted as follows: 2 pins for each DC motor, 1 pin for the servo motor, 4 pins for the joystick and 4 pins for the buttons. That summed up to a total use of 15 pins. Since the digital pins were not enough, the buttons were all connected to the analog pins on the Arduino. To make them work as digital inputs it had to be specified in the code. A complete circuit diagram that shows all the connections can be seen in Appendix B.

All the used components also had to be connected to power and ground. The DC motors requires 24 V power and were connected to a power supply of 24 V. The rest of the components only needed 5 V, therefore they could all share the 5 V from the Arduino. Everything mentioned above was also connected to ground. Since the power supply, the 5 V pin and the ground pin from the Arduino had to be connected to several components, the connections were made via breadboards.

(27)

3.3. SOFTWARE

3.3

Software

The programming of the Arduino was made by using the Arduino IDE software. In this program the coding language C was used to create the code for the DC motors. The code for the servo motor was taken from the Arduino website [11], but was adjusted to fit this project. The code was built up by different scenarios, one for each directive that could be made by the user. Since the joystick was used to control the movement of the claw in both X- and Y-axis, it was programmed to steer two of the DC-motors, one for each direction. If the user would pull the joystick to the left the code would decide what the response from the motors would be, i.e how fast and in what direction they should spin. To make the claw move in the opposite direction while playing, the motor rotation was programmed to change direction when the joystick was pulled the opposite way. The same principle went for the DC-motor that was in charge of lowering and lifting the claw, except these were controlled by buttons instead of a joystick. Depending on the combination of motion from the different motors the outcome of what the machine would do would vary.

The servo motor that controlled the opening and closing of the claw was also steered by two buttons, one for each function. The code used for this was a little bit more complicated than for the DC motors. The angle of the movement of the motor shaft could have been specified in the code, but since the opening motion was made in direct response from the user, no angular restrictions were needed in this case. The pace of the motion however had to be adjusted since the claw consisted of quite delicate parts. The full program code can be seen in Appendix C.

(28)
(29)

Chapter 4

Results

This chapter will present an overview of the final solution, and also discuss areas of future improvement.

4.1

Final Result

The final construction, that is shown as a picture made in Solid Edge in Figure 4.1, came to be a yellow frame with plexiglass around to make the electronics visible for the user. The glass made it easier for the user to understand the theory behind the electronics of the machine since the cords were all visible and connected to the Arduino at the bottom part of the machine.

Figure 4.1. Rendered photo of the finished CAD. The electronics is not shown in

the CAD version, but can be seen in the real photography of the construction. More pictures of the Claw Machine can be found in Appendix D. Picture: CAD by author.

(30)

CHAPTER 4. RESULTS

The motors used for the Claw Machine were three DC motors to enable the motion of the claw in X- Y- and Z-axis. These were the cheapest and most the effective alternatives because they only required the direct response from the user. In the final and real version of the Claw Machine, the DC-motor that enabled the motion in X-axis was placed on top of the framework instead of inside the box. This was due to the fact that the DC-motor, that controlled the motion in X-axis, was connected to one of the upper billets. The prioritization of a bigger playing area made it more suitable to place the motor above the construction instead of moving the lower billets closer to the middle of the construction. This made it possible for the belt from the DC-motor to reach the upper billet. The placement of the two DC-motors that controlled the motion in X- and Y-axis can be seen in the photography of the finished Claw Machine in Figure 4.2.

For the opening and closing of the claw a servomotor was used since the claw was a bit more fragile and required a more accurate control. It also provided the possibility to automatize the gripping motion of the claw if desired in the future, since the servo motor enabled to specify the exact angle for opening and closing the claw to prevent any damage to its fragile parts.

The resulting claw consisted of four arms, respectively attached to a lever arm and the lower hub. The lever arms were in turn attached to the upper hub which enabled the opening and closing of the claw when gliding on the shaft attached to the lower hub. By having a curved shape, the lever arms could avoid collisions with the lower hub and the total length of the claw was minimized.

Figure 4.2. Photography of the finished Claw Machine. More photos are presented

(31)

4.2. DISCUSSION AND FUTURE IMPROVEMENTS

4.2

Discussion and Future Improvements

The final result of this project was a fully functioning, manual Claw Machine with many possible development opportunities to proceed with if desired. Since the spread of Covid-19 affected the access to school and proper equipment, some com-promises had to be done during the construction phase.

One of the possible developments would be to program an automated process from picking the candy and dropping it over the winning box. For that, switches would be needed placed on two sides of the middle mounting which the claw was attached to. That would be necessary when the direct feedback from the user would be eliminated since the DC-motors do not know their own position and need some kind of feedback to react. This would give an even more exciting experience since the game would become even more uncertain. For an automated opening and closing of the claw, no additional parts would be needed but some changes in the code. The servo motor would have to be programmed to open to a certain degree within the limits of its capacity. This means that the four buttons used would have to be replaced with one that starts the automated process.

Another improvement would be to add lights and sound effects. These could for instance go on when a prize is dropped through the winning box, or when the claw gets a hold of the prize. To make this possible some kind of sensors or switches would be required, and the light- and sound effects would have to be programmed to respond to the sensors or switches.

If the Claw Machine would be rebuilt, but still be working the same way with no improvements, the 3D-printed parts might have been modeled slightly different. When the construction was put together some deficiencies were discovered. Among these were the formation of the mountings for the billets, that were U-shaped for the billet to rest inside and an easy assembly. They would have been better if they were O-shaped to fixate the billet even more. That would have resulted in a more stable construction, not so sensitive to displacement.

In conclusion, the final result of the Claw Machine was a success. The chosen motors were three DC motors for the movement in X- Y- and Z-axis, and one servo motor for the claw. The construction resulted in a wooden frame, which the mountings with billets and belts were attached to. The optimal shape of the claw was design in a iterative process of 3D-printing and the result was well suited for small candy bars.

4.2.1 Obstacles due to Covid-19

As mentioned above, this project was implemented during the spread of Covid-19. Since this escalated into a pandemic during the semester and all universities in Sweden closed, all the remaining work had to be done from home. The closing of KTH was declared halfway through the project, which meant that we were in the early construction phase. With only the frame assembled, and the rest of the material in separate parts, we had to leave school and continue from home. This

(32)

CHAPTER 4. RESULTS

led to difficulties since we now did not have the possibility to readjust and remake our parts when defects were discovered. A list of all the parts required had to be sent to the assistants, who still had access to school, for them to print, lasercut and then ship it to our homes. Further no prototypes could be made and tested, which lead to some of the mountings etc. not being optimal.

(33)

Bibliography

[1] Ngabonziza Nyampame, C., ”Drivning av Likstr¨omsmotor med MOSFET: DC Motor control by MOSFET”, (2011). Available: www.studylibsv.com (accessed Feb. 15, 2020)

[2] Subasic, N., ”MF133X F4 Motors.pdf” (2020). Available: www.kth.instructure.com (accessed Jan. 24, 2020)

[3] Salutskij, M., ”Elmotorn – s˚a fungerar den”, (2014) [Online]. Available: www.teknikensvarld.se (accessed Jan. 24, 2020)

[4] Abrahamsson, J. Danmo, J. ”The Stabilizing Spoon; Self-stabilizing uten-sil to help people with impaired motor skills”, (2017), [Online]. Available: www.kth.diva-portal.org (accessed Feb. 10, 2020)

[5] de Vasconcelos Oliveira, A-M., ”Robotgripdon f¨or kartongsortering”, (2019), [Online]. Available: www.kth.diva-portal.org (accessed Jan. 21, 2020)

[6] Johansson, H., Tekniska h¨ogskolan i Stockholm, Institutionen f¨or maskinkon-struktion, ”Elektroteknik”, (2006), [Online]. Available: www.kth.se

[7] Arduino Website, [Online]. Available: www.arduino.cc (accessed Feb. 20, 2020) [8] Warren, J., Adams, J., Molle, H., ”Arduino Robotics (1st ed. 2011. ed., Tech-nology in action Arduino robotics)”, (2011), [Online]. Available: www.kth-primo.hosted.exlibrisgroup.com

[9] Ardestam, F., Soltaniah, S., ”Dot Master: Braille printer”, (2018), [Online]. Available: www.diva-portal.org (accessed Feb. 20, 2020)

[10] Swhitney22, ”Servo actuated claw”, (2014), [Online]. Available: www.thingiverse.com (accessed Feb. 20, 2020)

[11] Arduino Sweep, [Online]. Available: www.arduino.cc (accessed Apr. 8, 2020) [12] Lundberg, J., ”Hur fungerar en elmotor?”, (2013), [Online]. Available:

(34)
(35)

Appendix A

The Claw

(36)
(37)

Appendix B

Circuit Diagram

Appendix B displays the complete circuit diagram of the Claw Machine. The dia-gram was drawn in Google Drawings by Author.

(38)
(39)

Appendix C

Program Code

Appendix C displays the complete code for the Claw Machine. The code for the DC motors was made in Arduino IDE by Author, using the code language C. The code for the servo motor was taken from the Arduino website [11], but was adjusted to fit this project.

(40)
(41)
(42)
(43)

Appendix D

Photographs

Pictures of the finished Claw Machine taken by the author. There may be deviations from the rendered photos from the CAD, because of changes made due to the circumstances.

(44)
(45)
(46)
(47)

Appendix E

Rendered photos

(48)
(49)
(50)
(51)
(52)
(53)
(54)

References

Related documents

A timing belt attached to the stepper motors with a cog mounted on the stepper motors rods, resulted in linear movement on the X- and Y-axis.. Proper linear bearings are also

Industrial Emissions Directive, supplemented by horizontal legislation (e.g., Framework Directives on Waste and Water, Emissions Trading System, etc) and guidance on operating

• Page ii, first sentence “Akademisk avhandling f¨ or avl¨ agande av tek- nologie licentiatexamen (TeknL) inom ¨ amnesomr˚ adet teoretisk fysik.”. should be replaced by

I started off with an idea that instead of cnc-mill plywood and get a contoured model I wanted to com- pose the stock myself.. Idid some quick Rhino tests and I liked patterns

46 Konkreta exempel skulle kunna vara främjandeinsatser för affärsänglar/affärsängelnätverk, skapa arenor där aktörer från utbuds- och efterfrågesidan kan mötas eller

Both Brazil and Sweden have made bilateral cooperation in areas of technology and innovation a top priority. It has been formalized in a series of agreements and made explicit

Ett relativt stort antal arter registrerades dven utefter strdckor med niira an- knytning till naturbetesmarker (striickorna 5, 6.. = 9,

From observations of the establishment of tourism in small coastal villages in Zanzibar, local people’s ability to bargain for compensation and shares in revenue was identified to