JacobCrabill opened a new pull request, #6057: URL: https://github.com/apache/incubator-nuttx/pull/6057
## Summary This PR adds a SocketCAN FDCAN driver for STM32H7. Features include standard and extended IDs, classic and FD frames, timeout / tx cancellation, and automatic configuration of nominal- and data-phase bit timing from CONFIG-defined bitrates. A `socketcan` config has been added to the nucleo-h743zi2 board; the Kconfig options should be the same or similar to other SocketCAN drivers. ## Impact A few bug fixes are included for net/can regarding CONFIG's. Note that this was developed independently prior to https://github.com/apache/incubator-nuttx/pull/5419, so the Kconfig settings and overall structure are likely to be similar, but I did not expend a significant amount of effort to match this driver to the (very similar) driver under arch/stm32. ## Testing Initial development and testing was performed using the Nucleo-H743ZI2 board + external transceiver + PEAK USB-FD. Testing was performed using `canutils` - `cansend`, `candump`. More recent testing has been performed by running this driver within PX4 on several STM32H7 boards: Cubepilot Orange Cube, and mRobotics Control Zero H7 OEM, both of which support at least 4Mbps CAN-FD with 2 CAN buses. For the PX4 boards, both the `canutils` applications + UAVCAN v1 have been tested successfully with both classic CAN and CAN-FD. See: https://github.com/PX4/PX4-Autopilot/tree/dev/socketcan-nuttx-10.3.0 for PX4 board support (To test with UAVCANv1, use pyUAVCAN + Yakut on your local PC). This PX4 branch includes effectively the same branch of NuttX as this branch here, with two additional backports needed by PX4. ## Future Work * Hardware-level CAN ID filtering (placeholders exist; not yet implemented) * If desired, we could add Kconfig options to disable extended ID support, like is done in some other drivers * Enable error interrupts; add additional error counters? -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
