LOGO Examples
LOGO Examples
Contents
1 Preface 7
2 Notes on Safety 9
3 Introduction 11
4 Setting the programming interface 12
5 Task 1: Logic functions "OR" and "NOR" 16
6 Task 2: Logic functions „AND“ and „NAND“ 17
7 Task 3: Edge evaluations 18
8 Task 4: Negation of signals 19
9 Task 5: Two-way circuit and four-way circuit 20
10 Task 6: The up/down counter 22
11 Task 7: Message text 23
12 Task 8: Monitoring the boiler temperature 25
13 Task 9: Analog value with message text, alarm with acknowledgment 26
14 Task 10: Light / fan control 27
15 Task 11: Solar collector 28
16 Task 12: Light settings in the conference room 30
17 Task 13: Arithmetic example 32
18 Functional model: Bank door 34
18.1 Introduction 34
18.2 Check the wiring of the system 35
18.3 Input/Output names 36
18.4 Customer gets access to the bank with his bank card 39
18.5 Automatic, time controlled closing of the door 40
18.6 Door opens automatically to let the customer exit 41
18.7 Customer can only enter during banking hours 42
18.8 Limitation of number of customers in the bank 43
18.9 Implementation of the Text Display for customer information 44
6 Automation with LOGO! - Example "Bank door"
19 Appendix 46
19.1 Overview of the switching elements 46
19.2 Usage of “normal open” or “normal closed” switches 46
19.3 Function of the relay board for motor control 47
19.4 Design of the training kit LOGO! Learn Advanced 47
20 References 48
Automation with LOGO! - Example "Bank door" 7
-
1 Preface
The Siemens LOGO! provides a lot of possibilities with this you can control a variety
of automation applications. Compact design, possibility of extensions, low cost,
and a powerful instruction set make the LOGO! a perfect solution for controlling a
wide variety of applications within the lower price scale. The various programming
features within LOGO!Soft Comfort give you the flexibility you need to solve your
automation problems
This manual with exercises and solutions is designed for trainees, skilled workers,
proficient, technicians, engineers, programmers and maintenance personnel who
have a general knowledge of programmable logic controllers.
3 Introduction
This is a workshop intended to get participants interested in LOGO!. It's objective is
not to teach participants extensive LOGO! knowledge or the basics of control
engineering. These topics are covered by trainings. We are offering many exercises
in this workshop. We are aware that not all participants will work on all exercises.
The exercises are more of an offer to program as long as it is fun.
We start with simple exercises that can either be tried and tested by simulation or
transferred to the training device and tested on it.
We will introduce all functions that are used in the "Bank door" example from
Fischer-Technik in the exercises.
The workshop can be conducted with older LOGO! devices. It was originally created
with 0BA6 but can be conducted with older ones as long as you don’t focus on the
external LOGO! Text Display. Our current training devices are equipped with 0BA7.
It is not important because we are dealing with basic functionalities and not the
latest enhancements. An important difference is the ability to connect to LOGO!.
For older devices up to LOGO! 0BA6, you have to use the LOGO! programming
cable (RS232 or USB). For 0BA7 you have to use the Ethernet interface. To give
more guidance therefore we start with some advice how to get your Ethernet
interface configured.
The entire documentation should not to be mistaken for a training course, but
instead regarded as a reminder for when you work with the software later.
We welcome any suggestions you may have for improving the workshop and its
description.
12 Automation with LOGO! - Example "Bank door"
Install LOGO! Soft Comfort at least in the version required for the used
hardware.
We generally recommend that you upgrade to the latest version.
Available for free on the Internet (Help > Download center)
NOTE
Administrator rights are required for the installation of the USB cable drivers.
If you are using a COM port, the correctly installed software can automatically
detect at which COM port LOGO! is connected.
Automation with LOGO! - Example "Bank door" 13
-
In case of an Ethernet interface, you have to make a few settings as shown in the
slides. We use the following values in most examples:
Select the address of the connected LOGO! and start Detect, the status is Yes
(checked with software in this case).
5 Task 1:
Logic functions "OR" and "NOR"
Program an OR and NOR circuit with inputs 1 – 3 and compare the operation.
Transfer the program to LOGO!, activate online mode and test the behaviour.
NOTE
You should proceed this way in all exercises.
Suggested solution
6 Task 2:
Logic functions „AND“ and „NAND“
Program an "AND" and "NAND" circuit with inputs 1 – 3 and compare the
operation.
Suggested solution
Suggested solution
Suggested solution
Suggested solution
Alternative solution
- I1 = Reset
- I2 = Pulse input
- I3 = Counting direction
- Switch-on value = 5
- Switch-off value = 10
- Start value = 2
Try the operating mode Programming on device and change the reset input
to input I8
How do you get the latest counter value at LOGO! or on the text display?
Assign the password "A" for the program using the software.
Suggested solution
Suggested solution
?
Why is it not possible to download the example to the LOGO! ?
>>> An „Open connector“ block must be added to the output of the message
block B002.
Automation with LOGO! - Example "Bank door" 25
-
Message text
Horn
Temperature
Hot water
Suggested solution
A message text is generally displayed with the current time and latest temperature.
"Temperature alarm"
Number of alarms
The backlighting of the message window should flash. The error must be
acknowledged in LOGO! or on the display.
Figure 20: Analog value with message text, alarm with acknowledgment
Use the function "Input/Output names" with input I1 and outputs Q1 & Q2.
Suggested solution
Solar collector
Pump
Cold water
Hot water boiler
Hot water
Suggested solution
S1 = 0 + S2 = 0 => 200 %
S1 = 1 + S2 = 0 => 600 %
S1 = 1 + S2 = 1 => 900 %
Suggested solution
Figure 26: Light settings in the conference room with manual operation
KAFTAN-media Automation with LOGO! - Example "Bank door" 31
-
Design a circuit for adding and subtracting counter values without using the Math
Function block.
Suggested solution
It may look complicated, but you usually only need one of the two arithmetic
operations.
By the way, the solution also includes the basic approach to multiplication and
division.
18.1 Introduction
Our model simulates the function of a modern automatic sliding door that is
typically used in businesses or banks.
We are looking at a bank door in our example. The customer opens the door from
the outside with a "bank card". The door is to close automatically afterwards. When
leaving the bank, the door opens automatically triggered by a sensor when the
customer approaches the door. We are using a light barrier in our case. With a
LOGO! text display, the door can be opened and closed manually.
The "card reader" only admits customers during regular banking hours. Customers
who are still inside the bank at the end of regular business hours should be able to
leave the building without any problems. For security reasons, the number of
customers inside the bank is not to exceed a maximum value. Once this value is
reached, the card reader is blocked until a few customers have left the bank and
the card reader is activated once again.
We are going to develop a program in several steps. Please keep in mind that we
do not have to use all safety devices in our exercises (as is the case in actual
applications). We are only working on understanding the operating principle.
LOGO! offers an excellent tool for this purpose, the status display. The LOGO!
display must be in the basic state "Display of time and date" for this purpose.
If this is the case, push the ">" button and the display shows the status of the
INputs.
Every time you press the ">" button, you are switching to the next display.
Check to make sure that the switches are connected to the correct LOGO! inputs.
Direction control
This means direction control takes place through pulses and the motor runs in this
direction until it is stopped by a stop pulse.
NOTE
The geared motor is somewhat recessed during initial testing of the model so that
the door is NOT moved at the same time.
Create a program that starts the movement of the door manually with the function
keys of the text display and stops it with the respective limit switch.
Manually close the door and start the motor with the F1 key. Check the
direction of rotation of the gearwheel. Move the door manually to the point
where the limit switch stops the motor.
Use the same approach to test the direction of rotation and the limit switch for
closing the door.
If the system works properly in both directions, carefully move the motor block
forward until the gear engages with the door opening mechanism. Do not press in
too tight.
Suggested solution
18.4 Customer gets access to the bank with his bank card
The customer is to open the door using the "card reader" in front of the door.
Integrate the corresponding input for this step into the program.
This step should not affect the previous function.
Suggested solution
What happens when you activate the card reader while the door is closing?
Suggested solution
The light barrier must be activated by turning on the bulb via Q3. If the light is on
the sensor input I4 should give a “1” signal as long as the light beam reaches the
sensor.
Suggested solution
It must still be possible to open the door manually from the inside and to leave the
bank after hours.
Business hours:
Suggested solution
If there are 5 customers inside the bank, the card reader for opening the door is to
be blocked. Only if there are less than 4 customers inside the bank, is the reader to
be reactivated.
Suggested solution
Turn on the backlighting in both displays using the program and use a display
with 16 (32) characters per line.
Suggested solution
We have come to the end of our programming for the functional model "Bank
door".
You can now try out many more LOGO! functions using this example.
Password protection
Protecting parameters
19 Appendix
19.1 Overview of the switching elements
20 References
[1] Online help of the software Siemens LOGO!Soft Comfort V7.0
[2] Kaftan, J.: LOGO! Course (German). Vogel Business Media, 2009