Continue to Site

Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

  • Congratulations cowski on being selected by the Eng-Tips community for having the most helpful posts in the forums last week. Way to Go!

Function block prog. in Pascal

Status
Not open for further replies.

mumarzia

Automotive
May 17, 2004
1
Dear Fellows,
Can any body let me know the web address or other stuff from where I can learn programming the function blocks in pascal for S7.

I have a problem in understanding a command

temp:=DWORD_TO_REAL(db20.dbd0)

how it works.

Bye,
Umar Zia
 
Replies continue below

Recommended for you

Hello, mumarzia;
I only saw your post today, ans I hoope this answer will still be usefull.

Siemens' Pascal-like language is called SCL, and you can find the SCL programming manual at this address:


The instruiction you are looking at is a Typecast function; the value in DB20.DBD0 is a DWORD format, which you convert to a REAL (IEEE floating-point value) before loading it to the variable "temp" (which presumably has been declared as a REAL value).

Hope this helps,
Daniel Chartier
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor