在S7300中如何实现延时5秒的s7200脉冲输出一般编程实例信号,试着把程序写出?

《第7章S7300程序设计法模拟量控制》由会员分享,可在线阅读,更多相关《第7章S7300程序设计法模拟量控制(65页珍藏版)》请在人人文库网上搜索。1、date: 2021-11-12file no.: ssp1_03c.1simatic s7siemens ag 2000. all rights reserved.information and training centerknowledge for automation第第7章章 s7-300程序设计方法程序设计方法(模拟量控制)(模拟量控制)date: 2021-11-12file no.: ssp1_03c.2simatic s7siemens ag 2000. all rights reserved.information and training centerknowledge 2、for automation7.1 s7-300的程序结构的程序结构7.2 系统设计的原则系统设计的原则7.3 系统设计的内容系统设计的内容7.4 程序设计的方法与过程程序设计的方法与过程7.5 开关量控制系统的设计开关量控制系统的设计7.6 关于模拟量关于模拟量i/o模块模块7.7 模拟量控制系统的设计模拟量控制系统的设计7.8 关于乒乓控制关于乒乓控制7.9 关于关于pid控制控制date: 2021-11-12file no.: ssp1_03c.3simatic s7siemens ag 2000. all rights reserved.information and trainin3、g centerknowledge for automation7.6 关于模拟量关于模拟量i/o模块模块生产过程生产过程物理量标准的模拟信号传感器变送器 压力 温度 流量 速度 ph 值 粘性 等 500mv 1v 5v 10v 20ma4.20ma等dacpqw .pqw .:pqw .模拟量输出模块模拟量输出模块mr模块adc结果存储器piw .piw .:piw .模拟量输入模块模拟量输入模块cpu:l piw 304t pqw 320:模拟执行器 物理量.量程卡量程卡date: 2021-11-12file no.: ssp1_03c.4simatic s7siemens ag 204、00. all rights reserved.information and training centerknowledge for automation1 量程卡量程卡date: 2021-11-12file no.: ssp1_03c.5simatic s7siemens ag 2000. all rights reserved.information and training centerknowledge for automation2 s7-300模拟量模块的寻址模拟量模块的寻址im256 to270336 to350352 to366368 to382304 to318320 5、to334272 to286288 to302 (发送) 槽口号 2 3 4 5 6 7 8 9 10 11 384 to398400 to414432 to446448 to462464 to478480 to494496 to510416 to430机架机架 1r0电源模块im(接收) 电源模块cpu512 to526528 to542544 to558560 to574576 to590592 to606608 to622624 to638机架机架 2im(接收) 电源模块机架机架 3640to654656to670672to686688 to702704 to718720 to73476、36 to750752 to766im(接收) 电源模块date: 2021-11-12file no.: ssp1_03c.6simatic s7siemens ag 2000. all rights reserved.information and training centerknowledge for automation3 模拟量模块模拟量模块sm335 ( (输入输入) )date: 2021-11-12file no.: ssp1_03c.7simatic s7siemens ag 2000. all rights reserved.information and trainin7、g centerknowledge for automation4 模拟模块模拟模块sm335 ( (输出输出) )date: 2021-11-12file no.: ssp1_03c.8simatic s7siemens ag 2000. all rights reserved.information and training centerknowledge for automation5 5 模拟输入模块模拟输入模块 sm331date: 2021-11-12file no.: ssp1_03c.9simatic s7siemens ag 2000. all rights reserved8、.information and training centerknowledge for automation6 模拟量的表达方式和测量值的分辨率模拟量的表达方式和测量值的分辨率20212223242526272829210211212213214vz16进制.位值十进制0123456789101112131415位的序号单位位的分辨率+ 符号111*15*= 0 或 18000000001128*8402010840000000000000000000002164132116181412*91011121314date: 2021-11-12file no.: ssp1_03c.10sim9、atic s7siemens ag 2000. all rights reserved.information and training centerknowledge for automation7 在不同测量范围下模拟量的表达方式在不同测量范围下模拟量的表达方式范围超上限超上界额定范围超下界超下限测量范围 10v电压例如:= 11.75911.7589 :10.000410.00 7.50 :-7.5-10.00- 10.0004 :- 11.759= 22.81522.810 :20.000520.00016.000 : :4.0003.9995 :1.1852= 1000.11000.10、0 :850.1850.0 : : :-200.0- 200.1 :- 243.0=352.778352.767 :300.011300.000225.000 : :0.000不允许负值单位3276732511 :276492764820736 : :0- 32768- 1 :- 4864date: 2021-11-12file no.: ssp1_03c.11simatic s7siemens ag 2000. all rights reserved.information and training centerknowledge for automation8 模拟输入量的规范化模拟输入量11、的规范化(可随模块带的软件块 fc105 )500,00,0027648date: 2021-11-12file no.: ssp1_03c.12simatic s7siemens ag 2000. all rights reserved.information and training centerknowledge for automation9 模拟量输出的规范化模拟量输出的规范化(可随模块带的软件块 fc106 )276480 0,0100,0date: 2021-11-12file no.: ssp1_03c.13simatic s7siemens ag 2000. all righ12、ts reserved.information and training centerknowledge for automation10 模拟输出量的表达形式模拟输出量的表达形式范围超上限超上界额定范围超下界超下限单位=3276732511 :2764927648 :0 :- 6912- 6913 : : :- 27648- 27649 :- 32512=- 32513 输出范围:电压011.7589 :10.000410.0000 : 00 to 10v1 to 5v05.8794 :5.00025.0000 :1.0000011.7589 :10.000410.0000 : 0 : : 13、: : : : :-10.0000- 10.0004 :- 11.75890 10v 00.99990 0 输出范围: 电流023.515 :20.000720.000 : 00 to 20ma4 to 20ma022.81 :20.00520.000 :4.000023.515 :20.000720.000 : 0 : : : : : : :-20.000- 20.007 :- 23.5150 20ma 03.99950 0date: 2021-11-12file no.: ssp1_03c.14simatic s7siemens ag 2000. all rights reserved.i14、nformation and training centerknowledge for automation11 配置配置模拟量模块模拟量模块sm335date: 2021-11-12file no.: ssp1_03c.15simatic s7siemens ag 2000. all rights reserved.information and training centerknowledge for automation12 12 配置模拟量模块配置模拟量模块 sm331date: 2021-11-12file no.: ssp1_03c.16simatic s7siemens ag 215、000. all rights reserved.information and training centerknowledge for automation13 结构化的极限监视功能(可随模块带的软件块 fb120 )fb120actvhlllhysqh ql limit模拟变量的实际值hlllhyshysqh ql t功能 符号lo_limhi_limdate: 2021-11-12file no.: ssp1_03c.17simatic s7siemens ag 2000. all rights reserved.information and training centerknowl16、edge for automation7.7 模拟量控制系统的设计模拟量控制系统的设计1. 1. 关于模拟量控制系统关于模拟量控制系统 模拟量控制系统是指输入信号为模拟量的控制系统。控制系统模拟量控制系统是指输入信号为模拟量的控制系统。控制系统的控制方式上可分为开环控制和闭环控制。的控制方式上可分为开环控制和闭环控制。 闭环控制根据其设定值的不同,又可分为调节系统和随动系统闭环控制根据其设定值的不同,又可分为调节系统和随动系统两种。调节系统的设两种。调节系统的设 定值是由控制系统的控制器给出,控制器定值是由控制系统的控制器给出,控制器的作用就是使反馈值向给定值靠近,以反馈值对设定值的偏差最的作17、用就是使反馈值向给定值靠近,以反馈值对设定值的偏差最小为目的。随动系统的设定值是由被控制对象给出的,控制器的小为目的。随动系统的设定值是由被控制对象给出的,控制器的作用就是使控制目标不断地向被控对象靠近。各种跟踪系统都是作用就是使控制目标不断地向被控对象靠近。各种跟踪系统都是随动系统。随动系统。 模拟量控制系统设计中应该注意抗干扰问题。解决干扰的办法模拟量控制系统设计中应该注意抗干扰问题。解决干扰的办法有有4个。个。 其一是接地问题。这里包括其一是接地问题。这里包括plc接地端的接地,要真接地不要接地端的接地,要真接地不要假接地。这里所说的接地就是接大地。假接地。这里所说的接地就是接大地。 其18、二是模拟信号线的屏蔽向题,屏蔽线的始端和终端都要接地其二是模拟信号线的屏蔽向题,屏蔽线的始端和终端都要接地。信号线的屏蔽是防止干扰的重要措施。信号线的屏蔽是防止干扰的重要措施。 其三是对某些高频信号要解决匹配问题。如果不匹配很容易在其三是对某些高频信号要解决匹配问题。如果不匹配很容易在信号传送中引进干扰,使信息失真。信号传送中引进干扰,使信息失真。 其四是对信号进行滤波。其四是对信号进行滤波。date: 2021-11-12file no.: ssp1_03c.18simatic s7siemens ag 2000. all rights reserved.information and tr19、aining centerknowledge for automation2.2.模拟量控制系统设计举例模拟量控制系统设计举例 (1)搅拌控制系统线性程序设计(搅拌控制系统线性程序设计(s7-pro111s7-pro111)初始状态及初始状态及 操作工艺操作工艺 硬件设计硬件设计 软件系统结构软件系统结构date: 2021-11-12file no.: ssp1_03c.19simatic s7siemens ag 2000. all rights reserved.information and training centerknowledge for automationob1块块dat20、e: 2021-11-12file no.: ssp1_03c.20simatic s7siemens ag 2000. all rights reserved.information and training centerknowledge for automationob1续续date: 2021-11-12file no.: ssp1_03c.21simatic s7siemens ag 2000. all rights reserved.information and training centerknowledge for automationob1续续date: 2021-11-121、2file no.: ssp1_03c.22simatic s7siemens ag 2000. all rights reserved.information and training centerknowledge for automationob1续续date: 2021-11-12file no.: ssp1_03c.23simatic s7siemens ag 2000. all rights reserved.information and training centerknowledge for automation ob100块块date: 2021-11-12file no.22、: ssp1_03c.24simatic s7siemens ag 2000. all rights reserved.information and training centerknowledge for automation系统仿真系统仿真i0.0=oni0.0=onpiw256100 q4.0=onpiw256=100 q4.0=off q4.1=onpiw256=100 q4.0=off q4.1=onpiw256=200 q4.1=off q4.2=off t1piw256=200 q4.1=off q4.2=off t1t1=on q4.2=off q4.3=on piw256=23、0 t2t1=on q4.2=off q4.3=on piw256=0 t2t2=on q4.3=offt2=on q4.3=offdate: 2021-11-12file no.: ssp1_03c.25simatic s7siemens ag 2000. all rights reserved.information and training centerknowledge for automation(3 3)结构化结构化软软件设计(件设计(s7-pro112s7-pro112)系统结构系统结构ob1块块date: 2021-11-12file no.: ssp1_03c.26simat24、ic s7siemens ag 2000. all rights reserved.information and training centerknowledge for automationob1续续date: 2021-11-12file no.: ssp1_03c.27simatic s7siemens ag 2000. all rights reserved.information and training centerknowledge for automationob1续续date: 2021-11-12file no.: ssp1_03c.28simatic s7siemens25、 ag 2000. all rights reserved.information and training centerknowledge for automationob1续续date: 2021-11-12file no.: ssp1_03c.29simatic s7siemens ag 2000. all rights reserved.information and training centerknowledge for automationfb1fc1date: 2021-11-12file no.: ssp1_03c.30simatic s7siemens ag 2000. a26、ll rights reserved.information and training centerknowledge for automationfc2date: 2021-11-12file no.: ssp1_03c.31simatic s7siemens ag 2000. all rights reserved.information and training centerknowledge for automationob100date: 2021-11-12file no.: ssp1_03c.32simatic s7siemens ag 2000. all rights rese27、rved.information and training centerknowledge for automationdb1db2date: 2021-11-12file no.: ssp1_03c.33simatic s7siemens ag 2000. all rights reserved.information and training centerknowledge for automation系统仿真系统仿真i0.0=oni0.0=onpiw256100 q4.0=onpiw256=100 q4.0=off q4.1=onpiw256=100 q4.0=off q4.1=onpi28、w256=200 q4.1=off q4.2=off t1piw256=200 q4.1=off q4.2=off t1t1=on q4.2=off q4.3=on piw256=0 t2t1=on q4.2=off q4.3=on piw256=0 t2t2=on q4.3=offt2=on q4.3=offdate: 2021-11-12file no.: ssp1_03c.34simatic s7siemens ag 2000. all rights reserved.information and training centerknowledge for automation7.8 关29、于乒乓控制关于乒乓控制1 乒乓控制算法乒乓控制算法2 乒乓控制算法的实现(乒乓控制算法的实现(s7_pro113)fc1块块date: 2021-11-12file no.: ssp1_03c.35simatic s7siemens ag 2000. all rights reserved.information and training centerknowledge for automationfc1续续date: 2021-11-12file no.: ssp1_03c.36simatic s7siemens ag 2000. all rights reserved.informatio30、n and training centerknowledge for automationdb1块块ob1块块date: 2021-11-12file no.: ssp1_03c.37simatic s7siemens ag 2000. all rights reserved.information and training centerknowledge for automation 仿真仿真 检测值小于低限,输出为检测值小于低限,输出为on。 检测值大于低限,输出为检测值大于低限,输出为off。date: 2021-11-12file no.: ssp1_03c.38simatic s7s31、iemens ag 2000. all rights reserved.information and training centerknowledge for automation7.9 关于关于pid控制控制1 闭环闭环pid控制控制 pid控制器管理输出数值,以便将偏差控制器管理输出数值,以便将偏差(e)为零,使系统达到稳定为零,使系统达到稳定状态。偏差是给定值(状态。偏差是给定值(sp)和过程变量()和过程变量(pv)的差。)的差。 date: 2021-11-12file no.: ssp1_03c.39simatic s7siemens ag 2000. all rights re32、served.information and training centerknowledge for automation2 pid算法算法 pid控制原则以下列公式为基础,其中将输出控制原则以下列公式为基础,其中将输出m(t)表示成比例项表示成比例项、积分项和微分项的函数:、积分项和微分项的函数: 其中其中 m(t) 为为pid运算的输出,是时间的函数运算的输出,是时间的函数 kp 为为 pid回路的比例系数回路的比例系数 ki 为为 pid回路的积分系数回路的积分系数 kd 为为pid回路的微分系数回路的微分系数 e 为为pid回路的偏差(给定值和过程变量之差)回路的偏差(给定值和过程变33、量之差) minital 为为pid回路输出的初始值回路输出的初始值date: 2021-11-12file no.: ssp1_03c.40simatic s7siemens ag 2000. all rights reserved.information and training centerknowledge for automation 为了在数字计算机内运行此控制函数,必须将连续函数化成为偏差为了在数字计算机内运行此控制函数,必须将连续函数化成为偏差值的间断采样。数字计算机使用下列相应公式为基础的离散化值的间断采样。数字计算机使用下列相应公式为基础的离散化pid运算模型。运算模型。 34、其中其中: mn 为采样时刻为采样时刻n的的pid运算输出值运算输出值 kp 为为 pid回路的比例系数回路的比例系数 ki 为为 pid回路的积分系数回路的积分系数 kd 为为pid回路的微分系数回路的微分系数 en 为采样时刻为采样时刻n的的pid回路的偏差回路的偏差 en-1 为采样时刻为采样时刻n-1的的pid回路的偏差回路的偏差 el 为采样时刻为采样时刻l的的pid回路的偏差回路的偏差 minital 为为pid回路输出的初始值回路输出的初始值date: 2021-11-12file no.: ssp1_03c.41simatic s7siemens ag 2000. all ri35、ghts reserved.information and training centerknowledge for automation 在此公式中,第一项叫做比例项,第二项由两项的和构成,叫积在此公式中,第一项叫做比例项,第二项由两项的和构成,叫积分项,最后一项叫微分项。比例项是当前采样的函数,积分项是分项,最后一项叫微分项。比例项是当前采样的函数,积分项是从第一采样至当前采样的函数,微分项是当前采样及前一采样的从第一采样至当前采样的函数,微分项是当前采样及前一采样的函数。在数字计算机内,这里既不可能也没有必要存储全部偏差函数。在数字计算机内,这里既不可能也没有必要存储全部偏差项的采样。因36、为从第一采样开始,每次对偏差采样时都必须计算项的采样。因为从第一采样开始,每次对偏差采样时都必须计算其输出数值,因此,只需要存储前一次的偏差值及前一次的积分其输出数值,因此,只需要存储前一次的偏差值及前一次的积分项数值。利用计算机处理的重复性,可对上述计算公式进行简化项数值。利用计算机处理的重复性,可对上述计算公式进行简化。简化后的公式为:。简化后的公式为:其中其中: mn 为采样时刻为采样时刻n的的pid运算输出值运算输出值 kp 为为 pid回路的比例系数回路的比例系数 ki 为为 pid回路的积分系数回路的积分系数 kd 为为pid回路的微分系数回路的微分系数 en 为采样时刻为采样时刻37、n的的pid回路的偏差回路的偏差 en-1 为采样时刻为采样时刻n-1的的pid回路的偏差回路的偏差 mx 为积分项前值为积分项前值date: 2021-11-12file no.: ssp1_03c.42simatic s7siemens ag 2000. all rights reserved.information and training centerknowledge for automation 计算回路输出值计算回路输出值 cpu实际使用对上述简化公式略微修改的格式。修改后的公式为:实际使用对上述简化公式略微修改的格式。修改后的公式为: 其中其中: mn 为采样时刻为采样时刻n的38、回路输出计算值的回路输出计算值 mpn 为采样时刻为采样时刻n的回路输出比例项的回路输出比例项 min 为采样时刻为采样时刻n的回路输出积分项的回路输出积分项 mdn 为采样时刻为采样时刻n的回路输出微分项的回路输出微分项 比例项比例项 比例项比例项mp是是pid回路的比例系数回路的比例系数(kp)及偏差及偏差(e)的乘积,为了方便计的乘积,为了方便计算取算取kp= kc 。cpu采用的计算比例项的公式为:采用的计算比例项的公式为: 其中其中: mpn 为采样时刻为采样时刻n的输出比例项的值的输出比例项的值 kc 为回路的增益为回路的增益 spn 为采样时刻为采样时刻n的设定值的设定值 pvn39、 为采样时刻为采样时刻n的过程变量值的过程变量值date: 2021-11-12file no.: ssp1_03c.43simatic s7siemens ag 2000. all rights reserved.information and training centerknowledge for automation 积分项积分项 积分项积分项mi与偏差和成比例。为了方便计算取。与偏差和成比例。为了方便计算取。cpu采用的积分项采用的积分项公式为:公式为: 其中其中: min 为为 采用时刻采用时刻n的输出积分项的值的输出积分项的值 kc 为回路的增益为回路的增益 ts 为采样的时间间40、隔为采样的时间间隔 ti 为积分时间为积分时间 spn 为采样时刻为采样时刻n的设定值的设定值 pvn 为采样时刻为采样时刻n的过程变量值的过程变量值 mx 为采样时刻为采样时刻n-1的积分项的积分项(又称为积分前项又称为积分前项) 积分项积分项(mx)是积分项全部先前数值的和。每次计算出是积分项全部先前数值的和。每次计算出min以后,都以后,都要用要用min去更新去更新mx。其中。其中min可以被调整或被限定。可以被调整或被限定。mx的初值通的初值通常在第一次计算出输出之前被置为常在第一次计算出输出之前被置为minitai(初值)。(初值)。 其它几个常量也是积分项的一部分,如增益、采样时刻41、其它几个常量也是积分项的一部分,如增益、采样时刻 (pid循环循环重新计算输出数值的循环时间重新计算输出数值的循环时间)、以及积分时间、以及积分时间(用于控制积分项对用于控制积分项对输出计算影响的时间输出计算影响的时间)。 date: 2021-11-12file no.: ssp1_03c.44simatic s7siemens ag 2000. all rights reserved.information and training centerknowledge for automation 微分项微分项 微分项微分项md与偏差的改变成比例,方便计算取与偏差的改变成比例,方便计算取 。 42、计算微分项的公计算微分项的公式为:式为: 为了避免步骤改变或由于对设定值求导而带来的输出变化,对此为了避免步骤改变或由于对设定值求导而带来的输出变化,对此公式进行修改,假定设定值为常量公式进行修改,假定设定值为常量(spn=spn-1),因此将计算过程,因此将计算过程变量的改变,而不计算偏差的改变,计算公式可以改进为:变量的改变,而不计算偏差的改变,计算公式可以改进为: 其中:其中: mdn 为为 采用时刻采用时刻n的输出微分项的值的输出微分项的值 kc 为回路的增益为回路的增益 ts 为采样的时间间隔为采样的时间间隔 td 为微分时间为微分时间 spn 为采样时刻为采样时刻n的设定值的设定值43、 spn-1 为采样时刻为采样时刻n-1的设定值的设定值 pvn 为采样时刻为采样时刻n的过程变量值的过程变量值 pvn-1 为采样时刻为采样时刻n-1的过程变量值的过程变量值 date: 2021-11-12file no.: ssp1_03c.45simatic s7siemens ag 2000. all rights reserved.information and training centerknowledge for automation 回路控制的选择回路控制的选择 如果不需要积分运算如果不需要积分运算(即在即在pid计算中不需要积分运算计算中不需要积分运算),则应将积分,则应44、将积分时间时间(ti)指定为无限大,由于积分和指定为无限大,由于积分和mx的初始值,即使没有积分的初始值,即使没有积分运算,积分项的数值也可能不为零。运算,积分项的数值也可能不为零。 这时积分系数这时积分系数 ki=0.0如果不需要求导运算如果不需要求导运算(即在即在pid计算中不需要微分运算计算中不需要微分运算),则应将求导,则应将求导时间时间(td)指定为零。指定为零。 这时微分系数这时微分系数 kd=0.0如果不需要比例运算如果不需要比例运算(即在即在pid计算中不需要比例运算计算中不需要比例运算),而需要积分,而需要积分(i)或积分微分或积分微分(id)控制,则应将回路增益数值控制,则45、应将回路增益数值(kc)指定为指定为0.0,这时,这时比例系数比例系数kp=0.0。因为回路增益。因为回路增益(kc)是计算积分及微分项公式内的是计算积分及微分项公式内的系数,将回路增益设定为系数,将回路增益设定为0.0,将影响积分及微分项的计算。因而,将影响积分及微分项的计算。因而,当回路增益取为,当回路增益取为0.0时,在时,在pid算法中,系统自动地把在积分和算法中,系统自动地把在积分和微分运算中的回路增益取为微分运算中的回路增益取为1.0 , 此时此时 date: 2021-11-12file no.: ssp1_03c.46simatic s7siemens ag 2000. all46、 rights reserved.information and training centerknowledge for automation3 pid算法的实现算法的实现运算框图运算框图date: 2021-11-12file no.: ssp1_03c.47simatic s7siemens ag 2000. all rights reserved.information and training centerknowledge for automation pid控制软件(控制软件(s7_pro4) ob1date: 2021-11-12file no.: ssp1_03c.48sim47、atic s7siemens ag 2000. all rights reserved.information and training centerknowledge for automation ob35date: 2021-11-12file no.: ssp1_03c.49simatic s7siemens ag 2000. all rights reserved.information and training centerknowledge for automation fb1date: 2021-11-12file no.: ssp1_03c.50simatic s7siemen48、s ag 2000. all rights reserved.information and training centerknowledge for automationfb1续续date: 2021-11-12file no.: ssp1_03c.51simatic s7siemens ag 2000. all rights reserved.information and training centerknowledge for automationfb1续续date: 2021-11-12file no.: ssp1_03c.52simatic s7siemens ag 2000. a49、ll rights reserved.information and training centerknowledge for automationfb1续续date: 2021-11-12file no.: ssp1_03c.53simatic s7siemens ag 2000. all rights reserved.information and training centerknowledge for automation db2date: 2021-11-12file no.: ssp1_03c.54simatic s7siemens ag 2000. all rights res50、erved.information and training centerknowledge for automation仿真仿真 : 观察过程量观察过程量piw256的变化,的变化,pid输出控制输出控制pqw350的改变的改变date: 2021-11-12file no.: ssp1_03c.55simatic s7siemens ag 2000. all rights reserved.information and training centerknowledge for automation4 pid控制模块控制模块(1) pidpid模块的工作原理模块的工作原理date: 20251、1-11-12file no.: ssp1_03c.56simatic s7siemens ag 2000. all rights reserved.information and training centerknowledge for automation(2)pidpid模块模块 fm355fm355:4 4路闭环控制路闭环控制模块内含:模块内含:4ai+8di+4di4ai+8di+4didate: 2021-11-12file no.: ssp1_03c.57simatic s7siemens ag 2000. all rights reserved.information and 52、training centerknowledge for automationfm355fm355(续):(续):输入地址输入地址piw256-257piw256-257输出地址输出地址pqw256-257pqw256-257date: 2021-11-12file no.: ssp1_03c.58simatic s7siemens ag 2000. all rights reserved.information and training centerknowledge for automationfm355fm355(续):(续):基本参数基本参数有无中断有无中断中断类型中断类型工作方式工作53、方式date: 2021-11-12file no.: ssp1_03c.59simatic s7siemens ag 2000. all rights reserved.information and training centerknowledge for automation(3 3)pidpid参数参数比例项:名称比例项:名称 数据类型数据类型 默认值默认值 功能功能 p_sel bool true 比例项使能控制 gain real 2.0 放大倍数积分项:名称积分项:名称 数据类型数据类型 默认值默认值 功能功能 i_sel bool true 积分项使能控制 ti time t#54、20s 积分时间 int_hold bool false 积分输出保持控制 i_itl_on bool - 积分输出再输入允许 i_itlval real 0.0 积分初值微分项:名称微分项:名称 数据类型数据类型 默认值默认值 功能功能 d_sel bool true 微分项使能控制 td time t#10s 微分时间 tm_lag time t#2s 微分滞后时间过程参数过程参数 date: 2021-11-12file no.: ssp1_03c.60simatic s7siemens ag 2000. all rights reserved.information and train55、ing centerknowledge for automation(4)模板初始化功能(sfcsfc块)块) sfc 50 sfc 50: 名称名称 功能功能 wr_parm 将动态参数写入模板 sfc 56 sfc 56: 名称名称 功能功能 wr_dparm 将预定参数写入模板 sfc 57 sfc 57: 名称名称 功能功能 parm_mod 赋模板的参数 sfc 58 sfc 58 名称名称 功能功能 wr_rec 写模板专用的数据记录 sfc 59 sfc 59 名称名称 功能功能 rd_rec 读模板专用的数据记录(5)模板初始化功能的调用例:调用例:调用sfc 50 call 56、rd_lgadr“sfc 50 call rd_lgadr“ sfc 50 的形参date: 2021-11-12file no.: ssp1_03c.61simatic s7siemens ag 2000. all rights reserved.information and training centerknowledge for automation(6)利用)利用pid模块设计的过程模块设计的过程date: 2021-11-12file no.: ssp1_03c.62simatic s7siemens ag 2000. all rights reserved.information57、 and training centerknowledge for automation5 闭环控制系统功能块闭环控制系统功能块 系统功能块系统功能块sfb 41用于连续控制用于连续控制sfb 42用于步进控制用于步进控制sfb 43用于脉冲宽度控制用于脉冲宽度控制 sfb 41 sfb 43的调用的调用指令树指令树 library standard library system function blocks 6 闭环控制软件包闭环控制软件包功能块功能块fb 41 fb 42 fb 43 与与sf41 sf42 sf43兼容,兼容, 用用于于pid控制。控制。 fb 41 fb 43的调用的调用 standard library pid control blocks date: 2021-11-12file no.: ssp1_03c.63simatic s7siemens}

我要回帖

更多关于 s7200脉冲输出一般编程实例 的文章

更多推荐

版权声明:文章内容来源于网络,版权归原作者所有,如有侵权请点击这里与我们联系,我们将及时删除。

点击添加站长微信