EasyManuals Logo

ST SPC560P34 User Manual

ST SPC560P34
936 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #521 background imageLoading...
Page #521 background image
RM0046 LIN Controller (LINFlex)
Doc ID 16912 Rev 5 521/936
Data reception (transceiver as subscriber)
To receive data from a slave node, the master sends a header with the corresponding
identifier. LINFlex stores the data received from the slave in the message buffer and stores
the message status in the LINSR.
If the response has been received successfully, the LINSR[DRF] is set. In case of error, the
DRF flag is not set and the corresponding error flag is set in the LINESR (see Section , Error
handling).
It is possible to handle frames with a Response size larger than 8 bytes of data (extended
frames). If the data field length in the BIDR is configured with a value higher than 8 data
bytes, the LINSR[DBFF] bit is set once the first 8 bytes have been received. The application
has to read the buffer BDR before resetting the DBFF bit. Once the last data byte (or the
checksum byte) has been received, the DRF flag is set.
Data discard
To discard data from a slave, the BIDR[DIR] bit must be reset and the LINCR2[DDRQ] bit
must be set before starting the header transmission.
Error detection
LINFlex is able to detect and handle LIN communication errors. A code stored in the LIN
error status register (LINESR) signals the errors to the software.
In Master mode, the following errors are detected:
â—Ź Bit error: During transmission, the value read back from the bus differs from the
transmitted value.
â—Ź Framing error: A dominant state has been sampled on the stop bit of the currently
received character (synch field, identifier field or data field).
â—Ź Checksum error: The computed checksum does not match the received one.
â—Ź Response and Frame timeout: See Section 21.8.3, 8-bit timeout counter, for more
details.
Error handling
In case of Bit Error detection during transmission, LINFlex stops the transmission of the
frame after the corrupted bit. LINFlex returns to idle state and an interrupt is generated if
LINIER[BEIE] = 1.
During reception, a Framing Error leads LINFlex to discard the current frame. LINFlex
returns immediately to idle state. An interrupt is generated if LINIER[FEIE] = 1.
During reception, a Checksum Error leads LINFlex to discard the received frame. LINFlex
returns to idle state. An interrupt is generated if LINIER[CEIE] = 1.
Overrun
Once the messages buffer is full (LINSR[RMB] = 1) the next valid message reception leads
to an overrun and message is lost. The hardware signals the overrun condition by setting

Table of Contents

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the ST SPC560P34 and is the answer not in the manual?

ST SPC560P34 Specifications

General IconGeneral
BrandST
ModelSPC560P34
CategoryMicrocontrollers
LanguageEnglish

Related product manuals