Example 09/02
CP 243-1
68 J31069-D0428-U001-A1-7618
LD Always_On
CALL ETH0_CTRL, cp_ready, ch_ready, cp_error
Symbol Address Comment
Always_On
SM0.0 Always 1 for system-related reasons
ch_ready
MB1
cp_error
MW2
cp_ready
M0.0
ETH0_CTRL
SBR1 This POU was generated by the Ethernet Wizard for use with CP243-1
NETWORK 2
As soon as channel 0 is ready for transmission and "ch0_ready" is set, the "start"
variable is set. This can take several cycles.
LD ch0_ready
S start, 1
Symbol Address Comment
ch0_ready
M1.0 Bit for channel 0 in the CH_READY return value of the ETH0_CTRL
subroutine
start
M4.0 Flip-flop for automatic start of data transmission
NETWORK 3
For an S7-200, the "First_Scan_On" bit is only set in the first cycle for system-related rea-
sons. Thus, the "start" variable is reset. This procedure is required so that the "start" variable
always generates a switching edge for the start of the ETHx_XFR subroutine, even for re-
peated start/stop procedures of the CPU.
LD First_Scan_On
R start, 1
Symbol Address Comment
First_Scan_On
SM0.1 1 in the first cycle (for system-related reasons), otherwise always 0
start
M4.0 Flip-flop for automatic start of data transmission