Automatic Cocktailmaker
by Timothy_Decoopman in Circuits > Raspberry Pi
179 Views, 1 Favorites, 0 Comments
Automatic Cocktailmaker
Hello
My name is Timothy and i made a automatic cocktailmaker. This was a very diffucult process. In this instructable i will explain how i built the frame, the electronic scheme and i am gonna show you the code. The machine doesn't work because i have some issue's with the code so i you are looking for a project to improve this is the one.
Supplies
Electronic components:
· 1x Raspberry Pi 3 Model B €35,00
· 2x Momentary Push Button Switch €15,96
· 1x 8 Channel Relay €8,99
· 1x 12V Switching Power Supply €46,15
· 1x Power Distribution Board €17,00
· 6x Peristaltic Pump €77,28
· 1x Oled €23,95
· 1x Ultrasonic sensor HC-SR04 €5,08
· 3m Silicone rubber tube's €57,44
· 1x druksensor/gewichtsensor €4,06
· 1x Stepper motor €10,99
· 1x Stepper motor driver (DRV8825) €5,75
· 1x Rfid sensor €14,00
· 1x Tandwiel tandlat systeem voor stappanemotor + houder €20,50
· Totaal = €322.15
Materials for the case:
· 4x wooden beam €34,50
· 1x big PVC sheet €15,99
· 2x Metal Bar €9,45
· 1x big MDF sheet €25,50
· different screws, nuts and bolts /
· Totaal =€104,94
Tools:
· Screwdrivers
· Hammer
· sawing machine
· sandpaper
· router / edge router
· drilling machine
· grinding wheel
The Frame
In this step i will explain how i built the 4 different sides of the frame.
first take your 4 beams and saw them so you have 4 beams
of 69,8 cm for the length , then 4 beams of 35 cm for the width and as last 4 beams of 47,4 cm for the height. These beams have a thickness of 3.5 cm.
When you have cut all the beams we can start to put the different sides of the frame together. As you can see here I started with the front side. For this I used the 2 beams of 35 cm and screwed them against 2 beams of 69.8 cm. You do this exactly the same for the back. Then I screwed the 4 beams of 35 cm between the front and back.
Finally I took a plate of 70 cm by 42 cm as a bottom plate and attached it to the frame.
Building the Sleigh
To make the sled I first sawed a plank until I had a plank of 14.5 by 10 cm. Then I attached the 4 v-groove wheels to the side of the plank.
Then I looked for 2 metal rods and sawed them to a length of 76.3. These bars must be angled so that the wheels can roll smoothly on them and therefore also roll perfectly straight. To support these metal rods and to put them at the right height, I sawed 2 extra beams in which a V was cut to insert the metal rods. So I already had most of the sled.
Of course the sled does not move forward by itself, so a stepper motor had to be installed at the bottom that moves on the basis of a gear rack system. The rack is made easy by choosing a bar as desired, but with a length of 69.5 cm and then sticking a rack to it by means of indoor mounting tape. This motor hangs in a bracket specially made for a stepper motor. You attach this in such a way that the stepper motor can rotate on the rack, so that the sled will move forward. Note, it is very important how you place the stepper motor.
As a last step, you attach the pressure sensor to the wooden plank with the plexi plate of 10 by 10 cm on top. I added some washers to washers to increase the distance between wooden plank and plexi plate so that there is air between the pressure sensor and the plexi plate.
The Front Plate
The front plate has the RFID, the OLED and 2 push buttons. This plate has a size of 69.8 by 14 cm and a thickness of 1.6 cm. In order to be able to fix the electronic components in the plate, we first had to look and measure where the components would be placed. Once I knew that, I milled everything out with the router. First the place where the RFID would come, then the place where the OLED would come and finally I drilled out the holes for the push button and widened them with the router. I also provided holes for the cables to pass through.
Then I looked to attach a clean PVC plate at the front
at the top. I also attached the same kind of plate for the wooden plate where the rfid and lcd come in. This plate for the top has a size of 77.3 by 10 cm and the bottom is 77.3 by 14 cm. in this pvc sheet I cut out the place for the electrical components with a utility knife. I then screwed these black PVC plates against the frame.
I also made a 3D piece that comes on top of the OLED screen so it looks cleaner. The link to all three printed pieces is at the bottom of the instructable in the last step.
the last photo shows the final product of the front plate.
Divider + Funnel
The next step was to make sure there was a separation between the carriage and funnel side and the bottle and electronics side. I did this by sawing a beam with dimensions 17 cm and this comes as you see in the third photo at 3 mm from the beam of 17.4 cm long. To "fix" the PVC sheet, I made a saw cut in the beams of the frame, this keeps the sheet in place.
As a next step I had 2 pieces 3D printed. These pieces are identical and are attached to each other to place the funnel. To fix the 3D pieces, there was still a beam shortage. That is why I sawed a beam of 35 cm and screwed it on at the correct distance. Once that beam was there, I could perfectly attach the 3D piece to it.
The Side Panels
Step 5 is attaching the side panels and making sure that they can open and close by means of a hinge. Both panels have a size of 47,4 by 43,8 cm. In order to be able to move the panels, a strip of 10 cm had to be cut and screwed to the side. The other part of the plate is attached to the hinge by means of screws as you can see in the photo. This hinge allows the entire side to open. This is useful for changing the bottles and for easily solving any electrical problems. Because the side had to close better, I placed a magnet on the frame.
On the other side i have done the same thing the only difference is that i needed to make a beam for the ultrasonic sensor. as you can see on the last picture. This beams measure depends on the height of your sleigh and glass. Just make sure it can detect your glass.
The Back Panel + Motors
The back panel measures 77,3 cm by 47,4 cm. And is screwed to the frame.
the motors are attached to the rear panel wherever you want. I have chosen to fix the motors with bolt and nut. This means that the motors were not allowed to fix in a place where the beams of the frame were located.
Because of this I chose to stay 5 cm from the side and the bottom. In addition, it does not matter much how you place the motors. I proceeded as follows: first I placed the motors where I wanted and then I marked the mounting holes. Then I drilled the holes. when attaching the motors to the panel make sure the tubes are not pinched if so do like me and insert washers to increase the distance between pump and back panel.
Once the motor has been attached to the rear panel, we must of course process the cabling properly. I used straps and hooks for this. The straps to hold the wires together and the hooks to keep them in line. The wires come in through the hole I drilled for this. As last stap you can add the tubes. Make sure one tube comes from a bottle and the other one goes trough the manifold (explained in step x) to the funnel.
The Top Plate
The top plate was the easiest. It is also a PVC sheet with a size of 77,3 cm by 47,1 cm. The plate is also screwed into the frame. Only one thing had to be done on the top plate and that was mounting the manifold. The manifold is the 3D printed piece through which the tubes run. The link of this 3D piece can be found again in the last step. Once the piece is printed, you only need to mark the holes for the tubes to come through and mark a rectangle for the longer piece to go through so that it can be easily attached.
The Electronic Components
On the first photo you can see how i placed my components. I'll tell you which component is which. If we start from the top left to the bottom right by going over the electrical components, we see the 8 channel relay first on the top left. Top right is the power distribution module board. In the middle left is the raspberry pi 3 with next to it a breadboard with the t piece that fits the pi. At the bottom left is the industrial power supply. Bottom right is first a breadboard to make up the stepper motor circuit and below that is the 5V regulator. To easily connect all these components, it is best to follow the last two pictures that contain the fritzing schemes.
Code + Other Links
I will not explain the code to you guys because that would simply take to much time but below are the links to my github directory where the code is located. This github directory also contains the other files like fritzing diagrams, 3D drawings, and my workdocumentations.