emc 311 mechatronic project

29
SCHOOL OF M EMC 311 MECHA GROUP M12 MUHAMMAD SYA MUHAMMAD ZAE NOR SHAFIQAH B NUR MUSFIRAH B ASSOC DR. N MECHANICAL ENGINEER 1/3 MECHATR NIC ATRONIC PROJECT AHIRAN BIN SALEH 115754 EEM BIN MOHAMAD ZAN 115755 BINTI SARI 115760 BINTI MUSTAFFA 117868 EVALUATOR C. PROF. DR. ZAHURIN SAMAD NORZALILAH MOHAMMAD NOR 22 DECEMBER 2014 RING

description

material handling project using raspberry pi

Transcript of emc 311 mechatronic project

Page 1: emc 311 mechatronic project

SCHOOL OF MECHANICAL ENGINEERING

EMC 311/3 MECHATR

MECHATRONIC PROJECT

GROUP

M12

MUHAMMAD SYAHIRAN BIN SALEH

MUHAMMAD ZAEEM BIN MOHAMAD ZAN

NOR SHAFIQAH BINTI SARI

NUR MUSFIRAH BINTI MUSTAFFA

ASSOC. PROF. DR. ZAHURIN SAMAD

DR. NORZALILAH MOHAMMAD NOR

SCHOOL OF MECHANICAL ENGINEERING

EMC 311/3 MECHATR NIC

MECHATRONIC PROJECT

MUHAMMAD SYAHIRAN BIN SALEH 115754

MUHAMMAD ZAEEM BIN MOHAMAD ZAN 115755

BINTI SARI 115760

NUR MUSFIRAH BINTI MUSTAFFA 117868

EVALUATOR

ASSOC. PROF. DR. ZAHURIN SAMAD

DR. NORZALILAH MOHAMMAD NOR

22 DECEMBER 2014

SCHOOL OF MECHANICAL ENGINEERING

Page 2: emc 311 mechatronic project

1. Introduction

2. Objective

3. Background

4. Methodology 4.1. Apparatus 6

4.2. Material Handling System

4.3. Procedure (circuit diagram and sequence of MHS included)

4.4. Python Coding

5. Result 5.1. Output Truth Table

5.2. Output (from command prompt)

6. Discussion

7. Conclusion

8. References

9. Attachment

C NTENTS

Material Handling System 11

Procedure (circuit diagram and sequence of MHS included)

17

Output Truth Table 20

command prompt) 21

1

3

4

6

13

20

23

24

25

26

Page 3: emc 311 mechatronic project

INTR0

Material Handling is the field concerned with solving the pragmatic problems involving the movement, storage in a manufacturing plant or warehouse, control and protection of goods and products throughout the processes of cleaning, preparation, manufacturing, distribution, consumption and disposal of all related materials, goods and their packaging. The Material Handling course work is on the methods, mechanical equicontrols used to achieve these functions. This Mechatromaterial handling system based on equipment as shown in figure 1, 2 and 3 by integrating various sensors and actuation system using micro-controller. We are required to create a program to collect eight balls in the container until the end of the program.

In this project, we used Raspberry Pi instead of PLC (programmable logic controller) various sensor and actuation system in order to develop a material handling system to complete the task given. We also determine an operation of a material handling system that can be performed using the hardware given and decompose the operatusing the raspberry pi, we create a program using python for carry 8 balls into a container that moves around on the conveyer belt. The flow of programming created will be further explained in the procedure section.

1

INTR0DUCTI N

Material Handling is the field concerned with solving the pragmatic problems involving the movement, storage in a manufacturing plant or warehouse, control and protection of goods and products throughout the processes of cleaning, preparation, manufacturing, distribution, consumption and disposal of all related materials, goods and their packaging. The Material Handling course work is on the methods, mechanical equipment, systems and related controls used to achieve these functions. This Mechatronic project, we are required to develop a material handling system based on equipment as shown in figure 1, 2 and 3 by integrating various sensors and actuation system using Programmable Logic Controller or Raspberry Pi

controller. We are required to create a program to collect eight balls in the container until

In this project, we used Raspberry Pi instead of PLC (programmable logic controller) various sensor and actuation system in order to develop a material handling system to complete the task given. We also determine an operation of a material handling system that can be performed using the hardware given and decompose the operation into several sequences. By using the raspberry pi, we create a program using python for carry 8 balls into a container that moves around on the conveyer belt. The flow of programming created will be further explained

Figure 1

Material Handling is the field concerned with solving the pragmatic problems involving the movement, storage in a manufacturing plant or warehouse, control and protection of materials, goods and products throughout the processes of cleaning, preparation, manufacturing, distribution, consumption and disposal of all related materials, goods and their packaging. The

pment, systems and related project, we are required to develop a

material handling system based on equipment as shown in figure 1, 2 and 3 by integrating Programmable Logic Controller or Raspberry Pi

controller. We are required to create a program to collect eight balls in the container until

In this project, we used Raspberry Pi instead of PLC (programmable logic controller) to integrate various sensor and actuation system in order to develop a material handling system to complete the task given. We also determine an operation of a material handling system that can be

ion into several sequences. By using the raspberry pi, we create a program using python for carry 8 balls into a container that moves around on the conveyer belt. The flow of programming created will be further explained

Page 4: emc 311 mechatronic project

2

Figure 2

Figure 3

Page 5: emc 311 mechatronic project

1. To develop a material handling system by integrating various sensor and actuation system using Raspberry Pi micro-controller.

2. To identify and learn the components that are available in the given equipment

3. To determine an operation of a material handling system that can be performed using the available hardware.

4. To cooperate with the large group members to complete the task that given concord to our engineering field.

5. To solve the problems that occur while dointhat given.

3

BJECTIVE

To develop a material handling system by integrating various sensor and actuation system controller.

To identify and learn the components that are available in the given equipment

determine an operation of a material handling system that can be performed using the

To cooperate with the large group members to complete the task that given concord to our

To solve the problems that occur while doing this project and try to complete the task at time

To develop a material handling system by integrating various sensor and actuation system

determine an operation of a material handling system that can be performed using the

To cooperate with the large group members to complete the task that given concord to our

g this project and try to complete the task at time

Page 6: emc 311 mechatronic project

BACKGR

Material handling is the movement, storage, control and protection of materials, goods and products throughout the process of manufacturing, distribution, consufocus of material handling is on the methods, mechanical equipment, systems and related controls used to achieve these functions. A material handling system (MHS) can be simply defined as an integrated system involving activities smaterials. Material handling systems (MHS) range from simple pallet rack and shelving projects, to complex conveyor belt and Automated Storage and Retrieval Systems (AS/RS). The primary objective of using a MHS is to ensure that the material in the right amount is safely delivered to the desired destination at the right time and at the minimum cost. The MHS is properly designed not only to ensure the minimum cost and compatibility with other manufacturing equipmenalso to meet safety concerns.

Raspberry Pi is a credit-card-sized singlePi Foundation with the intention of promoting the teaching of basic computer science in schools. There are a lot of idea using this intelligent device such as powered arcade machines and drones to the home automation and low-cost tablets. Since its first appearance a couple of years ago, the Raspberry Pi has been used in ways that its creators could never have imagined. Intendeeducational device, in the tradition of the venerable BBC Micro, the tiny computer found favor with the burgeoning maker and hacker cultures, which exercised their ingenuity and put the Raspberry Pi to use in many imaginative scenarios.

That’s mean one of the main interest application of Raspberry Pi is robotic. Robots are generally quite cool where obviously aside from the ones that wish to except for the ones that try to kill all of humanity. There are plenty of friendly robots out therfeature about how to make a robotic arm work with the RPi. Robots and Raspberry Pi seem to be a match made in heaven, if hobbyist projects are anything to go by. Projects include controlling, an autonomous plane, a voice controlled Star Wars R5aims to give a general introduction to the General Purpose Input Output pins on the Raspberry Pi. The GPIO pins are available on the PCB via a header and allow you to interface the Pi to the real world. So, there is the Pi with its 40

Figure 4: GPIO header and pins

4

BACKGR UND

Material handling is the movement, storage, control and protection of materials, goods and products throughout the process of manufacturing, distribution, consumption and disposal. The focus of material handling is on the methods, mechanical equipment, systems and related controls used to achieve these functions. A material handling system (MHS) can be simply defined as an integrated system involving activities such as handling, storing and controlling of materials. Material handling systems (MHS) range from simple pallet rack and shelving projects, to complex conveyor belt and Automated Storage and Retrieval Systems (AS/RS). The primary

s to ensure that the material in the right amount is safely delivered to the desired destination at the right time and at the minimum cost. The MHS is properly designed not only to ensure the minimum cost and compatibility with other manufacturing equipmen

sized single-board computer developed in the UK by the Raspberry Pi Foundation with the intention of promoting the teaching of basic computer science in schools.

ng this intelligent device such as powered arcade machines and drones cost tablets. Since its first appearance a couple of years ago, the

Raspberry Pi has been used in ways that its creators could never have imagined. Intendeeducational device, in the tradition of the venerable BBC Micro, the tiny computer found favor with the burgeoning maker and hacker cultures, which exercised their ingenuity and put the Raspberry Pi to use in many imaginative scenarios.

That’s mean one of the main interest application of Raspberry Pi is robotic. Robots are generally quite cool where obviously aside from the ones that wish to except for the ones that try to kill all of humanity. There are plenty of friendly robots out there. Online magazine RPi MagPi has a feature about how to make a robotic arm work with the RPi. Robots and Raspberry Pi seem to be a match made in heaven, if hobbyist projects are anything to go by. Projects include controlling,

controlled Star Wars R5-D4 droid and a robot boat. This project aims to give a general introduction to the General Purpose Input Output pins on the Raspberry Pi. The GPIO pins are available on the PCB via a header and allow you to interface the Pi to the

So, there is the Pi with its 40 way header in the top left of the board.

Figure 4: GPIO header and pins

Material handling is the movement, storage, control and protection of materials, goods and mption and disposal. The

focus of material handling is on the methods, mechanical equipment, systems and related controls used to achieve these functions. A material handling system (MHS) can be simply

uch as handling, storing and controlling of materials. Material handling systems (MHS) range from simple pallet rack and shelving projects, to complex conveyor belt and Automated Storage and Retrieval Systems (AS/RS). The primary

s to ensure that the material in the right amount is safely delivered to the desired destination at the right time and at the minimum cost. The MHS is properly designed not only to ensure the minimum cost and compatibility with other manufacturing equipment but

board computer developed in the UK by the Raspberry Pi Foundation with the intention of promoting the teaching of basic computer science in schools.

ng this intelligent device such as powered arcade machines and drones cost tablets. Since its first appearance a couple of years ago, the

Raspberry Pi has been used in ways that its creators could never have imagined. Intended as an educational device, in the tradition of the venerable BBC Micro, the tiny computer found favor with the burgeoning maker and hacker cultures, which exercised their ingenuity and put the

That’s mean one of the main interest application of Raspberry Pi is robotic. Robots are generally quite cool where obviously aside from the ones that wish to except for the ones that try to kill all

e. Online magazine RPi MagPi has a feature about how to make a robotic arm work with the RPi. Robots and Raspberry Pi seem to be a match made in heaven, if hobbyist projects are anything to go by. Projects include controlling,

D4 droid and a robot boat. This project aims to give a general introduction to the General Purpose Input Output pins on the Raspberry Pi. The GPIO pins are available on the PCB via a header and allow you to interface the Pi to the

Page 7: emc 311 mechatronic project

From what going to focus in this group project is to develop a material handling system to collect eight ping pong balls into a container that running on a conveyor by all mean creating code form Raspberry Pi. It consists of two rows of thirteen pins. Pin 1 is clearly marked on the board as“P1″. It is vital to looking at the header and compare the hea

Figure 5: Raspberry Pi B+ GPIO layout

5

From what going to focus in this group project is to develop a material handling system to eight ping pong balls into a container that running on a conveyor by all mean creating

code form Raspberry Pi. It consists of two rows of thirteen pins. Pin 1 is clearly marked on the ″. It is vital to looking at the header and compare the header to the figure 5 below.

Figure 5: Raspberry Pi B+ GPIO layout

From what going to focus in this group project is to develop a material handling system to eight ping pong balls into a container that running on a conveyor by all mean creating

code form Raspberry Pi. It consists of two rows of thirteen pins. Pin 1 is clearly marked on the der to the figure 5 below.

Page 8: emc 311 mechatronic project

METHThe purpose of this project is to collect ball from station 1 (left) and station 2 (right) as a material handling system using a raspberry pi microcontroller wi

4.1. APPARATUS

This is all the component that been used for this project to run material handiling system.

Component 1. Raspberry pi (B+ model)

2. 5/2 way single solenoid

6

METHODOL GY The purpose of this project is to collect ball from station 1 (left) and station 2 (right) as a material handling system using a raspberry pi microcontroller with python language.

that been used for this project to run material handiling

Details

• Dual step-down (buck) power supply

for 3.3V and 1.8V • 5V supply has polarity protection, 2A

fuse and hot-swap protection (so you can plug/unplug USB without resetting the board)

• New USB/Ethernet controller chip• 4 USB ports instead of 2 ports• 40 GPIO pins instead of 26. The

top/first 26 pins match the original layout, 9 additional GPIO and 2 EEPROM Plate identification pins

• Composite (NTSC/PAL) video now integrated into 4-pole 3.5mm 'headphone' jack

• MicroSD card socket instead of full size SD

• Four mounting holes in rectangular layout

• Many connectors moved around

• Pressure Rating: 150 psi • Number of Ports/Ways: 5• Power: 24 to 120 volts • Valve Type: Cartridge /

Manifold Valves

The purpose of this project is to collect ball from station 1 (left) and station 2 (right) as a material

that been used for this project to run material handiling

down (buck) power supply

protection, 2A swap protection (so you

can plug/unplug USB without resetting

New USB/Ethernet controller chip 4 USB ports instead of 2 ports 40 GPIO pins instead of 26. The top/first 26 pins match the original

PIO and 2 EEPROM Plate identification pins Composite (NTSC/PAL) video now

pole 3.5mm

MicroSD card socket instead of full

Four mounting holes in rectangular

Many connectors moved around

Number of Ports/Ways: 5

Page 9: emc 311 mechatronic project

7

3. 3/2 way solenoid

• Voltage: DC 24V • Current: 200 mA • Pressure: 0.15-0.8 MPa

4. Transistor TIP 41C

• VCBO :140 V • VCEO :100 V • VEBO :5 V • IC :6 A • IB :3 A

5. 1N4001 diode

• Peak voltage: 50 V • Output current: 1 A • Peak reverse current: 5uA

6. Proximity sensor (Cylindrical Capacitive Proximity Sensors )

• Distance detect: 15mm • Voltage: 12-24 VDC • Current: 15 mA

Page 10: emc 311 mechatronic project

7. Magnetic Sensor (swish cs-f)

8. Tact switch

9. Pneumatic double acting cylinder

10. Single acting cylinder

11. Relay

8

f)

• Range of applied voltage: 5

DC/AC • Max switch: 100 mA • Max contact capacity: 10W • Indicator light: Red LED

• Normally open

Pneumatic double acting cylinder

• Rounded stroke • 15mm diameter

• Rounded stroke • Spring return

• Coil voltage :24 Vdc • Coil current:21.8 mA • Coil resistance: 1.1 kohm• Contact current: 5 A

Range of applied voltage: 5-240

capacity: 10W Indicator light: Red LED

Coil resistance: 1.1 kohm

Page 11: emc 311 mechatronic project

12. Optocoupler LTV946

13. Breadboard

14. Resistors (1.5k and 1k ohm)

15. Electrolytic capacitor

9

• Current transfer ratio ( CTR : MIN. 50% at IF = 5mA,VCE = 5V )

• High input-output isolation voltage( Viso = 5,000Vrms )

• Response time ( tr : TYP. 4ms at VCE = 2V, IC = 2mA, RL = 100W )

• To set up circuit.

Resistors (1.5k and 1k ohm)

• To resist current

• Electrolytic decoupling capacitors

100uF/25V. These capacitors are great transient/surge suppressors. Attach one between the power and ground of your project to ensure smooth power delivery. High quality radial electrolytic capacitors.

( CTR : MIN. 50% at IF = 5mA,

output isolation voltage

( tr : TYP. 4ms at VCE = 2V, IC =

decoupling capacitors 100uF/25V. These capacitors are great transient/surge suppressors. Attach one between the power and ground of your project to ensure smooth power delivery. High quality radial

Page 12: emc 311 mechatronic project

16. Jumper wire

17. Voltage regulator 7809 and 7805

10

• 3”, 5” and 7” long • Male-to-male jumper • Male-to-female jumper (7”)

oltage regulator 7809 and 7805

• Output current up to 1.5 A• Output voltage of 9V (7809) and 5V

(7805) • Thermal overload protection• Short circuit protection

female jumper (7”)

1.5 A 9V (7809) and 5V

Thermal overload protection

Page 13: emc 311 mechatronic project

11

4.2. MATERIAL HANDLING SYSTEM

The material handling system has included some of devices and hardware. The overview of this system is the container start at the left of the conveyor and place at the conveyor. Relays act as switch and change the direction of motor. When Relay A and B is powered, the conveyor will move the container from starting point to right. When the container arrives at proximity sensor 1, proximity sensor 1 will trigger and conveyor stopped. During that time two ball will drop into the container. Then, conveyor move to right until it reaches at proximity sensor 2. At this point, another two ball is released. The container move to left and stop again at proximity sensor 1 place and release two ball. Finally, the container move to right again and collect last two ball and move to the end of the conveyor before its stop. Figure 6 shows the complete set of material handling system. For each of the set of wire need to label and the wire need to connect correctly to prevent from short circuit. Figure 7 shows wire is labeled correctly before its connect to the material handling set.

Figure 6: Complete set of material handling system

Page 14: emc 311 mechatronic project

12

Figure 7: Labeled wire

For each GPIO pin, we need to declare as input or output. This is because the GPIO pin is programmable. Table below show that each device is declared an unique name and each of them assign a GPIO pin.

DEVICE GPIO NAME Declare in program

INPUT OUTPUT

Power Switch 5 swPwr ü Emergency Stop Switch 6 swRst ü Proximity sensor 1 19 px1 ü Proximity sensor 2 26 px2 ü Magnetic sensor 13 mgs ü Relay A 23 rlyA ü Relay B 24 rlyB ü Top left solenoid valve 8 sol1t ü Bottom left solenoid valve 7 sol1b ü Top right solenoid valve 20 sol2t ü Bottom right solenoid valve 21 sol2b ü

Page 15: emc 311 mechatronic project

13

4.3. PROCEDURE

1. The power supply either to PLC or Raspberry Pi is made sure to be switched off and earthed before touching the PLC and Raspberry Pi, and connecting wire to it.

2. The Raspberry Pi is connected to a monitor, keyboard and mouse.

3. The wiring of the input and output device to the Raspberry Pi was set up as the Figure 8.

Figure 8: Wiring Diagram

Page 16: emc 311 mechatronic project

14

4. The interface circuit for the switch and magnetic sensor was set up as the Figure 9. Note that for magnetic sensor need 5V to operate.

Figure 9: Switch interface circuit

5. The interface circuit for the output device was set up as Figure 10.

Figure 10: Output interface circuit

6. The interface circuit for the Proximity Sensor was set up as Figure 11.

Figure 11: Proximity Sensor interface circuit

Page 17: emc 311 mechatronic project

7. To develop a material handling system, the decomposition of machine operation is constructed as shown in figure 12.

Figure 12: Decomposition of the program

8. Power up the Raspberry Pi after all of the wiring of the input and output device is done properly.

9. Start the command prompt (LXTerminal) and make new folder named ‘m12pro’ by typing ‘mkdir m12pro’.

10. Then, type ‘cd m12pro’. Make a new python script bu typing ‘mkd

11. Next, a python program is constructed in the file named m12pro.py by typing ‘sudo nano m12pro.py’ to develop the material handling system according to the decomposition of the program.

15

To develop a material handling system, the decomposition of machine operation is constructed as shown in figure 12.

Figure 12: Decomposition of the program

the Raspberry Pi after all of the wiring of the input and output device is done

Start the command prompt (LXTerminal) and make new folder named ‘m12pro’ by

Then, type ‘cd m12pro’. Make a new python script bu typing ‘mkdir m12pro.py’.

Next, a python program is constructed in the file named m12pro.py by typing ‘sudo nano m12pro.py’ to develop the material handling system according to the decomposition of

To develop a material handling system, the decomposition of machine operation is

the Raspberry Pi after all of the wiring of the input and output device is done

Start the command prompt (LXTerminal) and make new folder named ‘m12pro’ by

ir m12pro.py’.

Next, a python program is constructed in the file named m12pro.py by typing ‘sudo nano m12pro.py’ to develop the material handling system according to the decomposition of

Page 18: emc 311 mechatronic project

12. Save the python script by press Ctrl+X and y key to pro

13. Run the python script by typing ‘sudo python m12pro.py’.

14. The sequence of the program is monitored on the command prompt according to the program decomposition.

15. To stop the running python script, press Ctrl+C.

16

Save the python script by press Ctrl+X and y key to proceed.

Run the python script by typing ‘sudo python m12pro.py’.

The sequence of the program is monitored on the command prompt according to the

To stop the running python script, press Ctrl+C.

The sequence of the program is monitored on the command prompt according to the

Page 19: emc 311 mechatronic project

4.4. PYTHON CODING

17

Page 20: emc 311 mechatronic project

18

Page 21: emc 311 mechatronic project

19

Page 22: emc 311 mechatronic project

5.1. OUTPUT TRUTH TABLE

SEQUENCES RELAY

A

RELAY

B

Conveyor move to right

1 1

Proximity sensor 1 detect (left)

0 0

Drop ball to container (left)

0 0

Ball fill empty space (left)

0 0

Proximity sensor 2 detect (right)

0 0

Drop ball to container (right)

0 0

Ball fill empty space (right)

0 0

Conveyor move to left

1 0

Conveyor stop

0 0

20

RESULT

RELAY

TOP LEFT

SOLENOID

BOTTOM

LEFT

SOLENOID

TOP

RIGHT

SOLENOID0 0 0

1 0 0

1 1 0

0 0 0

0 0 1

0 0 1

0 0 0

0 0 0

0 0 0

SOLENOID

BOTTOM

RIGHT

SOLENOID 0

0

0

0

0

1

0

0

0

Page 23: emc 311 mechatronic project

5.2. OUTPUT (from command prompt)

+----------------------------------------------------------------------------| Project: EMC 311 Mechatronic (Semester 1 2014/15)| Objective: To develope a msterisl handling system| by integrated various sensor and actuation| systems using raspberry pi | Group Members: | (1) Muhammad Syahiran Bin Sale| (2) Muhammad Zaeem Bin Mohamad Zan 115755 | (3) Nor Shafiqah Binti Sari 115760 | (4) Nur Musfirah binti Mustaffa 117868 +---------------------------------------------------------------------------- Python GPIO.VERSION = 0.5.8 Ready ... Wait for Power Button Power ON Conveyor move to right. Wait for proximity sensor 1 detectProximity sensor 1 detect Conveyor Stop. BALL = 1 Close top gate 1 Wait for magnetic sensor to open bottom gate 1Magnetic sensor detect, open bottom gate 1Close bottom gate 1 Open top gate 1 BALL = 2 Close top gate 1 Wait for magnetic sensor to open bottom gate 1Magnetic sensor detect, open bottom gate 1Close bottom gate 1 Open top gate 1 Conveyor move to right. Wait for proximity sensor 2 detectProximity sensor 2 detect Conveyor Stop. BALL = 3 Close top gate 2 Open bottom gate 2

21

5.2. OUTPUT (from command prompt)

----------------------------------------------------------------------------+ | Project: EMC 311 Mechatronic (Semester 1 2014/15) | | Objective: To develope a msterisl handling system | | by integrated various sensor and actuation | | systems using raspberry pi | | Group Members: | | (1) Muhammad Syahiran Bin Saleh 115754 | | (2) Muhammad Zaeem Bin Mohamad Zan 115755 | | (3) Nor Shafiqah Binti Sari 115760 | | (4) Nur Musfirah binti Mustaffa 117868 |

----------------------------------------+

Wait for proximity sensor 1 detect

sensor to open bottom gate 1 Magnetic sensor detect, open bottom gate 1

Wait for magnetic sensor to open bottom gate 1 Magnetic sensor detect, open bottom gate 1

Wait for proximity sensor 2 detect

Page 24: emc 311 mechatronic project

Close bottom gate 2 Open top gate 2 BALL = 4 Close top gate 2 Open bottom gate 2 Close bottom gate 2 Open top gate 2 Conveyor move to left. Wait for proximity sensor 1 detectProximity sensor 1 detect Conveyor Stop. BALL = 5 Close top gate 1 Wait for magnetic sensor to open bottom gate 1Magnetic sensor detect, open bottom gate 1Close bottom gate 1 Open top gate 1 BALL = 6 Close top gate 1 Wait for magnetic sensor to open bottom gate 1Magnetic sensor detect, open bottom gate 1Close bottom gate 1 Open top gate 1 Conveyor move to right. Wait for proximity sensor 2 detectProximity sensor 2 detect Conveyor Stop. BALL = 7 Close top gate 2 Open bottom gate 2 Close bottom gate 2 Open top gate 2 BALL = 8 Close top gate 2 Open bottom gate 2 Close bottom gate 2 Open top gate 2 Conveyor move to right. Conveyor Stop. Cleanup all pin setting ... Normal Stop

22

Wait for proximity sensor 1 detect

Wait for magnetic sensor to open bottom gate 1 Magnetic sensor detect, open bottom gate 1

Wait for magnetic sensor to open bottom gate 1 Magnetic sensor detect, open bottom gate 1

Wait for proximity sensor 2 detect

Cleanup all pin setting ... Normal Stop

Page 25: emc 311 mechatronic project

DISCUSSI N

Throughout this project, our group is the only one who using Raspberry Pi to design a mhandling system (MHS). The provided MHS is design to drop products or parts into the container. In this project, the MHS need to collect ping pong eight ball using the provided hardware and device. The container can move from left to right and vice versa by using conveyor belt. This can be completed by programming. All of the automation in this project is done in python language.

In this project, we need to declare the input and output from Raspberry Pi to MHS. We need to design interface circuit so that we can connect the MHS to a Raspberry Pi. It is very challenging to integrate high voltage device (MHS) to a Rasensor used in the MHS is operated in 24 V. device that operated in 24 V. For example, proximity stransmit 24 V signal at its output, so we need to step down the voltage to7809 and 7805 voltage regulator. Then the 5 V supply will drive the optocoupler and act as switch to send the input signal to the Raspberry Pi. to the Raspberry Pi because it is operated in 5 V, in addition of Raspberry Pi also can supply 5 V to the device.

Furthermore, all the output device is operatealone because it only can supply 3.3 V up solenoid and relay not only operate careful when connecting this output device so that high current supply not leak to the Raspberry Pi. In this project, we are using a TIP41C NPN power transistor to each of the solenoid and relay that act as switch. When the power transistor received a low current signal from the Raspberry Pi it will allow the high current/voltage to flow to the output device ei

We manage to integrate all the input and output device to the Raspberry Pi and runs test to every single of them. All of them are function correctly. But there is problem when we run the input and output together. This maybe occurs supply is grounded together.

The programming of the Raspberry Pi is easier compare to PLC ladder diagram. Each of the GPIO pin can be declare but the input and output pin for PLC is fixed with the addreswhy our group decided to use the Raspberry Pi as core of the system to drive MHS.

23

DISCUSSI N

Throughout this project, our group is the only one who using Raspberry Pi to design a mhandling system (MHS). The provided MHS is design to drop products or parts into the container. In this project, the MHS need to collect ping pong ball. We required collecting total of eight ball using the provided hardware and device. The container can move from left to right and

rsa by using conveyor belt. This can be completed by programming. All of the automation python language.

In this project, we need to declare the input and output from Raspberry Pi to MHS. We need to design interface circuit so that we can connect the MHS to a Raspberry Pi. It is very challenging to integrate high voltage device (MHS) to a Raspberry Pi that’s only runs 3.3 V. Most of the sensor used in the MHS is operated in 24 V. We need to use PLC as a power supply to all the

For example, proximity sensor that operated with 24 V will , so we need to step down the voltage to at least 5 V

7809 and 7805 voltage regulator. Then the 5 V supply will drive the optocoupler and act as switch to send the input signal to the Raspberry Pi. For magnetic sensor we can directly connectto the Raspberry Pi because it is operated in 5 V, in addition of Raspberry Pi also can supply 5 V

all the output device is operated in 24 V. Raspberry Pi can’t drive the output device alone because it only can supply 3.3 V up to 5.0 V maximum. The output that is consisting

high voltage but it also need high current supply. We need to careful when connecting this output device so that high current supply not leak to the Raspberry

s project, we are using a TIP41C NPN power transistor to each of the solenoid and relay that act as switch. When the power transistor received a low current signal from the Raspberry Pi it will allow the high current/voltage to flow to the output device either solenoid of relay.

We manage to integrate all the input and output device to the Raspberry Pi and runs test to every single of them. All of them are function correctly. But there is problem when we run the input and output together. This maybe occurs because of noises that exist. In addition, the power

The programming of the Raspberry Pi is easier compare to PLC ladder diagram. Each of the GPIO pin can be declare but the input and output pin for PLC is fixed with the addreswhy our group decided to use the Raspberry Pi as core of the system to drive MHS.

Throughout this project, our group is the only one who using Raspberry Pi to design a material handling system (MHS). The provided MHS is design to drop products or parts into the

ball. We required collecting total of eight ball using the provided hardware and device. The container can move from left to right and

rsa by using conveyor belt. This can be completed by programming. All of the automation

In this project, we need to declare the input and output from Raspberry Pi to MHS. We need to design interface circuit so that we can connect the MHS to a Raspberry Pi. It is very challenging

spberry Pi that’s only runs 3.3 V. Most of the We need to use PLC as a power supply to all the

ensor that operated with 24 V will at least 5 V by using

7809 and 7805 voltage regulator. Then the 5 V supply will drive the optocoupler and act as For magnetic sensor we can directly connect

to the Raspberry Pi because it is operated in 5 V, in addition of Raspberry Pi also can supply 5 V

Raspberry Pi can’t drive the output device consisting of

high voltage but it also need high current supply. We need to careful when connecting this output device so that high current supply not leak to the Raspberry

s project, we are using a TIP41C NPN power transistor to each of the solenoid and relay that act as switch. When the power transistor received a low current signal from the Raspberry Pi

ther solenoid of relay.

We manage to integrate all the input and output device to the Raspberry Pi and runs test to every single of them. All of them are function correctly. But there is problem when we run the input

because of noises that exist. In addition, the power

The programming of the Raspberry Pi is easier compare to PLC ladder diagram. Each of the GPIO pin can be declare but the input and output pin for PLC is fixed with the address. That’s why our group decided to use the Raspberry Pi as core of the system to drive MHS.

Page 26: emc 311 mechatronic project

CONCLUSI N

By doing this project, now we already know how to develop a material handling system by integrating various sensor and actuation system by using Raspberry Pi microactually very suitable for industrial uses, especially for industrial control processes. The low cost computer is extremely customizable and for many businesses trying it out makes sense. Raspberry Pi is integrated, the device has many uses and advantages over elements of existing IT. The uses of Raspberry Pi are better than programmer logic control (PLC) in term of cost, time and easy use. That’s why we chose Raspberry Pi while doing year there will be more group that use Raspberry Pi so that they can discuss among them then can make the system better and solve the existing problem.

24

CONCLUSI N

By doing this project, now we already know how to develop a material handling system by and actuation system by using Raspberry Pi micro-controller. It is

actually very suitable for industrial uses, especially for industrial control processes. The low cost computer is extremely customizable and for many businesses trying it out makes sense. Raspberry Pi is integrated, the device has many uses and advantages over elements of existing IT. The uses of Raspberry Pi are better than programmer logic control (PLC) in term of cost, time and easy use. That’s why we chose Raspberry Pi while doing this project. We hope next year there will be more group that use Raspberry Pi so that they can discuss among them then can make the system better and solve the existing problem.

By doing this project, now we already know how to develop a material handling system by controller. It is

actually very suitable for industrial uses, especially for industrial control processes. The low cost computer is extremely customizable and for many businesses trying it out makes sense. Once Raspberry Pi is integrated, the device has many uses and advantages over elements of existing IT. The uses of Raspberry Pi are better than programmer logic control (PLC) in term of cost,

this project. We hope next year there will be more group that use Raspberry Pi so that they can discuss among them then

Page 27: emc 311 mechatronic project

REFERENCES

1. William Bolton. (2008) MECHATRONICS electronic controlelectrical engineering. 4th edition. Pearson.

2. Getting Started with Raspberry Pi (

3. Associate Professor Dr. Zahurin bin Samad. (2014/2015) Lecture Note Mechatronic.

4. Mr. Ahmad Faizul Hawary.

5. Mr. Hashim MD Nordin. Assistant Engineer

6. Mr. Mohd Ali Shahbana Mohd Raus. Assistant Engineer

7. Mr. Ameer

25

REFERENCES

William Bolton. (2008) MECHATRONICS electronic control systems in mechanical and electrical engineering. 4th edition. Pearson.

Getting Started with Raspberry Pi (2012) by Matt Richardson and Shawn Wallace

Associate Professor Dr. Zahurin bin Samad. (2014/2015) Lecture Note Mechatronic.

Lecturer

Mr. Hashim MD Nordin. Assistant Engineer

Mr. Mohd Ali Shahbana Mohd Raus. Assistant Engineer

systems in mechanical and

by Matt Richardson and Shawn Wallace

Associate Professor Dr. Zahurin bin Samad. (2014/2015) Lecture Note Mechatronic.

Page 28: emc 311 mechatronic project

ATTACHMENT

26

ATTACHMENT

Page 29: emc 311 mechatronic project

27