100%(1)100% found this document useful (1 vote) 688 views3 pagesSFC14
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content,
claim it here.
Available Formats
Download as PDF or read online on Scribd
Reading Consistent Data of a DP Standard Slave//PROFINET lO
Device with SFC 14 “DPRD_DAT"
Data Consistency
Refer to the section Overview of S7 Cammunication and $7 Basic Communication - Data consistency
Purpose of SFC 14
You require SFC 14 "DPRD_DAT" because you can only read out a maximum of four continuous bytes
using load instructions that access the /Os or the process image input table,
Note
IFrequired, you can also read consistent data via the process image of the inputs. To
determine whether the CPU supports this functionality, refer to the "Automation System
‘S7-300, Hardware and installation manual
All $7-400 CPUs support this functionality
AN Caution
When using SFC 14"DPRD_DAT", avoid accessing I/O areas that have process
image partitions with OB6x connections (clocked interrupts) assigned to them,
Description
With SFC 14 "DPRD_DAT" (read consistent data of a OP standard slave), you read the consistent data
of a DP standard slave/PROFINET IO device,
To find the maximum length that applies for S7-300 CPUs, refer to the manuals, Automation System
87-300, Hardware and Installation, ET 200S interface Submodule, 1M151-7 CPU, or Base Submodule
BM147CPU. For S7-400 CPUs refer to the manual Automation System S7-400 CPU Data. If no error
occurred during the data transfer, the data that have been read are entered in the destination area
identified by RECORD.
‘The destination area must have the same length as configured for the selected module with STEP 7.
Ifyou read from @ DP standard slave with a modular design or with several DP identifiers, you can only
access the data of one module/DP identifier per SFC 14 call specifying the configured start address.
Note
‘An access with SFC 14 "DPRD_DAT" can only be to data areas that are three or more than,
four bytes long. Otherwise the aocess is rejected with the error code W#16#8090,
Parameter Declaration DataType © Memory Area Description
LADDR = INPUT = WORD 1,Q,M,D,L, Configured start address from the | area
constant Cf the module from which the data will
beread.
Note:
Addresses have to be entered in
hexadecimal format. Far example,
diagnostic address 100 means:
LADDR=Ww#16#64,
RETVAL OUTPUT INT. L.Q.M,D,L fan error occurs while the function is
active, the return value contains an error
code.
RECORD OUTPUT ANY. 1,Q,M,D,L Destination area for the read user data,
‘This must be exactly as long as you
configured for the selected module with
STEP 7. Only data type BYTE is
permitted.
Note: Note that the RECORD parameter
‘of $7-300 CPUs always requires the full
‘specification of the DB parameters (for
‘example: P#DB1 DBXO.0 byte 100),
‘Omitting an explicit DB no. is not
permitted for $7-00 CPUs and causes
lan error message in the user program,
Error Information
Note
Ifyou access DPV slaves, error information from these slaves can be forwarded fram the
DP master to the SFC. For details on this error information, see Receiving an Interrupt from
a DP Slave with SFB 54 "RALRM" STATUS[3}
Error Code (Wi#16#t..) Explanation
000 No error occurred,
090 ‘= You have not configured a module for the specified logical base address
or
‘+ you have ignored the restriction concerning the length of consistent data
or
‘+ you have not entered the start address in the LADDR parameter in
hexadecimal format
e092 A type other than BYTE is specified in the ANY reference,
8093 No DP modulelPROFINET IO device from which you can read consistent
data exists at the logical address specified in LADDR,
80A0 Access error detected while the I/O devices were being accessed
8080 Slave failure on external DP interface module.
8081 The length of the specified destination area is not identical to the user data
length configured with STEP 7.
082 ‘System error with external DP interface module.
8083 System error with external DP interface module,
aco The data haver't yet bean read by the module,
goc2 ‘System error with extemal DP interface module.
80Fx System error with external DP interface module,87Ky System error with external DP interface module,
08x System error with external DP interface module.
Bay General error information, see Evaluating Errors with the Output Parameter
RET VAL