Raspberry Pi 4B CAN HAT support ?

I got a Raspberry Pi 4B with a RS485 CAN HAT.
FreeBSD 14.0-RELEASE is working perfectly fine but I am not able to see / interact with my CAN HAT.. Is there a need to add some special parameters ? (I already added the ones from the documentation) or CAN HAT is not supported by FreeBSD ?

Thanks
 
Code:
# dmesg | egrep -i can\|spi
WARNING: Cannot find freebsd,dts-version property, cannot check DTB compliance
regfix0: Cannot configure GPIO pin: 5
regfix0: Cannot register regulator.
regfix2: Cannot set GPIO pin: 6
regfix2: Cannot register regulator.
spi0: <BCM2708/2835 SPI controller> mem 0x7e204000-0x7e2041ff irq 18 on simplebus0
spibus0: <OFW SPI bus> on spi0
spibus0: <unknown card> at cs 0 mode 0
spibus0: <unknown card> at cs 1 mode 0
 
Thanks Starcat for your findings !

So it is definitely not instantiated correctly as I don't have anything either on dmesg, /dev or ifconfig..

I am wondering if something is missing in /boot/efi/config.txt

I tried that :
[all] arm_64bit=1 dtparam=audio=on,i2c_arm=on,spi=on dtoverlay=mmc dtoverlay=disable-bt dtoverlay=mcp2515-can0,oscillator=8000000,interrupt=25,spimaxfrequency=1000000 device_tree_address=0x4000 kernel=u-boot.bin [pi4] hdmi_safe=1 armstub=armstub8-gic.bin enable_uart=1
 
Thanks tingo .

I added both
rc_debug="YES" rc_info="YES"
to my /etc/rc.conf, here is the result :

---<<BOOT>>--- GDB: debug ports: uart GDB: current port: uart KDB: debugger backends: ddb gdb KDB: current backend: ddb WARNING: Cannot find freebsd,dts-version property, cannot check DTB compliance Copyright (c) 1992-2024 The FreeBSD Project. Copyright (c) 1979, 1980, 1983, 1986, 1988, 1989, 1991, 1992, 1993, 1994 The Regents of the University of California. All rights reserved. FreeBSD is a registered trademark of The FreeBSD Foundation. FreeBSD 15.0-CURRENT #0 main-n269103-112783ebbc31: Thu Apr 4 05:48:15 UTC 2024 root@releng3.nyi.freebsd.org:/usr/obj/usr/src/arm64.aarch64/sys/GENERIC arm64 FreeBSD clang version 17.0.6 (https://github.com/llvm/llvm-project.git llvmorg-17.0.6-0-g6009708b4367) WARNING: WITNESS option enabled, expect reduced performance. VT(efifb): resolution 592x448 module scmi already present! real memory = 4148158464 (3955 MB) avail memory = 4016869376 (3830 MB) Starting CPU 1 (1) Starting CPU 2 (2) Starting CPU 3 (3) FreeBSD/SMP: Multiprocessor System Detected: 4 CPUs random: unblocking device. random: entropy device external interface kbd0 at kbdmux0 ofwbus0: <Open Firmware Device Tree> simplebus0: <Flattened device tree simple bus> on ofwbus0 ofw_clkbus0: <OFW clocks bus> on ofwbus0 simplebus1: <Flattened device tree simple bus> on ofwbus0 simplebus2: <Flattened device tree simple bus> on ofwbus0 regfix0: <Fixed Regulator> on ofwbus0 clk_fixed4: clock-fixed has no clock-frequency clk_fixed4: clock-fixed has no clock-frequency regfix1: <Fixed Regulator> on ofwbus0 regfix2: <Fixed Regulator> on ofwbus0 regfix3: <Fixed Regulator> on ofwbus0 regfix4: <Fixed Regulator> on ofwbus0 simplebus3: <Flattened device tree simple bus> on ofwbus0 simple_mfd0: <Simple MFD (Multi-Functions Device)> mem 0x7d5d2000-0x7d5d2eff on simplebus0 bcm2835_firmware0: <BCM2835 Firmware> on simplebus0 ofw_clkbus1: <OFW clocks bus> on bcm2835_firmware0 clk_fixed4: clock-fixed has no clock-frequency clk_fixed4: clock-fixed has no clock-frequency clk_fixed4: clock-fixed has no clock-frequency clk_fixed4: clock-fixed has no clock-frequency psci0: <ARM Power State Co-ordination Interface Driver> on ofwbus0 clk_fixed4: clock-fixed has no clock-frequency clk_fixed4: clock-fixed has no clock-frequency clk_fixed4: clock-fixed has no clock-frequency clk_fixed4: clock-fixed has no clock-frequency clk_fixed4: clock-fixed has no clock-frequency clk_fixed4: clock-fixed has no clock-frequency clk_fixed4: clock-fixed has no clock-frequency clk_fixed4: clock-fixed has no clock-frequency clk_fixed4: clock-fixed has no clock-frequency clk_fixed4: clock-fixed has no clock-frequency clk_fixed4: clock-fixed has no clock-frequency clk_fixed4: clock-fixed has no clock-frequency clk_fixed4: clock-fixed has no clock-frequency clk_fixed4: clock-fixed has no clock-frequency clk_fixed4: clock-fixed has no clock-frequency clk_fixed4: clock-fixed has no clock-frequency gic0: <ARM Generic Interrupt Controller> mem 0x40041000-0x40041fff,0x40042000-0x40043fff,0x40044000-0x40045fff,0x40046000-0x40047fff irq 30 on simplebus0 gic0: pn 0x2, arch 0x2, rev 0x1, implementer 0x43b irqs 256 clk_fixed4: clock-fixed has no clock-frequency clk_fixed4: clock-fixed has no clock-frequency clk_fixed4: clock-fixed has no clock-frequency clk_fixed4: clock-fixed has no clock-frequency gpio0: <BCM2708/2835 GPIO controller> mem 0x7e200000-0x7e2000b3 irq 14,15 on simplebus0 gpiobus0: <OFW GPIO bus> on gpio0 gpio1: <Raspberry Pi Firmware GPIO controller> on bcm2835_firmware0 gpiobus1: <GPIO bus> on gpio1 regfix0: Cannot configure GPIO pin: 5 REGNODE_INIT failed: 6 regfix0: Cannot register regulator. clk_fixed4: clock-fixed has no clock-frequency clk_fixed4: clock-fixed has no clock-frequency regfix2: Cannot set GPIO pin: 6 REGNODE_INIT failed: 6 regfix2: Cannot register regulator. mbox0: <BCM2835 VideoCore Mailbox> mem 0x7e00b880-0x7e00b8bf irq 13 on simplebus0 clk_fixed4: clock-fixed has no clock-frequency clk_fixed4: clock-fixed has no clock-frequency gpioregulator0: <GPIO controlled regulator> on ofwbus0 clk_fixed4: clock-fixed has no clock-frequency clk_fixed4: clock-fixed has no clock-frequency clk_fixed4: clock-fixed has no clock-frequency clk_fixed4: clock-fixed has no clock-frequency generic_timer0: <ARMv8 Generic Timer> irq 4,5,6,7 on ofwbus0 Timecounter "ARM MPCore Timecounter" frequency 54000000 Hz quality 1000 Event timer "ARM MPCore Eventtimer" frequency 54000000 Hz quality 1000 clk_fixed4: clock-fixed has no clock-frequency clk_fixed4: clock-fixed has no clock-frequency clk_fixed4: clock-fixed has no clock-frequency clk_fixed4: clock-fixed has no clock-frequency clk_fixed4: clock-fixed has no clock-frequency clk_fixed4: clock-fixed has no clock-frequency clk_fixed4: clock-fixed has no clock-frequency clk_fixed4: clock-fixed has no clock-frequency clk_fixed4: clock-fixed has no clock-frequency clk_fixed4: clock-fixed has no clock-frequency clk_fixed4: clock-fixed has no clock-frequency clk_fixed4: clock-fixed has no clock-frequency clk_fixed4: clock-fixed has no clock-frequency clk_fixed4: clock-fixed has no clock-frequency clk_fixed4: clock-fixed has no clock-frequency clk_fixed4: clock-fixed has no clock-frequency clk_fixed4: clock-fixed has no clock-frequency clk_fixed4: clock-fixed has no clock-frequency clk_fixed4: clock-fixed has no clock-frequency clk_fixed4: clock-fixed has no clock-frequency bcm_dma0: <BCM2835 DMA Controller> mem 0x7e007000-0x7e007aff irq 31,32,33,34,35,36,37,38,39,40,41 on simplebus0 usb_nop_xceiv0: <USB NOP PHY> on ofwbus0 clk_fixed4: clock-fixed has no clock-frequency clk_fixed4: clock-fixed has no clock-frequency clk_fixed4: clock-fixed has no clock-frequency clk_fixed4: clock-fixed has no clock-frequency bcm2835_clkman0: <BCM283x Clock Manager> mem 0x7e101000-0x7e102fff on simplebus0 gpioc0: <GPIO controller> on gpio0 uart0: <PrimeCell UART (PL011)> mem 0x7e201000-0x7e2011ff irq 16 on simplebus0 uart0: console (115200,n,8,1) spi0: <BCM2708/2835 SPI controller> mem 0x7e204000-0x7e2041ff irq 18 on simplebus0 spibus0: <OFW SPI bus> on spi0 spibus0: <unknown card> at cs 0 mode 0 spibus0: <unknown card> at cs 1 mode 0 sdhci_bcm0: <Broadcom 2708 SDHCI controller> mem 0x7e300000-0x7e3000ff irq 24 on simplebus0 mmc0: <MMC/SD bus> on sdhci_bcm0 iichb0: <BCM2708/2835 BSC controller> mem 0x7e804000-0x7e804fff irq 27 on simplebus0 bcmwd0: <BCM2708/2835 Watchdog> mem 0x7e100000-0x7e100113,0x7e00a000-0x7e00a023,0x7ec11000-0x7ec1101f on simplebus0 bcmrng0: <Broadcom BCM2835/BCM2838 RNG> mem 0x7e104000-0x7e104027 on simplebus0 gpioc1: <GPIO controller> on gpio1 fb0: <BCM2835 VT framebuffer driver> on simplebus0 fb0: keeping existing fb bpp of 32 fbd0 on fb0 WARNING: Device "fb" is Giant locked and may be deleted before FreeBSD 15.0. VT: Replacing driver "efifb" with new "fb". fb0: 592x448(592x448@0,0) 32bpp fb0: fbswap: 1, pitch 2368, base 0x3eaf5000, screen_size 1060864 sdhci_bcm1: <Broadcom 2708 SDHCI controller> mem 0x7e340000-0x7e3400ff irq 79 on simplebus1 mmc1: <MMC/SD bus> on sdhci_bcm1 pmu0: <Performance Monitoring Unit> irq 0,1,2,3 on ofwbus0 cpulist0: <Open Firmware CPU Group> on ofwbus0 cpu0: <Open Firmware CPU> on cpulist0 bcm2835_cpufreq0: <CPU Frequency Control> on cpu0 pcib0: <BCM2838-compatible PCI-express controller> mem 0x7d500000-0x7d50930f irq 80,81 on simplebus2 pcib0: hardware identifies as revision 0x304. pci0: <OFW PCI bus> on pcib0 pcib1: <PCI-PCI bridge> irq 91 at device 0.0 on pci0 pci1: <OFW PCI bus> on pcib1 bcm_xhci0: <VL805 USB 3.0 controller (on the Raspberry Pi 4b)> irq 92 at device 0.0 on pci1 bcm_xhci0: 32 bytes context size, 64-bit DMA usbus0 on bcm_xhci0 genet0: <RPi4 Gigabit Ethernet> mem 0x7d580000-0x7d58ffff irq 82,83 on simplebus2 genet0: GENET version 5.0 phy 0x0000 miibus0: <MII bus> on genet0 brgphy0: <BCM54213PE 1000BASE-T media interface> PHY 1 on miibus0 brgphy0: 10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, 1000baseT, 1000baseT-master, 1000baseT-FDX, 1000baseT-FDX-master, auto genet0: Ethernet address: d8:3a:cd:43:11:99 clk_fixed4: clock-fixed has no clock-frequency clk_fixed4: clock-fixed has no clock-frequency gpioled0: <GPIO LEDs> on ofwbus0 lock order reversal: (sleepable after non-sleepable) 1st 0xffff000000dd86c8 LED mtx (LED mtx, sleep mutex) @ /usr/src/sys/dev/led/led.c:295 2nd 0xffffa00001892c10 Raspberry Pi firmware gpio (Raspberry Pi firmware gpio, sx) @ /usr/src/sys/arm/broadcom/bcm2835/raspberrypi_gpio.c:250 lock order LED mtx -> Raspberry Pi firmware gpio attempted at: #0 0xffff000000529c70 at witness_checkorder+0xa78 #1 0xffff0000004bdee0 at _sx_xlock+0x70 #2 0xffff00000092c644 at rpi_fw_gpio_pin_set+0xe4 #3 0xffff0000001dfdf4 at led_create_state+0x15c #4 0xffff0000001a6d1c at gpioled_attach+0x294 #5 0xffff0000004f00ec at device_attach+0x3fc #6 0xffff0000004efc54 at device_probe_and_attach+0x80 #7 0xffff0000004f21c8 at bus_generic_new_pass+0x100 #8 0xffff0000004f2178 at bus_generic_new_pass+0xb0 #9 0xffff0000004f2178 at bus_generic_new_pass+0xb0 #10 0xffff0000004ecaec at bus_set_pass+0x50 #11 0xffff000000434be0 at mi_startup+0x1e0 #12 0xffff0000000008a8 at virtdone+0x68 uma_zalloc_debug: zone "malloc-64" with the following non-sleepable locks held: exclusive sleep mutex LED mtx (LED mtx) r = 0 (0xffff000000dd86c8) locked @ /usr/src/sys/dev/led/led.c:295 stack backtrace: #0 0xffff00000052a0e0 at witness_debugger+0x60 #1 0xffff00000052b374 at witness_warn+0x40c #2 0xffff0000007ef970 at uma_zalloc_debug+0x34 #3 0xffff0000007ef4fc at uma_zalloc_arg+0x30 #4 0xffff0000004855f0 at malloc+0x90 #5 0xffff0000009212c4 at bcm2835_firmware_property+0x48 #6 0xffff00000092c65c at rpi_fw_gpio_pin_set+0xfc #7 0xffff0000001dfdf4 at led_create_state+0x15c #8 0xffff0000001a6d1c at gpioled_attach+0x294 #9 0xffff0000004f00ec at device_attach+0x3fc #10 0xffff0000004efc54 at device_probe_and_attach+0x80 #11 0xffff0000004f21c8 at bus_generic_new_pass+0x100 #12 0xffff0000004f2178 at bus_generic_new_pass+0xb0 #13 0xffff0000004f2178 at bus_generic_new_pass+0xb0 #14 0xffff0000004ecaec at bus_set_pass+0x50 #15 0xffff000000434be0 at mi_startup+0x1e0 #16 0xffff0000000008a8 at virtdone+0x68 armv8crypto0: CPU lacks AES instructions Timecounters tick every 1.000 msec usbus0: 5.0Gbps Super Speed USB v3.0 sdhci_bcm0-slot0: Got command interrupt 0x00030000, but there is no active command. sdhci_bcm0-slot0: ============== REGISTER DUMP ============== sdhci_bcm0-slot0: Sys addr: 0x00000000 | Version: 0x00009902 sdhci_bcm0-slot0: Blk size: 0x00000000 | Blk cnt: 0x00000000 sdhci_bcm0-slot0: Argument: 0x000001aa | Trn mode: 0x00000000 sdhci_bcm0-slot0: Present: 0x000f0000 | Host ctl: 0x00000001 sdhci_bcm0-slot0: Power: 0x0000000f | Blk gap: 0x00000000 sdhci_bcm0-slot0: Wake-up: 0x00000000 | Clock: 0x00003947 sdhci_bcm0-slot0: Timeout: 0x00000000 | Int stat: 0x00000000 sdhci_bcm0-slot0: Int enab: 0x01ff00bb | Sig enab: 0x01ff00bb sdhci_bcm0-slot0: AC12 err: 0x00000000 | Host ctl2:0x00000000 sdhci_bcm0-slot0: Caps: 0x00000000 | Caps2: 0x00000000 sdhci_bcm0-slot0: Max curr: 0x00000001 | ADMA err: 0x00000000 sdhci_bcm0-slot0: ADMA addr:0x00000000 | Slot int: 0x00000000 sdhci_bcm0-slot0: =========================================== ugen0.1: <(0x1106) XHCI root HUB> at usbus0 uhub0 on usbus0 uhub0: <(0x1106) XHCI root HUB, class 9/0, rev 3.00/1.00, addr 1> on usbus0 sdhci_bcm0-slot0: Got command interrupt 0x00030000, but there is no active command. sdhci_bcm0-slot0: ============== REGISTER DUMP ============== sdhci_bcm0-slot0: Sys addr: 0x00000000 | Version: 0x00009902 sdhci_bcm0-slot0: Blk size: 0x00000000 | Blk cnt: 0x00000000 sdhci_bcm0-slot0: Argument: 0x000001aa | Trn mode: 0x00000000 sdhci_bcm0-slot0: Present: 0x000f0000 | Host ctl: 0x00000001 sdhci_bcm0-slot0: Power: 0x0000000f | Blk gap: 0x00000000 sdhci_bcm0-slot0: Wake-up: 0x00000000 | Clock: 0x00003947 sdhci_bcm0-slot0: Timeout: 0x00000000 | Int stat: 0x00000000 sdhci_bcm0-slot0: Int enab: 0x01ff00bb | Sig enab: 0x01ff00bb sdhci_bcm0-slot0: AC12 err: 0x00000000 | Host ctl2:0x00000000 sdhci_bcm0-slot0: Caps: 0x00000000 | Caps2: 0x00000000 sdhci_bcm0-slot0: Max curr: 0x00000001 | ADMA err: 0x00000000 sdhci_bcm0-slot0: ADMA addr:0x00000000 | Slot int: 0x00000000 sdhci_bcm0-slot0: =========================================== sdhci_bcm0-slot0: Got command interrupt 0x00030000, but there is no active command. sdhci_bcm0-slot0: ============== REGISTER DUMP ============== sdhci_bcm0-slot0: Sys addr: 0x00000000 | Version: 0x00009902 sdhci_bcm0-slot0: Blk size: 0x00000000 | Blk cnt: 0x00000000 sdhci_bcm0-slot0: Argument: 0x00000000 | Trn mode: 0x00000000 sdhci_bcm0-slot0: Present: 0x000f0000 | Host ctl: 0x00000001 sdhci_bcm0-slot0: Power: 0x0000000f | Blk gap: 0x00000000 sdhci_bcm0-slot0: Wake-up: 0x00000000 | Clock: 0x00003947 sdhci_bcm0-slot0: Timeout: 0x00000000 | Int stat: 0x00000000 sdhci_bcm0-slot0: Int enab: 0x01ff00bb | Sig enab: 0x01ff00bb sdhci_bcm0-slot0: AC12 err: 0x00000000 | Host ctl2:0x00000000 sdhci_bcm0-slot0: Caps: 0x00000000 | Caps2: 0x00000000 sdhci_bcm0-slot0: Max curr: 0x00000001 | ADMA err: 0x00000000 sdhci_bcm0-slot0: ADMA addr:0x00000000 | Slot int: 0x00000000 sdhci_bcm0-slot0: =========================================== sdhci_bcm0-slot0: Got command interrupt 0x00030000, but there is no active command. sdhci_bcm0-slot0: ============== REGISTER DUMP ============== sdhci_bcm0-slot0: Sys addr: 0x00000000 | Version: 0x00009902 sdhci_bcm0-slot0: Blk size: 0x00000000 | Blk cnt: 0x00000000 sdhci_bcm0-slot0: Argument: 0x00000000 | Trn mode: 0x00000000 sdhci_bcm0-slot0: Present: 0x000f0000 | Host ctl: 0x00000001 sdhci_bcm0-slot0: Power: 0x0000000f | Blk gap: 0x00000000 sdhci_bcm0-slot0: Wake-up: 0x00000000 | Clock: 0x00003947 sdhci_bcm0-slot0: Timeout: 0x00000000 | Int stat: 0x00000000 sdhci_bcm0-slot0: Int enab: 0x01ff00bb | Sig enab: 0x01ff00bb sdhci_bcm0-slot0: AC12 err: 0x00000000 | Host ctl2:0x00000000 sdhci_bcm0-slot0: Caps: 0x00000000 | Caps2: 0x00000000 sdhci_bcm0-slot0: Max curr: 0x00000001 | ADMA err: 0x00000000 sdhci_bcm0-slot0: ADMA addr:0x00000000 | Slot int: 0x00000000 sdhci_bcm0-slot0: =========================================== sdhci_bcm0-slot0: Got command interrupt 0x00030000, but there is no active command. sdhci_bcm0-slot0: ============== REGISTER DUMP ============== sdhci_bcm0-slot0: Sys addr: 0x00000000 | Version: 0x00009902 sdhci_bcm0-slot0: Blk size: 0x00000000 | Blk cnt: 0x00000000 sdhci_bcm0-slot0: Argument: 0x00000000 | Trn mode: 0x00000000 sdhci_bcm0-slot0: Present: 0x000f0000 | Host ctl: 0x00000001 sdhci_bcm0-slot0: Power: 0x0000000f | Blk gap: 0x00000000 sdhci_bcm0-slot0: Wake-up: 0x00000000 | Clock: 0x00003947 sdhci_bcm0-slot0: Timeout: 0x00000000 | Int stat: 0x00000000 sdhci_bcm0-slot0: Int enab: 0x01ff00bb | Sig enab: 0x01ff00bb sdhci_bcm0-slot0: AC12 err: 0x00000000 | Host ctl2:0x00000000 sdhci_bcm0-slot0: Caps: 0x00000000 | Caps2: 0x00000000 sdhci_bcm0-slot0: Max curr: 0x00000001 | ADMA err: 0x00000000 sdhci_bcm0-slot0: ADMA addr:0x00000000 | Slot int: 0x00000000 sdhci_bcm0-slot0: =========================================== sdhci_bcm0-slot0: Got command interrupt 0x00030000, but there is no active command. sdhci_bcm0-slot0: ============== REGISTER DUMP ============== sdhci_bcm0-slot0: Sys addr: 0x00000000 | Version: 0x00009902 sdhci_bcm0-slot0: Blk size: 0x00000000 | Blk cnt: 0x00000000 sdhci_bcm0-slot0: Argument: 0x00000000 | Trn mode: 0x00000000 sdhci_bcm0-slot0: Present: 0x000f0000 | Host ctl: 0x00000001 sdhci_bcm0-slot0: Power: 0x0000000f | Blk gap: 0x00000000 sdhci_bcm0-slot0: Wake-up: 0x00000000 | Clock: 0x00003947 sdhci_bcm0-slot0: Timeout: 0x00000000 | Int stat: 0x00000000 sdhci_bcm0-slot0: Int enab: 0x01ff00bb | Sig enab: 0x01ff00bb sdhci_bcm0-slot0: AC12 err: 0x00000000 | Host ctl2:0x00000000 sdhci_bcm0-slot0: Caps: 0x00000000 | Caps2: 0x00000000 sdhci_bcm0-slot0: Max curr: 0x00000001 | ADMA err: 0x00000000 sdhci_bcm0-slot0: ADMA addr:0x00000000 | Slot int: 0x00000000 sdhci_bcm0-slot0: =========================================== mmc0: No compatible cards found on bus iicbus0: <OFW I2C bus> on iichb0 iic0: <I2C generic I/O> on iicbus0 mmcsd0: 64GB <SDHC SR64G 8.0 SN 2C31A197 MFG 10/2019 by 3 SD> at mmc1 50.0MHz/4bit/65535-block bcm2835_cpufreq0: ARM 600MHz, Core 200MHz, SDRAM 400MHz, Turbo OFF CPU 0: ARM Cortex-A72 r0p3 affinity: 0 Cache Type = <64 byte D-cacheline,64 byte I-cacheline,PIPT ICache,64 byte ERG,64 byte CWG> Trying to mount root from ufs:/dev/ufs/rootfs [rw]... Instruction Set Attributes 0 = <CRC32> Instruction Set Attributes 1 = <> Instruction Set Attributes 2 = <> Processor Features 0 = <AdvSIMD,FP,EL3 32,EL2 32,EL1 32,EL0 32> Processor Features 1 = <> Memory Model Features 0 = <TGran4,TGran64,SNSMem,BigEnd,16bit ASID,16TB PA> Memory Model Features 1 = <8bit VMID> Memory Model Features 2 = <32bit CCIDX,48bit VA> Debug Features 0 = <DoubleLock,2 CTX BKPTs,4 Watchpoints,6 Breakpoints,PMUv3,Debugv8> Debug Features 1 = <> Auxiliary Features 0 = <> Auxiliary Features 1 = <> AArch32 Instruction Set Attributes 5 = <CRC32,SEVL> AArch32 Media and VFP Features 0 = <FPRound,FPSqrt,FPDivide,DP VFPv3+v4,SP VFPv3+v4,AdvSIMD> AArch32 Media and VFP Features 1 = <SIMDFMAC,FPHP DP Conv,SIMDHP SP Conv,SIMDSP,SIMDInt,SIMDLS,FPDNaN,FPFtZ> CPU 1: ARM Cortex-A72 r0p3 affinity: 1 CPU 2: ARM Cortex-A72 r0p3 affinity: 2 CPU 3: ARM Cortex-A72 r0p3 affinity: 3 gic0: using for IPIs Release APs...done TCP_ratelimit: Is now initialized WARNING: WITNESS option enabled, expect reduced performance. uhub0: 5 ports with 4 removable, self powered Warning: no time-of-day clock registered, system time will not be set accurately Dual Console: Serial Primary, Video Secondary ugen0.2: <vendor 0x2109 USB2.0 Hub> at usbus0 uhub1 on uhub0 uhub1: <vendor 0x2109 USB2.0 Hub, class 9/0, rev 2.10/4.21, addr 1> on usbus0 uhub1: 4 ports with 4 removable, self powered ugen0.3: <vendor 0x1ea7 2.4G Keyboard> at usbus0 ukbd0 on uhub1 ukbd0: <vendor 0x1ea7 2.4G Keyboard, class 0/0, rev 1.10/2.00, addr 2> on usbus0 kbd1 at ukbd0 genet0: link state changed to UP lo0: link state changed to UP genet0: link state changed to DOWN genet0: link state changed to UP ums0 on uhub1 ums0: <vendor 0x1ea7 2.4G Keyboard, class 0/0, rev 1.10/2.00, addr 2> on usbus0 ums0: 8 buttons and [XYZT] coordinates ID=2

As you can see I am trying 15.0 to see if I would had more chance, but got the same behavior with 14.0-RELEASE
 
Have you built and installed port sysutils/rpi-firmware?

It contains device tree blob overlay files:
share/rpi-firmware/overlays/mcp2515-can0.dtbo
share/rpi-firmware/overlays/mcp2515-can1.dtbo
share/rpi-firmware/overlays/mcp2515.dtbo
 
Thanks Starcat I can't believe I missed that ! I thought that this would had been included into the RPI build...

I added it and did a

cp -pr /usr/local/share/rpi-firmware/* /boot/msdos/ cp /boot/msdos/config_rpi4.txt /boot/msdos/config.txt

and also added

enable_uart=1 dtoverlay=mcp2515-can0,oscillator=8000000,interrupt=25,spimaxfrequency=1000000

But nothing changed (dmesg, /dev, ifconfig)
 
You're welcome! According to the Waveshare wiki, the following line would also need to be added to config.txt:
Code:
dtparam=spi=on
Hope that helps.
 
Thanks, yes I also tested that, that is my current (non working) config.txt :

cat /boot/efi/config.txt arm_64bit=1 dtoverlay=disable-bt dtoverlay=mmc device_tree_address=0x4000 kernel=u-boot.bin armstub=armstub8-gic.bin hdmi_safe=1 enable_uart=1 dtparam=spi=on dtoverlay=mcp2515-can0,oscillator=12000000,interrupt=25,spimaxfrequency=2000000
 
I have also developed a sudden interest in CAN buses (for big diesel engines). Quick question about debugging your hat problem: Have you tried booting Debian? It might tell you whether the problem is hardware or (FreeBSD-) software.
 
https://stackoverflow.com/questions/65680141/raspberrypi-3b-with-multiple-can-buses-mpc2515
I googled this with these search terms. "freebsd mcp2515-can0" Note, that a DTS file should work with any operating system. So you may be able to copy and paste into your own device tree files (script & binary blob) Wish you good luck, and hope to see a post titled "SOLVED mcp2515-can0" .

RV5 https://forum.rvspace.org/t/can-bus-not-exposed/2517/13 post with ideas, pictures, Yes not Raspberry Pi FreeBSD, but might learn from this post.

https://forum.khadas.com/t/can-bus-mcp2515-on-vim4/20817/13 VIM4 board interfacing to a mcp2515 can bus controller

https://download.freebsd.org/releases/ISO-IMAGES/14.0/

Yes, looking for your FreeBSD 14.0 support information to CAN bus on a raspberry pi 4B. I have used an expensive tool to read data from a Cummins NT Diesel engine in an older Freightliner Semi Truck. Looking for future conversations, cell phone pictures, schematics diagrams, & configuration files that are tested to work. We all benefit, from your sharing information here. Fred
https://www.can-cia.org/can-knowledge/ Here is introductory CAN BUS webpage from CAN In Automation group ( CIA ).
The CAN knowledge webpages describe several CAN physical layer options. Additionally, these webpages also contain technical descriptions about CANopen CC and CANopen FD as well as other standardized CAN-based higher-layers.

Hope others share USEFUL Controller Area Network CAN information Fred
 
I have also developed a sudden interest in CAN buses (for big diesel engines). Quick question about debugging your hat problem: Have you tried booting Debian? It might tell you whether the problem is hardware or (FreeBSD-) software.
I tried Alpine Linux and was able to see the CAN as a serial device and was able to interact with it
 
Back
Top