已阅读5页,还剩1页未读, 继续免费阅读
版权说明:本文档由用户提供并上传,收益归属内容提供方,若内容存在侵权,请进行举报或认领
文档简介
IEEETRANSACTIONSONNUCLEARSCIENCE,VOL.51,NO.3,JUNE2004489MeasurementofReal-TimeAspectsofSimaticPLCOperationintheContextofPhysicsExperimentsHaraldKleines,JanosSarkadi,FrankSuxdorf,andKlausZwollAbstractToday,mostslowcontrolsystemsforphysicsex-perimentsatForschungszentrumJlichareimplementedwithProgrammableLogicController(PLC)technologyandfieldbussystems.Inmanycases,evendeterministicresponseisrequiredfromthePLCs.Thisraisesthequestionaboutthereal-timeperformancethatcanbeexpectedfromaPLC.Response-timemeasurementsofSimaticPLCsmanufacturedbytheworldmarketleaderSiemensarepresented.InfluenceofprogramstructureandhardwareconfigurationonperformanceanddeterministicbehaviorofaPLCisdiscussed.I.PROGRAMMABLELOGICCONTROLLERS(PLCS)INEXPERIMENTCONTROLSYSTEMSTODAY,industrialautomationtechnologyiswellestab-lishedininfrastructuresystemsforphysicsexperiments,e.g.,inwaterorgassupplysystems.ThisleadstotheheavyuseofProgrammableLogicControllers(PLCs),whichtypicallyaretheintelligentautomationstationsformingthecoreofindustrialsystems1.Mainreasonsincludelowpricesinducedbymassmarket;robustness;longtermavailabilityandsupportfrommanufacturer;professionality(connectors,conformancetostandards,)Beyondthescopeofpureinfrastructuresystems,PLCsarein-creasinglybecomingcentralcomponentsofexperimentcontrolsystems,replacingVME-orPC-basedreal-timesystems2,3.ThisiscausedbythefollowingfeaturesofmodernPLCfamilies.Highdegreeofscalability:ModernPLCfamilieshaveawidespectrumofCPUtypes,thatisscalablenotonlywithregardtoperformance,butalsowithregardtofunction-alityandformfactor.Foroutdoororfaulttolerantappli-cationsspecialversionsareavailable.Extensibility:ThemodulardesignofPLCsenablestheextensionwithawiderangeofdigitalandanalogI/Omodules.Additionally,integratedtechnologymod-ulesareavailablefordifferentapplicationareas,e.g.,steppermotorcontrollers,servomotorcontrollers,orPIDcontrollers.Extensivecommunicationcapabilities:ModernPLCshaveatleastoneintegratedcommunicationportandcanbeextendedbyavarietyofcommunicationcontrollersManuscriptreceivedMay16,2003;revisedOctober1,2003.TheauthorsarewithZentrallaborfrElektronik,ForschungszentrumJlich,D-52425Jlich,Germany(e-mail:h.kleinesfz-juelich.de).DigitalObjectIdentifier10.1109/TNS.2004.828504fordifferentfieldandprocessbussystems,thusenablingconnectionofotherindustrialdevices.AkeyissueistheextensionofacentralPLCsystemwithdecentralperipheryviaspecialfieldbusses(e.g.,PROFIBUSDP),thatallowsthetransparentconnectionof“unintelligent”I/O-modules.ThusaPLCprogramcanaccessthisdecen-tralperipheryinthesamewayascentralPLCperiphery.Powerfuldevelopmentenvironment:ModernPLCfami-liescomewithahomogeneouscrossdevelopmentenvi-ronment,thatsupportsallthemajorIEC1131program-minglanguages4.Typically,representationsininstruc-tionlist(IL),functionblockdiagram(FBD)orladderdiagram(LD)canbeswitcheddynamically.Thedevelop-menttoolsallowsemigraphicalhardwareconfiguration,offerstrongdebuggingmechanismsandallowincrementaldevelopmentbytheexchangeofblocksduringruntime.Today,inFZJuelich,allnewandadvancedexperimentcon-trolsystemsareheavilyPLC-based3,asillustratedbythear-chitectureofaneutronspectrometercontrolsystemshowninFig.1.BecausetheworldmarketleaderSiemensdominatestheEuropeanmarket,SimaticS7PLCsareusedinFZJuelich,almostexclusively.ThemidrangeseriesS7-300ismostpopular.Thehigh-endseriesS7-400istargetedatapplicationswithextremeperformancerequirementsandsupportsalsomultiprocessorconfigurations.TheminiPLCseriesS7-200israrelyused,becauseitgotthenameS7bypuremarketingreasonsanditsprogrammingenvironmentisincompatibletotheotherS7devices.InsteadoftheS7-200,theIM151/CPUservesasaminiPLC.TheIM151/CPUisanintelligentcontrollerforthedecentralperipheryfamilyET200S.AlsothedecentralperipherysystemsET200LandET200MareusedcommonlyinJlich.TheSoftPLCWinAChasonlybeentestedintheLab,sofar.TheresponsibleplanningofPLC-basedcontrolsystemsre-quiresknowledgeontheirreal-timefeatures.WhatisthemagnitudeofPLCresponsetime,dependingonPLCtype?Candeadlinesbeguaranteed?Whatprogrammingruleshavetobefollowed?Thepaperaddressestheseissuesbymeasurementsatdif-ferentPLCtypesoftheSimaticS7family.ThestandardIEC1131definesacommonframeworkforPLCfunctionalityandprogramminglanguages4,whichallthemajorPLCmanufac-turersconformto.ThusgeneralresultscanbegeneralizedalsototheirPLCfamilies.0018-9499/04$20.002004IEEE490IEEETRANSACTIONSONNUCLEARSCIENCE,VOL.51,NO.3,JUNE2004Fig.1.ControlsystemarchitectureoftheneutronspectrometerKWS3.Fig.2.Blockcallinghierarchy.II.SIMATICS7PROGRAMMINGMODELClassicalreal-timeapplicationsinresearchareimplementedwithreal-timekernelslikeOS-9orVxWorks,thatfollowanasynchronousparallelprogrammingapproach,asdefinedinPOSIX5,forexample.Thesoftwaredeveloperstructureshisprogramintasksaccordingtothelogicalstructureoftheproblemtosolve.Thesetasksareexecutedquasiparallelbytheoperatingsystem,andtheexecutionisbasicallyevent-triggered.Byassigningprioritiestothetaskstheprogrammergiveshintstotheoperatingsystemaboutthedesiredexecutionorder.Thustheprogrammerdoesnothavetoplantheschedulingdetails.Ontheotherhanditisdifficulttounderstandtheexecutionorderandtodecide,ifaspecifictaskcanmeetitsdeadlines.TheprogrammingmechanismsinPLCsystemsaretotallydifferent,becausetheyfollowtheolderapproachofsyn-chronousprogramming6.Here,theexecutionoftasksiscompletelytime-triggered,andtheprogrammerhastoorganizehisprogramintotasksaccordingtothetime,whenataskhastorun.Sohemustplantheexecutionorderhimself,whichismorecomplicatedbutalsogivesmorecontrol.InStep7,thedevelopmentenvironmentoftheS7,allcodeexistsinblocks,asdefinedinIEC1131.TasksarerepresentedbyOrganizationBlocks(OBs).OBsaretheschedulableitems,thatarecalledbytheoperatingsystemofthePLCatcertainevents,e.g.,whenatimerexpiresoranerroroccurs.Thus,theOBsaretheinterfaceoftheoperatingsystemtotheuserpro-gram.AsindicatedinFig.2,OBscancallFunctions(FCs),whichareblocksthatcorrespondtofunctionsinaprocedurallanguage.FCscancallotherFCsorsystemfunctions(SFCs),whichcorrespondtooperatingsystemcallsinaPOSIXenviron-ment.FunctionBlocks(FBs)/SystemFunctionBlocks(SFCs)areFCs/SFCswithanassigneddatablockforstaticfunctiondata.A“normal”PLCprogramiscontainedinOB1,whichiscalledcyclicallybytheoperatingsystem,asindicatedinFig.3.BeforeOB1iscalledtheoperatingsystemtransfersdatafromtheinputmodulestoamemoryareacalledprocessimagetable.AfterOB1hasbeencalled,datafromtheprocessimagetableiscopiedtotheoutputmodules.TheindirectaccesstoI/O-modulesviatheprocessimagetablereducesaccesstimeandincreasesconsistency.KLEINESetal.:SIMATICPLCOPERATION491Fig.3.ExecutionofmainprogramscancycleOB1.TheexecutiontimeofOB1ismonitored,andifapreconfig-uredmaximumisexceeded,thetimeerrorOB80iscalled.OnS7-400andWinACalsoaminimumforthecycletimeofOB1canbeconfigured.IftheexecutiontimeforOB1islessthen,thebackgroundOB90iscalled,whichhasthelowestpriority.ThepriorityofallotherOBsincreaseswithitsnumber.OnlyonS7-400andWinACthisdefaultpri-oritycanbechanged.EachOBcanbeinterruptedbyOBswithahigherpriority.TableIliststhepossibleOBs.AvailabilityofOBsdependsontheCPUtype.IfmoreOBsofacertaintypearerequired,amoreexpensiveCPUhastobebought.Time-of-dayinterruptOBsarestartedatapreconfiguredtime,e.g.,endofashift,whereastimedelaysinterruptOBsarestartedattheexpirationofaone-shot-timer.CyclicinterruptOBsarestartedwithafixedfrequency.Thetimeintervalandthephaseoffsetcanbeconfiguredwithagranularityof1ms.HardwareinterruptsOBsarestartedbyaaneventataninputorfunctionmodule,e.g.,detectionoftherisingedgeofadigitalsignal.Thisfunctionalityisonlyavailablewithso-called“HighFeature”inputmodules.SynchronouserrorOBsarestartedbyerrorsintheuserprogram,whereasasynchronouserrorinterruptOBsarestartedbyPLCfaults,likepowerfailure,modulefailureortimeerrors.Atimeerroroccurs,whenanOBcannotmeetitsscheduledstarttime,andisanuniquefeatureofPLCs.III.REAL-TIMEPERFORMANCEMEASUREMENTSA.PerformanceEvaluationGoalsAkeyissueofreal-timeperformanceisthereactiontimetoexternalevents.BecausePLCsystemsbasicallyconformtoasynchronousprogrammingmodel,thisisdirectlydeterminedbythecycletime,whichhastobeanalyzedforthefreerunningcycleOB1andcyclicinterrupts;e.g.,OB35.TodeterminetheapplicationareaofPLCclasses,theminimumofhastobemeasuredfordifferentPLCtypes.TheactualvalueofinaspecificapplicationdependsontheamountofcodeinthecyclicOB,ofcourse.TABLEIOBTYPESOFASIMATICS7TABLEIIPLCSUNDERTESTDeterministicbehaviorofaPLCisdeterminedbythejitterof,whichisofprimaryinterestforcyclicinterrupts.With“HighFeature”inputmodules,alsohardwareinterruptsarepossible.Heretheminimumresponsetime,whichisdefinedasthetimetoactivateOB40,anditsjitterhastobemeasured.Inordertogetacompletepicture,themeasurementshavetobeconductedforaminiPLC,amidrangePLCandahigh-endPLC.TableIIshowstheCPUs,thathavebeenselectedforthemeasurementsinthispaper.Thetimeforafloatingpointaddi-tionhasbeenmeasuredbyrepeatingittimes,inordertoconveyanimpressionoftheirrelativeperformance,whichdif-fersconsiderably.BecauseofthedistributednatureofPLC-basedsystems,theimpactofPROFIBUScommunicationtoresponsetimeisanim-492IEEETRANSACTIONSONNUCLEARSCIENCE,VOL.51,NO.3,JUNE2004Fig.4.Experimentsetup.Fig.5.HistogramofOB1cycletimeatIM151/CPU.portantissue.Thustheadditionaldelaysintroducedbycommu-nicationaswellastheadditionaljitterhavetobeanalyzed.Butpresentationofcommunication-relatedmeasurementswouldgobeyondthescopeofthispaperandwillbecoveredbyafuturepublication.Theanalysisoftheresponsetimeasafunctionofthesystemload,e.g.,inducedbyharddiskactivity,communicationorback-groundcomputing,isakeyissueonconventionalPOSIX-likereal-timesystems.ThisisnotanissueonPLCsystemsbe-causeoftheirsynchronouscyclicoperation.Eventhecommu-nicationonfieldbusseslikePROFIBUSDPV0orAS-Interfaceiscyclically,thusinducingaconstantload.Forasynchronoustypeofcommunication,e.g.,TCP/IP,intelligentcommunica-tioncontrollersareused,thusoffloadingtheCPU.AnexceptionfromthisruleistheMPI(MultipointInterface,aproprietaryfieldbus),thatisintegratedineachCPU.ButinJlichMPIisonlyusedforprogramming.B.MeasurementScenarioAccordingtoFig.4theinputsofthePLCsundertest(listedinTableII)areconnectedtoapulsegenerator.OB40isacti-vatedbyarisingedgeoftheinputsignalandtogglesaoutputsignal.TheoutputofthepulsegeneratorandoutputsofthePLCundertestareconnectedtotheNationalInstrumentsanaloginputmoduleNI6062E.Thesignalsaresampledwithafre-Fig.6.HistogramofOB1cycletimeatCPU314C-2DP.quencyof100kHz.Matlabcodehasbeendevelop
温馨提示
- 1. 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。图纸软件为CAD,CAXA,PROE,UG,SolidWorks等.压缩文件请下载最新的WinRAR软件解压。
- 2. 本站的文档不包含任何第三方提供的附件图纸等,如果需要附件,请联系上传者。文件的所有权益归上传用户所有。
- 3. 本站RAR压缩包中若带图纸,网页内容里面会有图纸预览,若没有图纸预览就没有图纸。
- 4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
- 5. 人人文库网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对用户上传分享的文档内容本身不做任何修改或编辑,并不能对任何下载内容负责。
- 6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
- 7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。
最新文档
- 居委会涉疫事件应急预案
- 2024北京市城市管理委员会所属事业单位招聘13人笔试模拟试题及答案解析
- 高一语文教师个人工作总结(4篇)
- 酒店店长年终工作总结(6篇)
- 甘肃省会宁县2023-2024学年中考二模化学试题含解析
- 邮储银行述职报告(30篇)
- 湖北省荆门市2022-2023学年八年级下学期英语期中试卷(含答案)
- 贫血病人诊疗知识考试试题
- 生产制造执行管理系统(MES)解决方案
- 爱中国宣教心
- 七上生物实验报告(共9页)
- 无领导小组讨论评分表(共3页)
- 我国企业境外借壳上市的实证分析与法律规范
- 左室电极靶静脉的选择技巧课件幻灯PPT
- 电脑借用登记表
- 中国知网CNKI的检索与使用技巧
- CAD常用快捷键Word版
- 专题讲座资料(2021-2022年)工程勘察设计收费标准计价格[2002]10号
- (万科粉刷石膏)粉刷石膏技术交底
- 课堂作业的设计
- 农行网银错误信息代码一览精品
评论
0/150
提交评论