Hello Everyone.
I have an application in which my pcan router pro is keeping sensors alive on CAN2,CAN3, and CAN4 alive by sending cyclic messages to them. It is possible for these sensors to fail for various reasons. I would like to be able to monitor the bus states and report any BUS-OFF states to CAN1. I do not see any functions for monitoring this but perhaps I can read a register somewhere.
Thanks,
Steve
Monitoring Bus States
Re: Monitoring Bus States
hi,
you can read e.g. C1GSR register and test for bit 7. If set, the CAN controller is Bus-OFF. Use CnGSR (n=1..4) for
each CAN bus.
Regards
Philipp
you can read e.g. C1GSR register and test for bit 7. If set, the CAN controller is Bus-OFF. Use CnGSR (n=1..4) for
each CAN bus.
Regards
Philipp
--------------------------------------------
PEAK-System HW development Team
support@peak-system.com
phone: +49-6151-8173-20
fax: +49-6151-8173-29
--------------------------------------------
PEAK-System HW development Team
support@peak-system.com
phone: +49-6151-8173-20
fax: +49-6151-8173-29
--------------------------------------------