Programming Plc Applications; An Alarm System - Mitsubishi Electric FX2N Beginners Manual

Hide thumbs Also See for FX2N:
Table of Contents

Advertisement

An Introduction to Programming
3.6

Programming PLC Applications

Programmable logic controllers provide an almost unlimited number of ways to link inputs with
outputs. Your task is to choose the right instructions from the many supported by the control-
lers of the MELSEC FX family to program a suitable solution for your application.
This chapter provides two simple examples that demonstrate the development of a PLC appli-
cation from the definition of the task to the finished program.
3.6.1

An alarm system

The first step is to have a clear concept of what you want to do. This means that you need to
take a "bottom-up" approach and write a clear description of what it is you want the PLC to do.
Task description
The objective is to create an alarm system with several alarm circuits and a delay function for
arming and disarming the system.
The system will be armed with a key switch, with a 20-second delay between turning the
switch and activation. This provides enough time for the user to leave the house without
tripping the alarm. During this delay period a display will show whether the alarm circuits
are closed.
An alarm will be triggered when one of the circuits is interrupted (closed-circuit system,
also triggers an alarm when a circuit is sabotaged). In addition to this we want to show
which circuit triggered the alarm.
When an alarm is triggered a siren and a blinking alarm lamp are activated after a delay of
10 seconds. (The acoustic and visual alarms are activated after a delay to make it possible
to disarm the system after entering the house. This is also why we want to use a special
lamp to show that the system is armed.)
The siren will only be sounded for 30 seconds, but the alarm lamp will remain activated
until the system is disarmed.
A key-operated switch will also be used to deactivate the alarm system.
Assignment of the input and output signals
The next step is to define the input and output signals we need to process. On the basis of the
specifications we know that we are going to need 1 key-operated switch and 4 alarm lamps. In
addition to this we need at least 3 inputs for the alarm circuits and 2 outputs for the siren and the
blinking alarm lamp. This makes a total of 4 inputs and 6 outputs. Then we assign these signals
to the inputs and outputs of the PLC:
Function
Input
Output
FX Beginners Manual
Arm system
Alarm circuit 1
Alarm circuit 2
Alarm circuit 3
Display "system armed"
Acoustic alarm (siren)
Optical alarm (rotating beacon)
Alarm circuit 1 display
Alarm circuit 2 display
Alarm circuit 3 display
Programming PLC Applications
Name
Adress
Remarks
S1
X1
Make contact (key-operated switch)
S11, S12
X2
Break contacts (an alarm is triggered
S21, S22
X3
when the input has the signal state "0")
S31, S32
X4
H0
Y0
E1
Y1
The outputs functions are activated when
H1
Y2
the corresponding outputs are switched
on (set). For example, if Y1 is set the
H2
Y3
acoustic alarm will sound.
H3
Y4
H4
Y5
3 – 23

Advertisement

Table of Contents
loading

Table of Contents