| Author |
Message |
Tilmann Reh
Guest
|
Posted:
Wed Dec 08, 2004 9:15 pm Post subject:
SJA1000 Error Counters |
|
|
Hello,
I need some more detailed information about how *exactly* the error
counters of the SJA1000 (in BasicCAN mode) are working.
The datasheet only tells me that if the transmit error counter
overflows (after 256 errors), the device will stop all bus activities
until it's reactivated under software control.
There seems to be no information about
- which conditions *exactly* cause increments of that error counter;
- if the error counter reset or decremented again upon success transmit;
- can the error counter be cleared under software control by any means;
- receive error counting;
etc.
Unfortunately, though this is a mature chip and in full production for
several years now, additional information at the Philips homepage
becomes less instead of more - several application notes obviously
vanished, and the only one that is still there is of 1997.
The SJA1000 is used in BasicCAN mode in the current application,
not in PeliCAN mode. There are more detailed tables about error
conditions and their effect on the error counters in the PeliCAN-
specific section of the application note (AN 97076). Nothing like
this is mentioned on the pages about BasicCAN - do these tables
also apply to BasicCAN, though they explicitly are in the PeliCAN
section?
Thanks for any hints or links that can shed some light on this...
--
Dipl.-Ing. Tilmann Reh
Autometer GmbH Siegen - Elektronik nach Maß.
http://www.autometer.de |
|
| Back to top |
|
 |
Mouarf
Guest
|
Posted:
Wed Dec 08, 2004 10:08 pm Post subject:
Re: SJA1000 Error Counters |
|
|
the errors that cause counters increment are parts of the CAN specification
itself,
see http://wiki.daimi.au.dk/oodist/_files/can2spec.pdf for example (p25).
The "official" errors are described p24.
I do not know if you can reset the error counter by software on this chip
but I've seen on Fujitsu µC for example that the error counters can not be
modified by the software. That's one reason why some CAN controllers now
integrates a listen-only mode in order to:
- not to send ACK on the bus
- not to care about errors on the bus (and do not go into a bus off mode)
Nevertheless, a bus off state does not mean no RX (at least no TX or ACK)!
Does it fit to your question?
Mouarf
"Tilmann Reh" <tilmannreh@despammed.com> schrieb im Newsbeitrag
news:cp79fv$hjv$1@online.de...
| Quote: | Hello,
I need some more detailed information about how *exactly* the error
counters of the SJA1000 (in BasicCAN mode) are working.
The datasheet only tells me that if the transmit error counter
overflows (after 256 errors), the device will stop all bus activities
until it's reactivated under software control.
There seems to be no information about
- which conditions *exactly* cause increments of that error counter;
- if the error counter reset or decremented again upon success transmit;
- can the error counter be cleared under software control by any means;
- receive error counting;
etc.
Unfortunately, though this is a mature chip and in full production for
several years now, additional information at the Philips homepage
becomes less instead of more - several application notes obviously
vanished, and the only one that is still there is of 1997.
The SJA1000 is used in BasicCAN mode in the current application,
not in PeliCAN mode. There are more detailed tables about error
conditions and their effect on the error counters in the PeliCAN-
specific section of the application note (AN 97076). Nothing like
this is mentioned on the pages about BasicCAN - do these tables
also apply to BasicCAN, though they explicitly are in the PeliCAN
section?
Thanks for any hints or links that can shed some light on this...
--
Dipl.-Ing. Tilmann Reh
Autometer GmbH Siegen - Elektronik nach Maß.
http://www.autometer.de |
|
|
| Back to top |
|
 |
Hans-Bernhard Broeker
Guest
|
Posted:
Wed Dec 08, 2004 11:33 pm Post subject:
Re: SJA1000 Error Counters |
|
|
Tilmann Reh <tilmannreh@despammed.com> wrote:
| Quote: | I need some more detailed information about how *exactly* the error
counters of the SJA1000 (in BasicCAN mode) are working.
|
Did you see the notice that points you at an other controller the
SJA1000 in BasicCAN mode is designed to be compatible to? Odds are,
what isn't described in SJA1000_3.pdf, you'll find in that
controller's datasheet.
| Quote: | The datasheet only tells me that if the transmit error counter
overflows (after 256 errors), the device will stop all bus activities
until it's reactivated under software control.
There seems to be no information about
- which conditions *exactly* cause increments of that error counter;
- if the error counter reset or decremented again upon success transmit;
- can the error counter be cleared under software control by any means;
- receive error counting;
|
IIRC, most of that is documented in the CAN spec itself already, which
see.
--
Hans-Bernhard Broeker (broeker@physik.rwth-aachen.de)
Even if all the snow were burnt, ashes would remain. |
|
| Back to top |
|
 |
Paul Probert
Guest
|
Posted:
Thu Dec 09, 2004 2:28 am Post subject:
Re: SJA1000 Error Counters |
|
|
Tilmann Reh wrote:
| Quote: | Hello,
I need some more detailed information about how *exactly* the error
counters of the SJA1000 (in BasicCAN mode) are working.
I don't have the specific information you want, but I remember this: |
The error count is decremented a little every time you get ( or send ??) a message
successfully, so there is no need to manually reset the counter. If you fix your
error condition, after a certain amount of traffic the chip forgets there ever were
any errors. Of course, you could always re-initialize the whole chip.
--
o__ | Paul Probert
,>/'_ | Associate Scientist
(_)\(_) | The University of Wisconsin-Madison
| Dept. of Electrical and Computer Engineering |
|
| Back to top |
|
 |
Tilmann Reh
Guest
|
Posted:
Thu Dec 09, 2004 12:45 pm Post subject:
Re: SJA1000 Error Counters |
|
|
Mouarf schrieb:
Thanks for the link. I intended to search the original specification
anyways...
However, what I really was/am wondering about is the fact that this
behaviour is similarly described in the SJA1000 application note -
without the decrementing conditions, and only for PeliCAN mode, however.
| Quote: | I do not know if you can reset the error counter by software on this chip
but I've seen on Fujitsu µC for example that the error counters can not be
modified by the software. That's one reason why some CAN controllers now
integrates a listen-only mode in order to:
- not to send ACK on the bus
- not to care about errors on the bus (and do not go into a bus off mode)
Nevertheless, a bus off state does not mean no RX (at least no TX or ACK)!
|
But if a device enters bus off state, it will not respond to anything
on the bus. (Passive and active error states are described in the
documents about the SJA1000, but no exact rules about how the error
counters are behaving in BasicCAN mode...)
| Quote: | Does it fit to your question?
|
Partly. :-)
Many thanks,
--
Dipl.-Ing. Tilmann Reh
Autometer GmbH Siegen - Elektronik nach Maß.
http://www.autometer.de |
|
| Back to top |
|
 |
Tilmann Reh
Guest
|
Posted:
Thu Dec 09, 2004 12:53 pm Post subject:
Re: SJA1000 Error Counters |
|
|
Hans-Bernhard Broeker schrieb:
| Quote: | I need some more detailed information about how *exactly* the error
counters of the SJA1000 (in BasicCAN mode) are working.
Did you see the notice that points you at an other controller the
SJA1000 in BasicCAN mode is designed to be compatible to? Odds are,
what isn't described in SJA1000_3.pdf, you'll find in that
controller's datasheet.
|
I know the predecessor, the 82C200. Unfortunately, I started CAN
development in 1997 when the SJA1000 just came out - so I used
that one right from the start, and I don't have the 82C200
datasheet or related application notes. Unfortunately, these
also obviously vanished from the web - I did not find any detailed
reference or the datasheet.
If you have it, I would be lucky if you could send it by mail.
| Quote: | The datasheet only tells me that if the transmit error counter
overflows (after 256 errors), the device will stop all bus activities
until it's reactivated under software control.
There seems to be no information about
- which conditions *exactly* cause increments of that error counter;
- if the error counter reset or decremented again upon success transmit;
- can the error counter be cleared under software control by any means;
- receive error counting;
IIRC, most of that is documented in the CAN spec itself already, which
see.
|
Yes - but the SJA1000 data sheet and/or application notes should
contain the exact implementation details anyway. What still puzzles
me is the mentioning of all error handling details only for PeliCAN
mode...
Thanks,
--
Dipl.-Ing. Tilmann Reh
Autometer GmbH Siegen - Elektronik nach Maß.
http://www.autometer.de |
|
| Back to top |
|
 |
Tilmann Reh
Guest
|
Posted:
Thu Dec 09, 2004 12:55 pm Post subject:
Re: SJA1000 Error Counters |
|
|
Paul Probert schrieb:
| Quote: | I need some more detailed information about how *exactly* the error
counters of the SJA1000 (in BasicCAN mode) are working.
I don't have the specific information you want, but I remember this:
The error count is decremented a little every time you get ( or send ??) a message
successfully, so there is no need to manually reset the counter. If you fix your
error condition, after a certain amount of traffic the chip forgets there ever were
any errors. Of course, you could always re-initialize the whole chip.
|
From the CAN specification, this should be true.
I was missing the exact implementation details for the SJA1000 in
its datasheet or application note...
Thanks,
--
Dipl.-Ing. Tilmann Reh
Autometer GmbH Siegen - Elektronik nach Maß.
http://www.autometer.de |
|
| Back to top |
|
 |
Hans-Bernhard Broeker
Guest
|
Posted:
Thu Dec 09, 2004 5:44 pm Post subject:
Re: SJA1000 Error Counters |
|
|
Tilmann Reh <tilmannreh@despammed.com> wrote:
| Quote: | that one right from the start, and I don't have the 82C200
datasheet or related application notes.
[...]
If you have it, I would be lucky if you could send it by mail.
|
Google finds http://www.e-lab.de/downloads/DOCs/PCA82C200.pdf
Anyway, I don't think you really need the 82C200 datasheet. Scanning
over the SJA100_3.pdf, I saw a short notice that essentially said that
in BasicCAN mode, its error counters behave exactly as specified in
the CAN spec itself. Given that you don't get to read them out in
this mode, anyway, that's about all you'll ever know about it.
| Quote: | Yes - but the SJA1000 data sheet and/or application notes should
contain the exact implementation details anyway.
|
That you'll have to bring to Philips' attention, not ours. ;-)
OTOH, if you think this through to conclusion, requiring this would
mean every CAN device's documentation would have to include a verbatim
copy of large parts of the CAN spec --- that can't really be useful,
and might even be impossible: the official CAN spec (ISO-whatever)
costs money.
Describing the BasicCAN mode of the SJA1000 as "same as 82C200, with
the following changes:" probably made sense back when the SJA1000
datasheet was written, but not any longer. Not unless they keep the
82C200 one available, that is.
| Quote: | What still puzzles me is the mentioning of all error handling
details only for PeliCAN mode...
|
That's because PeliCAN is more complex, and implements lots of things
that aren't covered by the CAN spec, and thus have to be documented
explicitly rather than by reference.
--
Hans-Bernhard Broeker (broeker@physik.rwth-aachen.de)
Even if all the snow were burnt, ashes would remain. |
|
| Back to top |
|
 |
Tilmann Reh
Guest
|
Posted:
Thu Dec 09, 2004 6:10 pm Post subject:
Re: SJA1000 Error Counters |
|
|
Hans-Bernhard Broeker schrieb:
This is interesting... I searched for "82c200" only, and got no
useful hit - however, there were some notes on CAN homepages mentioning
that the 82C200 datasheet was not available... (Perhaps I should
inform those webmasters about the link you provided. :-) )
Thanks!
| Quote: | Anyway, I don't think you really need the 82C200 datasheet. Scanning
over the SJA100_3.pdf, I saw a short notice that essentially said that
in BasicCAN mode, its error counters behave exactly as specified in
the CAN spec itself. Given that you don't get to read them out in
this mode, anyway, that's about all you'll ever know about it.
Yes - but the SJA1000 data sheet and/or application notes should
contain the exact implementation details anyway.
That you'll have to bring to Philips' attention, not ours. ;-)
OTOH, if you think this through to conclusion, requiring this would
mean every CAN device's documentation would have to include a verbatim
copy of large parts of the CAN spec --- that can't really be useful,
and might even be impossible: the official CAN spec (ISO-whatever)
costs money.
|
OK, I can agree to that.
Thanks for your help.
--
Dipl.-Ing. Tilmann Reh
Autometer GmbH Siegen - Elektronik nach Maß.
http://www.autometer.de |
|
| Back to top |
|
 |
|
|
|
|