Wolfgang Grandegger wrote:
> Hi Christian,
>
> christian pellegrin wrote:
>> The following patch adds the possibility to monitor TEC/REC. I found
>> it quite useful for understanding how the bus works. I see that not
>> all controllers support is but for those that do it might be useful.
>
> It might be useful for debugging, I agree, but is it useful for the real
> user? Kurt posted a similar patch using SysFS some time ago and we
> didn't take it because it is not supported on all systems. Instead, we
> would like to add the TEC and REC value, if possible, to the data[6..7]
> fields of the error frame. This information is hardware specific anyhow.
> Would that fit your needs?
Well, it's not the same thing and as we need to touch iproute2 anyway
for the bus-error addition, I tend to add your TXerr an RXerr counter
stuff, but not as part of the statistic counters. It should be handled
via separate IFLA_CAN_ERROR_COUNTER request, which returns an error if
it is not available. The ip utility should display it after state, where
it logically belongs to:
$ ip -details -statistics link show can0
2: can0: <NOARP,UP,LOWER_UP,ECHO> mtu 16 qdisc pfifo_fast state UP qlen 10
link/can
can <TRIPLE-SAMPLING> restart-ms 100
state ERROR-ACTIVE (error-counter tx 127 rx 240)
The error counters are only displayed if readable. Any other opinions or
improvements? Would that be useful for real users?
Wolfgang.
_______________________________________________
Socketcan-users mailing list
[email protected]
https://lists.berlios.de/mailman/listinfo/socketcan-users