65
ifm
Programming Manual
ecomatmobile
CabinetController (CR0301) Runtime System V05
2016-04-21
ifm function elements
ifm function elements for the device CR0301
>
CAN1_EXT_RECEIVE
4302
Unit type = function block (FB)
Unit is contained in the library
ifm_CAN1_EXT_Vxxyyzz.LIB
Symbol in CODESYS:
>
Description
4336
CAN1_EXT_RECEIVE configures a data receive object and reads the receive buffer of the data
object.
The FB must be called once for each data object during initialisation to inform the CAN controller
about the identifiers of the data objects.
In the further program cycle CAN1_EXT_RECEIVE is called for reading the corresponding receive
buffer, this is done several times in case of long program cycles The programmer must ensure by
evaluating the byte AVAILABLE that newly received data objects are retrieved from the buffer and
further processed.
Each call of the FB decrements the byte AVAILABLE by 1. If the value of AVAILABLE is 0, there is no
data in the buffer.
By evaluating the output OVERFLOW, an overflow of the data buffer can be detected. If
OVERFLOW = TRUE at least 1 data object has been lost.
If this unit is to be used, the 1st CAN interface must first be initialised for the extended ID with
CAN1_EXT
(
>
Parameters of the inputs
2172
Parameter
Data type
Description
CONFIG
BOOL
TRUE (in the 1st cycle):
configure data object
FALSE:
during further processing of the program
CLEAR
BOOL
TRUE:
delete receive buffer
FALSE:
function element is not executed
ID
DWORD
Number of the data object identifier:
normal frame (2
11
IDs):
0...2 047 = 0x0000 0000...0x0000 07FF
extended Frame (2
29
IDs):
0...536 870 911 = 0x0000 0000...0x1FFF FFFF
Summary of Contents for Ecomat 100 Mobile CR0301
Page 212: ......