2017-01-12 12:44 AM
Hello,
we are currently working on a LIN-Slave Driver for the SPC560D40L1. The use of the hardware-id-filter have made it easy so far but now we fail in one last test where we must distinguish whether the framing error has occurred in the header or in the response.
Is there a way to distinguish these two events in the framing error interrupt with id-filtering activated?
Thank you in advance!
Best regards
Torben
#lin #spc560d #framing-error #linflex2017-01-12 02:19 AM
Hello Torben,
Yes you can.
in the chapter 20 from the RM0045
you should enable the corresponding interrupt
Best regards
Erwan
2017-01-12 03:46 AM
Hello Erwan,
thanks for the quick response.
We have noticed the header error enable flag as well but we can't find the corresponding flag, like mentioned here:
Best Regards
Torben
2017-01-12 08:13 AM
Hello Torben ,
the RM is not clear.
maybe , the Header error Interrupt is triggered in IDPEF Flag for SPC560Dxx Family
Could you try this ?
Best Regards
Erwan
2017-01-13 01:49 AM
Hello Torben ,
After checking with experts ,
For header Error Interrupt, you need to check the flag SFEF , BDEF and IDPEF
For Framing Error Interrupt, you need to check the flag FEF
Best Regards
Erwan
2017-01-13 01:55 AM
Thank you Erwan!
We'll try this on monday!
Best Regards
Torben
2017-01-16 06:10 AM
Hello Erwan,
we tried your suggestion but we still couldn't find out if a framing error has occurred in the identifier of the header or in one of the data bytes of the response.
2017-01-17 12:41 AM
Hello Torben ,
Did you check in your Interruption handler the associated flag ?
Anyway , i am checking with experts.
Best Regards
Erwan
2017-01-17 02:37 AM
Hello Erwan,
yes, we checked it.
It seems like the IDPEF flag, for example, is only for parity errors and is not related to a framing errror.
Parity errors must be handled differently according to the LIN spec.
Best Regards,
Torben
2017-01-18 07:43 AM
According to the RM ,
FEF is the flag relative to Framing Error.
SFEF or BDEF or IDPEF bit is the flag relative to Header Error.
Did you check the others flags ?
BR
Erwan