Skip to content
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

WIP: update to e-h 1.0.0-alpha.6 #8

Merged
merged 2 commits into from
Dec 9, 2021
Merged

WIP: update to e-h 1.0.0-alpha.6 #8

merged 2 commits into from
Dec 9, 2021

Conversation

ryankurte
Copy link
Owner

@ryankurte ryankurte commented Dec 8, 2021

changes to SPI (rust-embedded/embedded-hal#287) mean forward compat for spi::Transfer and spi::Exec is no longer possible :-/

if we want to continue providing compatibility the easiest is probably to backport a transfer_split(write: &[u8], read: &[u8]) to 0.2.x.

cc. @eldruin @Dirbaio

[edit] solved below, thanks folks!

changes to SPI mean we can no longer run compat either way, would need to revert in 1.0.0-alpha.6 or backport changes to 0.2.x
src/forward.rs Outdated Show resolved Hide resolved
src/forward.rs Outdated Show resolved Hide resolved
@Dirbaio
Copy link
Contributor

Dirbaio commented Dec 8, 2021

You can copy from the write buffer to the read buffer, then do a single-buffer Transfer on the read buffer. The only case where this doesn't work is where the read buffer is smaller, which should be very, very rare.

@ryankurte
Copy link
Owner Author

ahh brilliant, not sure how i missed that, thanks!

@ryankurte ryankurte merged commit 4e6ffe8 into main Dec 9, 2021
@ryankurte ryankurte deleted the e-h-1.0.0-alpha.6 branch December 9, 2021 19:17
@ryankurte ryankurte mentioned this pull request Jul 8, 2022
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.

2 participants