I am trying to connect mcp2515 can bus module with raspi 4b. On using pi@piv2:~ $ sudo ip link set can0 up type can bitrate 125000 the terminal freezes so i downgraded my terminal to 5.4.61-v7l ,t started working after that change. On using dmesg I found the following:

mcp251x spi0.0 can0: MCP2515 successfully initialized.
mcp251x spi0.0 can0: bitrate error 33.3% too high
mcp251x spi0.0 can0: bus-off 

I had also installed can-utils package and tried to verify my connections using candump but no messages are received. My mcp2515 works on 8Mhz, my connections are as follows: Arduino - can module - can module - raspi, I have verified working of arduino can module via oscilloscope. Also I am using 5v to 3.3v logic converters to connect the raspi to can bus. I am following this page: https://forums.raspberrypi.com/viewtopic.php?t=141052

  • You should post details of what YOU did - not link to some obscure post. I don't know what "i downgraded my terminal to 5.4.61-v7l' is supposed to mean.
    – Milliways
    Commented Dec 3, 2022 at 23:33

1 Answer 1


The Forum instruction you linked (which seems rather poor IMO) is far from clear.

I don't know what the ip command you listed will do but it is unlikely to have ANY impact on SPI speed, which is normally set when initialising the interface by an ioctl call.

I haven't used mcp2515 but the Device Tree documentation shows:-

dtoverlay -h mcp2515

Name:   mcp2515

Info:   Configures the MCP2515 CAN controller on spi0/1/2
        For devices on spi1 or spi2, the interfaces should be enabled
        with one of the spi1-1/2/3cs and/or spi2-1/2/3cs overlays.

Usage:  dtoverlay=mcp2515,<param>=<val>

Params: spi<n>-<m>              Configure device at spi<n>, cs<m>
                                (boolean, required)

        oscillator              Clock frequency for the CAN controller (Hz)

        speed                   Maximum SPI frequence (Hz)

        interrupt               GPIO for interrupt signal

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.