diff options
author | Andre Hartmann <aha_1980@gmx.de> | 2016-12-11 14:54:59 +0100 |
---|---|---|
committer | André Hartmann <aha_1980@gmx.de> | 2017-01-10 14:12:32 +0000 |
commit | 66fd2b9655d5f34f880b8daf8b2f422a27789517 (patch) | |
tree | 3eb5ab7d49e12029171eb0f227a559f5efd7fc07 /src | |
parent | 2312a704b7dae74be562af3e82ab3b788d7a0d6a (diff) |
SocketCAN: Describe how to recover from bus errors
Taken from https://www.kernel.org/doc/Documentation/networking/can.txt
section 6.5.3:
A device may enter the "bus-off" state if too many errors occurred on
the CAN bus. Then no more messages are received or sent. An automatic
bus-off recovery can be enabled by setting the "restart-ms" to a
non-zero value, e.g.:
$ ip link set canX type can restart-ms 100
Change-Id: I80b53e430988c0405269d4efe21f936ace0e3544
Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
Reviewed-by: Rolf Eike Beer <eb@emlix.com>
Diffstat (limited to 'src')
-rw-r--r-- | src/serialbus/doc/src/socketcan.qdoc | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/serialbus/doc/src/socketcan.qdoc b/src/serialbus/doc/src/socketcan.qdoc index b5d7db6..919955d 100644 --- a/src/serialbus/doc/src/socketcan.qdoc +++ b/src/serialbus/doc/src/socketcan.qdoc @@ -52,6 +52,12 @@ sudo ip link set up can0 type can bitrate 250000 \endcode + To automatically recover from "bus off" errors after 100 milliseconds, + the following command can be used: + \code + sudo ip link set up can0 type can bitrate 250000 restart-ms 100 + \endcode + \section2 Setting up a virtual CAN bus \note For CAN FD usage, the MTU (Maximum Transmission Unit) has to be set |