Skip to content

Add PAB_CAN board config and device tree (ARK PAB CAN Jetson Carrier)#104

Open
AlexKlimaj wants to merge 7 commits into
mainfrom
claude/jetson-can-pab-device-tree-8h43l3
Open

Add PAB_CAN board config and device tree (ARK PAB CAN Jetson Carrier)#104
AlexKlimaj wants to merge 7 commits into
mainfrom
claude/jetson-can-pab-device-tree-8h43l3

Conversation

@AlexKlimaj

@AlexKlimaj AlexKlimaj commented Jul 12, 2026

Copy link
Copy Markdown
Member

Summary

Adds a new PAB_CAN product target for the ARK PAB CAN Jetson Carrier Rev 1.0, derived from PAB_V3 — matching the schematic change log: "Initial Release Based on ARK PAB Jetson Carrier V3; Remove IO MCU; Swap power input connectors."

Built from a sheet-by-sheet comparison of the PAB CAN Rev 1.0 schematic against PAB V3 Rev 3.0, plus the production BOM.

What's identical to PAB_V3 (fragment carries over unchanged)

  • Jetson blocks 1–3: CSI lanes, DP1, PCIe, SPI0 pins, GPIO nets
  • Cameras: dev-kit i2c-mux dual CSI wiring → same dual IMX219/IMX477/IMX708 overlays, dual IMX219 baked as default
  • Micro HDMI incl. the Q21 HPD inverter → active-low hotplug + HDMI DCB kept
  • USB: usb2-0/1/2 + usb3-0 (USB-C only SS port), USB4715 hub → same padctl/port topology, usb3-1 dropped
  • UARTA (force-PIO) and UARTB (hsuart, serial3) — the UARTs moved to different connectors (see below) but stay on the same module pins
  • M.2 Key E / Key M

What changed

Change Device-tree impact
Ethernet switch: KSZ8795CLX → Microchip LAN96455S (U25) Runs in unmanaged ROM boot (straps: BOOT_MODE=011, MGMT_MODE SPI client). No DSA driver on R36 5.15. Traffic works as a plain L2 switch; SPI management does not respond (MISO stays silent / 0x00). See below.
SWITCH_RSTn on PAC.06 (module pin 211 / GPIO09) Active-low: low = reset, high = run. MB1 BCT holds PAC.06 LOW through early boot; a kernel gpio-hog then drives HIGH so the rising edge latches straps and starts unmanaged ROM boot. Leave the hog high for the life of Linux.
Jetson CAN (module pins 143/145) → on-board TCAN1057A (U3) → Pixhawk Payload Bus connector (J4) None needed: mttcan@c310000 is enabled by the stock BSP tree and can0 pinmux is already in the BCT, so can0 comes up out of the box.
IO MCU removed; UART0 moved from M.2 Key E BT pins → external JST-GH (J19); UART2 moved from PAB_V3's debug connector → UART2/I2C0 JST-GH (J20) None: same module pins, same UARTA/UARTB nodes.
Power input connectors swapped None (FMU-side).

Ethernet switch: unmanaged mode (no DSA)

Hardware is strapped for:

  • ROM boot / unmanaged (BOOT_MODE) — internal ROM configures a basic L2 switch after nRESET deassert
  • SPI client (MGMT_MODE) — management pins exist on Jetson SPI1 / spi@3210000 CS0, but this path is not usable today

Implications:

  1. Data plane works without software config. RJ45 ports forward Ethernet once SWITCH_RSTn is released (rising edge after rails are up). No kernel DSA, no VLAN/register programming required for basic connectivity.
  2. SPI management does not work with this strap configuration. Probing spi@0 / CS0 yields no response (MISO idle / all zeros). There is no in-tree LAN9645x DSA driver on JetPack R36 (5.15); even with spidev/raw SPI, the switch does not answer management traffic in this unmanaged ROM-boot setup. The DT node (compatible = "microchip,lan96455s") documents the wiring and reserves CS0 so stock tegra-spidev is not double-registered — it does not imply a working SPI control path.
  3. No SPI EEPROM / managed VLANs on this schematic. Advanced features that need register access or EEPROM-loaded config are out of scope for this board revision as wired.
  4. Reset sequencing matters. Holding nRESET high from power-on never produces the strap-latch rising edge, so the switch stays dark. Fix is BCT gpio-output-low on PAC.06 + kernel hog output-high.

Dropped the now-useless CONFIG_MICREL_KS8995MA defconfig fragment (KSZ8795).

Registration

PAB_CAN added to build.sh (incl. all), flash.sh, setup.sh, provision.sh, packaging scripts (tag prefix pab-can-, matched before pab-* in CI), .github/workflows/build.yml, scripts/device_tree/classify.sh, and docs (README, cameras, gpio, i2c, device-tree, packaging).

Validation (bench)

  • Full ./build.sh PAB_CAN + flash on hardware.
  • SWITCH_RSTn rising edge: switch LEDs come up after boot with BCT low + hog high.
  • ARKV6S behind the switch: ping + MAVLink UDP (14550) + NSH telnet over Ethernet (Jetson 192.168.0.1/24, vehicle 192.168.0.4).
  • SPI management path confirmed non-functional in unmanaged mode (no usable response on CS0).

Known limitations

  • Switch is unmanaged only — no software port control, no VLANs, no DSA netdevs.
  • SPI signals do not work for switch management with the current straps/ROM boot path; do not rely on spi@0 for configuration.
  • Future managed mode would require strap/hardware changes (and a kernel DSA driver), not just DT tweaks.

claude and others added 2 commits July 12, 2026 21:37
…etson Carrier

New product target for the PAB CAN carrier (Rev 1.0), derived from PAB_V3 per
its schematic change log ("Initial Release Based on ARK PAB Jetson Carrier V3;
Remove IO MCU; Swap power input connectors").

Schematic comparison against PAB V3 Rev 3.0 (sheet by sheet):
- Jetson blocks 1-3, cameras (dev-kit i2c-mux dual CSI), micro HDMI (active-low
  HPD via Q21 inverter), USB (usb2-0/1/2 + usb3-0 USB-C, USB4715 hub), M.2 Key E
  and Key M, and UARTA/UARTB wiring are identical, so the fragment carries over.
- The KSZ8795 ethernet switch is replaced by a Microchip LAN9646 on the same
  management bus (module SPI0 -> spi@3210000 CS0, spi1_pz3-6 pins) with the same
  reset GPIO (SWITCH_RSTn, module pin 211 -> PAC.06). The fragment swaps the
  node to compatible "microchip,lan9646"; the R36 5.15 kernel has no LAN9646
  driver (DSA support landed upstream in 6.13) and the switch runs
  strap-configured, so the node documents the wiring and reserves CS0. The
  KS8995 defconfig fragment is dropped since it only served the KSZ8795.
- Jetson CAN (module pins 143/145) now feeds an on-board TCAN1057A transceiver
  to the Pixhawk Payload Bus connector. mttcan@c310000 is already enabled by
  the stock BSP tree and can0/can0_din pinmux is already in the shared BCT, so
  no kernel DT change is needed for can0 to come up.
- UART0 moves from the M.2 Key E Bluetooth pins to an external JST-GH (J19) and
  UART2 from the PAB_V3 debug connector to the UART2/I2C0 JST-GH (J20); both
  stay on the same module pins, so the existing uarta/uartb setup is unchanged.
- The PAB_V3 SW_PMEn input (module pin 216) is unconnected on this carrier; its
  BCT config (rsvd0, pulled up, input) is safe as-is, so the BCT files are
  byte-identical to PAB_V3.

Register the PAB_CAN target in build/flash/setup/provision, packaging (tag
prefix pab-can-), the CI tag matrix (matched before pab-*), device-tree
tooling, and docs.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013wvSbvPTrgdKjnPzVuh7Tv

@dakejahl dakejahl left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

mttcan@c310000 is enabled by the stock BSP tree and can0_dout_paa0/can0_din_paa1 pinmux is already in the BCT so can0 comes up out of the box.

so jetson-can service is not needed it sounds like

Comment thread docs/cameras.md Outdated
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants