Specifications

4 CAN I/O Support
4-14
information is of type double and is identical to the return value of function
CANPC_read_rcv_data(…) described in the Softing user manual. Refer to the
manual for more information. The timestamp information is of type double and
outputs the latest time at which a CAN message with the corresponding
identifier has been received. This time information in seconds (with a
resolution of 1 microsecond) can be used to implement timeout-logic within
your model.
The popup menu lets you select which output information is output at each
output port of the block. If
Data is selected each output port signal is a scalar
only. If
Data – Status is selected each output port signal is a vector with two
elements, where the first element contains the data frame and the second
element the status information. If
Data – Status – Timestamp is selected each
output port signal is a vector with three elements, where the first element
contains the data frame, the second element the status information, and the
third element the timestamp.
Generate interrupts — The fourth control (check box) lets you define if the
CAN messages defined in this instance of the block will initiate an interrupt
from the CAN board each time they are received. If checked this allows driving
the model (target application) execution controlled by CAN messages.
Sample time — The fifth control (edit field) defines the sample time at which
the Send block is executed during a model (target application) run.
You can use as many instances of the Receive block in the model as needed. For
example by using two instances of the block with different sample times, CAN
messages can be retrieved at different rates. Or you can use multiple instances
to structure your model more efficiently.