Application of V80 series PLC in automatic card re

2022-08-24
  • Detail

Abstract:

taking the v80plc of haiweishen industry (Shenzhen) Co., Ltd. as an example, this paper introduces the application of haiweishen V80 series PLC in the automatic card reader system, expounds the control mode, performance and application of pulse output of haiweishen V80, and provides a programming example

key words: PLC pulse output

1. Introduction

with the development of productivity and the improvement of automation level, flexible and reliable micro control systems are needed in more and more control systems. As one of the main manufacturing bases of Honeywell characteristic materials and technology group, hiveyshen V80 series PLC is a small PLC with 24 input circuits and 16 relay/transistor optional output circuits. Because of its rich internal functions, high reliability, self intellectual property rights, independent brands and localized air pressurization service even in water with three atmospheres, it is currently applied to various control fields to realize automatic control of logic, stepping, digital and analog quantities. V80 series PLC provides powerful motion control function blocks for the widely used motion control performance requirements; Flexible process control can be realized. Taking the automatic card reader system as an example, this paper introduces the pulse output function of V80 series PLC

2.v80 PLC pulse output function setting and pulse output mode

v80 PLC has two independent pulse outputs. There are two output modes for each pulse output: PWM mode and PTO mode

2.1 PWM mode

pwm mode refers to the output of an infinite number of pulse sequences with any duty cycle. By calling PWM setting function block (pwmset), pulse output can be selected to work in PWM mode

after setting the relevant parameters, call the pulse output operation function block (plsrun) to output the newly set PWM waveform except the stop key and emergency stop switch. Figure 1 is an example of setting pulse output loop 1 to PWM mode output

Figure 1 Pulse output channel 1 works in PWM mode

Figure 1 Pulse output channel 1 works in PWM mode

2.2 PTO mode

pto mode refers to the output of a limited number of pulse sequences with equal width ratio. There are three different parameter setting methods according to different situations, as shown in Table 1

table 1 Comparison of PTO mode setting mode characteristics

users can select a setting mode to set PTO according to actual needs

after setting the relevant parameters, call the pulse output operation function block (plsrun) to output the newly set PTO waveform. The use of pulse output PTO will be described in detail with a case of automatic card reader control system

3. ladder diagram design and programming example of automatic card reader control system

3.1 brief introduction of automatic card reader system

Figure 2 Automatic card reader system diagram

the automatic card reader system is composed of upper computer, PLC, two stepping motors and mechanical system (see Figure 2). The upper computer communicates with PLC, and PLC controls the actions of two stepping motors. The specific process is: the upper computer sends the "push card" command, the PLC makes the corresponding control, and the pulse output 1 drives the motor 1 to push the card to the workbench, and then waits for the upper computer to read and write data; Then the upper computer sends the command of "send good card" or "send bad card" according to the reading and writing conditions, and the PLC drives the motor 2 by the pulse output 2 to push the card to the target position. In order to make the motor operate in a relatively "moderate" way, the motor should accelerate smoothly from a relatively low speed to the target speed, and then run at the target speed of the device used to test the strength of the test piece under the environment outside the normal temperature and humidity for a period of time, and then decelerate smoothly to stop, and the PTO envelope output mode of PLC can well meet this performance requirement. This system also needs to cooperate with the motor movement to do some other i/o control related to the sequence. This system will use the cam function block of V80 to complete this task

3.2 programming example of automatic card reader system

1) initialization program

call a subroutine with the first scanning flag, and initialize the pulse output parameters in the subroutine. See Figure 3 and Figure 4

Figure 3 First scan flag call subroutine 1

Figure 4 Initialization of motor parameters in subroutine 1

2) motor control

see Figure 5 and Figure 6. Select a user variable unit (40020) to save the command word sent by the upper computer every time, and compare it with the last saved command word (40030). When the command word changes, it indicates that there is a new command, otherwise there is no new command. When there is a new command, restart a timer (41103) and count from 0. That is, start a new control process

figure C determines whether a new command is received

Figure 6 Restart the timer after receiving the new command

in Figure 6, the function of the cam function block is to compare the current value of the timer (41103) with a series of user set target values (the first address of the user set target value is 41200), and the comparison is reflected in the target unit starting from unit 00065

the restart of the motor or the corresponding i/o can be controlled by using the output of cam. After the plsrun function block has been run, the pulse sequence can be output again as long as the PTO setting function block is reset. Participate

Copyright © 2011 JIN SHI