


下载本文档
版权说明:本文档由用户提供并上传,收益归属内容提供方,若内容存在侵权,请进行举报或认领
文档简介
_NCF204_ReadActualPosition_REAL(
1/3)
FBInstanceArea
StartAddress
EndAddress
Size
NoRetain
H512
H1407
896
Retain
H1408
H1535
128
Timers
T3072
T4095
1024
Counters
C3072
C4095
1024
Specifyunu
sedarea.
Therequire
dsizevariesd
FBInstancerea
StartAddress
EndAddress
Si
NoRetain
D32020
D32767
748
Retain
H1408
H1535
128
Timers
T3072
T4095
1024
Counters
C3072
C4095
1024
NCF204
ReadPresentPosition(REAL)_NCF204_ReadActualPosition_REAL
Basicfunction
Readsthepresentpositionofanaxis.
Symbol
_NCF204_ReadActualPosition_REAL
AlwaysON(P_On) (BOOL) (BOOL)
EN ENO
UnitNo. (INT) (BOOL) NormalendUnitNo Done
AxisNo. (INT) (BOOL) ErrorflagAxis Error
Outputenablebit (BOOL) (WORD) Errorcode
Enable ErrorID
(REAL) PresentpositionPosition
Filename
Lib\FBL\omronlib\PositionController\NCF\NCF204ReadActualPositionREAL12.cxf
Applicablemodels
PositionControlUnit
CJ1W-NCF71,CS1W-NCF71
CPUUnit
CS1*-CPU**HUnitVersion3.0orlaterCJ1*-CPU**HUnitVersion3.0orlaterCJ1M-CPU**UnitVersion3.0orlater
CP1H
CX-Programmer
Version5.0orlater
Languagesinfunctionblock
definitions
Ladderprogramming
Conditionsforusage
ThefollowingconditionsforusageshouldbethePositionControlUnitversion1.2orearlier.(ItwillnotberequiredinthePositionControlUnitversion1.3orlater)
CX-ProgrammerSetting
ThefunctionblocksrelatedtothePositionControlUnitswillnotoperateiftheareaH512orhigher(defaultsetting)isspecifiedastheNonRetainAreathroughtheFunctionblockmemoryallocation.Makesuretochangethememoryareatounusedarea(DMorEM,forexample)fromtheCX-Programmer.Tochangethisvalue,clickPLC/FunctionBlockMemory/FunctionBlockMemoryAllocationfromthe Bar.
FunctionBlockMemoryAllocation[NewPLC1]
OK
CancelEditDefault
ependingontheusedFBandthenumberofFBs.Ifanareabeingusedintheladderprogramisspecifiedorsufficientspacecannotbefound,theCX-Programmerwilldisyacompileerror.
FunctionBlocMemoryAllocation[NewPLC1]
OK
CancelEdit
Default Forexample,tousethememoryareafromD32020toD32767
Advanced (748words),specifythe
addressesasshownintheleft.
Functiondescription
ThepresentpositionoftheaxisofthespecifiedUnitNo.(UnitNo)andAxisNo.(Axis)iscontinuouslyupdatedinthe“Presentposition(Position)”whiletheOutputenablebit(Enable)isON.WhentheOutputenablebit(Enable)turnsOFF,the“Presentposition(Position)”isclearedtoallzeros.
TheNormalend(Done)turnsONwhenthepresentpositiondataisvalid.
TheErrorflag(error)willbeturnedONandtheErrorcode(ErrorID)willbeoutputifanerroroccursfortheFB.(TheywillnotbeturnedONwhenaxiserrorsoccurs.)
ThisstatuswillberesetthentheOutputenablebit(Enable)turnsOFF.
Thesestatus(Done/Error/ErrorID)willberesetthentheOutputenablebit(Enable)turnsOFF.
ENONOFF
ENOONOFF
EnableON
OFF
DoneONOFF
ErrorONOFF
ReadPresentONPositionOFF
KindofFBdefinition
Alwayecutiontype.
ConnecttheENinputtotheAlwaysONFlag(P_On).
Thesameinstancecannotbeusedintwoormoreces.
ENinput
condition
・ConnecttheENinputtotheAlwaysONFlag(P_On).
IfanotherbitisconnectedtoEN,theFBoutputswillbeheldwhentheconnectedbitturnsOFF.
RestrictionsOther
・TheErrorflag(Error)andErrorcode(ErrorID)forthisFBreflectthestatusoftheMemoryAreainthePositionControlUnitwithoutaltion.
・ThisFBusesUnitErrorReset,WriteData,ReadDataandSaveDataBitsofthePositionControlUnit(seeNote).Therefore,donotturnthesebitsONorOFFbetweentheperiodfromtherisingedgeofENtotherisingedgeofENO.Forthesamereason,donotusethesebitsforcoiloutputs(OUTcommands).
・TheoutputvariableofFBmaynotchangeevenifENisturnedON.Inthatcase,checkifanyofUnitErrorReset,WriteData,ReadDataandSaveDataBitisleftON.
Note:
Forcalculationofbitaddresses,thesebitsarereferencedinthisFBinthefirstexecutionofeachinstance,andwhenchanging"UnitNo.(UnitNo)","AxisNo.(Axis)"oftheinputvariableandset“Outputenablebit(Enable)".
Applicationexample
WhenturningtheBitAONfromOFF,thepresentpositionofaxis1oftheServomotorconnectedtothePositionControlUnitwithunitnumber0isreadandstoredinD0.
UnitNo.:0
CPU NCF
Servomotor
Axis1
Sample
_NCF204_ReadActualPosition_REAL
AlwaysON(P_On) (BOOL) (BOOL)
EN ENO
UnitNo. (INT) (BOOL) Normalend
&0 UnitNo Done BitB
AxisNo. (INT) (BOOL) Errorflag
&1 Axis Error BitC
Outputenablebit (BOOL) (WORD) Errorcode
BitA Enable ErrorID D100
(REAL) Presentposition
Position D0
Related
manuals
PositionControlUnitsOPERATIONMANUAL(W426-E1)12-4ErrorCodes
VariableTablesInputVariables
Name
Variablename
Datatype
Default
Range
Description
EN
EN
BOOL
1(ON):FBstarted
0(OFF):FBnotstarted
UnitNo.
UnitNo
INT
&0
&0to&15
Specifytheunitnumber.
AxisNo.
Axis
INT
&1
&1to&16
Specifytheaxisnumber.
Outputenablebit
Enable
BOOL
0(OFF)
TurnONtoenableoutput.TurnOFFtoresettheoutput.
OutputVariables
Name
Variablename
Datatype
Range
Description
ENO
ENO
BOOL
1(ON):FBoperatingnormally
0(OFF):FBnotoperatingnormally
・FBnotstarted
・Inputvariableoutoftherange
・FBendedwitherror
・CommonParameterscouldnotberead
Normalend
Done
BOOL
TurnsONforanormalend.
Errorflag
Error
BOOL
TurnsONforanerrorend.
Errorcode
ErrorID
WORD
ReturnstheerrorcodewhenanerrorhasoccurredintheFB.RefertotheRelatedManualsfordetailsonerrors.
Acodeof#0000willbereturnedifanyofthefollowingconditionsissatisfied.
・Inputvariableisoutofrange.
・ThecommonparametersofthePositionControlUnitsareoutofrange.
・Notestablishedcommunicationswithaspecifiedaxis.
Presentposition
Position
REAL
ThepresentpositionoftheaxiscontrolledbythePositionControlUnit.
VersionHistory
Version
Date
Contents
1.00
2004.06.
Originalproduction
1.10
2005.01.
Limitationaboutthesettingtimingwith"UnitNo."and"AxisNo."wasremoved.
1.20
2007.11.
Limitationonreading“Presentposition(Position)"wasremoved.
UpgradeDetails
Version
DetailedContents
1.10
Inversion1.0x,"UnitNo.(UnitNo)"and"AxisNo.(Axis)"mustbesetwhenENwasONand"Outputenablebit(Enable)"wasOFF.Thismeans
温馨提示
- 1. 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。图纸软件为CAD,CAXA,PROE,UG,SolidWorks等.压缩文件请下载最新的WinRAR软件解压。
- 2. 本站的文档不包含任何第三方提供的附件图纸等,如果需要附件,请联系上传者。文件的所有权益归上传用户所有。
- 3. 本站RAR压缩包中若带图纸,网页内容里面会有图纸预览,若没有图纸预览就没有图纸。
- 4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
- 5. 人人文库网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对用户上传分享的文档内容本身不做任何修改或编辑,并不能对任何下载内容负责。
- 6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
- 7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。
最新文档
- 健康促进经费活动方案
- 健康女性活动方案
- 健康武汉活动方案
- 健康相关活动方案
- 健康观摩活动方案
- 健康领域过年活动方案
- 健身房广告新年活动方案
- 健身暑期引流活动方案
- 股权合作协议书13篇
- 外研版九年级下册Module 4 Rules and suggestions Unit 2 Reading课件(内嵌音视频)
- 中建三局三公司安装分公司劳务企业定额
- 《选品与采购》中职全套教学课件
- HG∕T 4591-2014 化工液力透平
- 国家开放大学《工程地质(本)》形考作业-1-4参考答案
- 2024年新疆发声亮剑发言稿3则
- JT-T-1344-2020纯电动汽车维护、检测、诊断技术规范
- 北京市西城区2023-2024学年五年级下学期期末数学试卷
- 【网上书店设计与实现20000字(论文)】
- 江苏省南京市建邺区2023-2024学年五年级下学期6月期末英语试题
- 2024年湖北省武汉市中考语文试卷真题(含答案)
- 福建省漳州市2023-2024学年八年级下学期期末数学试题
评论
0/150
提交评论