You are on page 1of 15

School of Mechanical Engineering

Universiti Sains Malaysia


EMC 311/3 Mechatronics Programmable Logic Controller Wiring

Laboratory 1
Assoc. Prof. Dr. Zahurin Samad
Tel.: 04-5996312 Hp: 019-4220332 Fax: 04-5941025 Email: zahurin@eng.usm.my

http://elearning.usm.my/

EMC 311 Mechatronics

Warning

Laboratory 1/2

Caution! Danger 240 V AC electric is used

Make sure electric power supply to PLC is OFF when


Touching the PLC Connecting wires to the PLC

Refer to lecturer/ technician to ensure that the connections done are correct before switching the PLC ON

EMC 311 Mechatronics

Laboratory 1/3

Objectives
To connect PLC to input & output devices To build simple ladder diagram to control output devices by using the input devices To observe PLC operation

EMC 311 Mechatronics

Laboratory 1/4

Equipment
1 1 1 1 1 1 2 2 2 8

Software CX-Programmer Computer Omron CPM1A PLC RS-232C Adapter RS-232C Cable Electrical Plug with cable Switches LEDs Resistors Wires

CAD Laboratory 20 sets 3 person/set

EMC 311 Mechatronics

Laboratory 1/5

Observe the appearance of CPM1A Omron PLC

EMC 311 Mechatronics

Power supply & earth wiring

Laboratory 1/6

Make sure the PLC is connected to power supply and earth as shown.

Power supply

Earth

EMC 311 Mechatronics

Connecting computer to PLC

Laboratory 1/7

Connect the computer to the PLC using RS-232C Adapter and RS-232C cable as shown above.

EMC 311 Mechatronics

Laboratory 1/8

Input devices wiring

Analyze how the current flows

For correct wiring, the current will flow from + terminal and back to terminal of power supply

Connect one terminal of the 2 switches to input terminal 0.00 & 0.01 respectively. Connect the other terminal of the 2 switches to the positive terminal of 24 V power supply output. Connect the input com terminal to the negative terminal of 0 V power supply output.

EMC 311 Mechatronics

Output devices wiring

Analyze how Laboratory 1/9 the current flows

Power supply

Output device

Connect one terminal of the 2 LEDs to output terminal 10.00 & 10.01 respectively. The other terminal of the 2 LEDs is connected to one terminal of the 2 resistors. Connect the other terminal of the 2 resistors (combined) to the negative terminal of 0 V power supply output. Connect the 2 output com terminals to the positive terminal of 24 V power supply output. For correct wiring, the current will flow from + terminal and back to terminal of power supply

EMC 311 Mechatronics

Laboratory 1/10

Programming using CX programmer


Click to start CX programmer

Select PLC Model & then click OK

Click to create new file

CX programmer is displayed

EMC 311 Mechatronics

Laboratory 1/11

Drawing Ladder Diagram

Write the address & click OK Click this button to add a normally opened contact

Place the contact here

Name the device & click OK

The contact will appear here

EMC 311 Mechatronics

Laboratory 1/12

Connecting inputs and outputs in ladder diagram


Use this button to add Switch A Use this button to add Switch B Use this button to add LED A and LED B

EMC 311 Mechatronics

Laboratory 1/13

Loading & Running Program


Save file Connect to PLC Download Upload Program Monitor Run

Show PLC status

Compile a program

Compile all programs

Message shown after compiling programs

EMC 311 Mechatronics

Observing PLC Operation

Laboratory 1/14

Observe the changes on

Answer the following questions

The ladder diagram The input indicators on the PLC The output indicators on the PLC The output LED

when the following steps are performed


1.

2.
3. 4. 5.

6.
7.

How does the switch A control the LED A? How does the switch B control the LED B? Why the switches can continue controlling the LEDs although the PLC is disconnected from the computer?

8. 9.

Press switch A ON Release switch A OFF Press switch B ON Release switch B OFF Change the PLC mode to RUN Turn OFF the PLC Disconnect the cable that connecting the PLC and the computer (press the sides and pull the connector attached to the PLC) Turn ON the PLC Repeat step 1 to 4

EMC 311 Mechatronics

Laboratory 1/15
Submission

Report

Contents

Objective Background Procedure

Result

Power supply, earth, input, output and computer connections Ladder diagram construction PLC program loading and running Electrical circuit Ladder diagram Observation The flow of electric current in the electrical circuit and the ladder diagram Summarize your discussion

Due after 1 week 1 report/team Type using MS Word English language Send through web site http://elearning.usm.my

Discussion

Conclusion

You might also like