can0 口
(1) # ifconfig can0 down (2) # ip link set can0 up type can bitrate 250000RTNETLINK answers: No such device(3) # ip link set can0 type can bitrate 125000(4)# ifconfig can0 upifconfig: ioctl 8914: No such device # dmesg | grep can0[ 0.634034] device: 'can0': device_add[ 0.634268] PM: Adding info for No Bus:can0[ 50.543579] mcp251x spi2.0 can0: bit-timing not yet defined A link change request failed with some changes committed already. Interface can0 may have been left with an inconsistent configuration, please check. rockchip-spi ff130000.spi: cr0 0x2c01, div 4 mcp251x spi2.0: read reg! mcp251x spi2.0: reg:0 mcp251x spi2.0: CANCTRL_REQOP_MASK224 mcp251x spi2.0: CANCTRL REQOP CONF:128 mcp251x spi2.0: hw reset mcp251x spi2.0: hw reset fail ret:-19 rockchip-spi ff130000.spi: cr0 0x2c01, div 4dts中can0为:
&spi2 { status = "okay"; spi_wk2xxx@00{ status = "disabled"; }; mcp2515: can@00 { status = "okay"; compatible = "microchip,mcp2515"; reg = <0x00>; clocks = <&mcp251x_clk>; interrupt-parent = <&gpio0>; interrupts = <1 IRQ_TYPE_EDGE_FALLING>; spi-max-frequency = <24000000>; pinctrl-names = "default"; pinctrl-0 = <&can0_pins>; poll_mode = <0>; enable_dma = <1>; };};
再次感谢,麻烦抽空回复,等待中,不胜感激。
麻烦帮看一下, can0口打开时候,出现mcp251x spi2.0: hw reset fail ret:-19错误 你好,这个问题解决了吗?
页:
[1]