-
Notifications
You must be signed in to change notification settings - Fork 134
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ATSAM CAN driver (MCAN peripheral) #955
Conversation
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as resolved.
bcd8ee2
to
8583c9a
Compare
It does not work yet; I suspect the clock configuration... |
d5442d5
to
464615e
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Very nice and clean, only some minor notes.
The Atmel variant of this CAN IP block has configurable buffers (total size up to 4352 words == 17KB) located in the "userspace" SRAM. (STM32 has only <1KB fixed message RAM and e.g. the Rx FIFOs only fit 3 elements each.) The buffer element sizes are also configurable to not waste memory if 64 byte CAN messages are not used (on STM32 the elements are fixed size for up to 64 bytes CAN data), we can use the Thus I suggest to adapt this driver, get rid of the software-buffers in favor of the large hardware-buffers and significantly less memory copying. |
173523d
to
f43ca14
Compare
f43ca14
to
cfa8ba8
Compare
The pull request is now ready for reviewing and merging :) |
I'll review tomorrow. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Very nice!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Very well written, just minor nitpicks.
Fix deprecated warning about implicitly-declared copy constructor with custom assignment operator.
Co-authored-by: Raphael Lehmann <raphael@rleh.de>
Merge now? 😆 |
I'd like more CAN filters 😅, but apart from that, feel free to merge. |
(just cherry-picked some commits to fix the macOS CI) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks!
message_ram.hpp
implementationconnect<...>()