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

Expose SPI sio() setting #1826

Closed
Tracked by #2494
ElDonad opened this issue Jul 17, 2024 · 3 comments · Fixed by #2919
Closed
Tracked by #2494

Expose SPI sio() setting #1826

ElDonad opened this issue Jul 17, 2024 · 3 comments · Fixed by #2919
Labels
1.0 non-breaking Not needed for 1.0 and can be supported without breaking the driver. peripheral:spi SPI peripheral

Comments

@ElDonad
Copy link

ElDonad commented Jul 17, 2024

Hello,
I was trying to setup three wires SPI for my application using an ESP32-S3, and it appears that the esp-hal API doesn't expose this setting. Would it be possible to expose this functionality ? I don't think it would be very hard, there could be a helper function akin to Spi::with_sio() that would resemble something like

fun with_sio(self) -> Self{
    let reg_block = self.register_block();
    reg_block.user().modify(|_,w| unsafe {
        w.sio().set_bit();
    }
    self
}

I'm fairly new to ESP and Rust dev and I don't have the means to thoroughly test this PoC currently, so I hope it's not too far from correct...

@jessebraham jessebraham added the peripheral:spi SPI peripheral label Jul 17, 2024
@bjoernQ
Copy link
Contributor

bjoernQ commented Jul 18, 2024

That would be a useful addition

@ElDonad
Copy link
Author

ElDonad commented Jul 22, 2024

By the way there is not much information about it in the technical manual, but I assume this should only be available for the Half Duplex mode, it wouldn't make sense otherwise. I'll try to get it to work on a ESP32S3 I have, maybe then I can issue a PR...

@tom-borcin tom-borcin added the chip:esp32s3 Issue related to ESP32-S3 chip label Aug 14, 2024
@jessebraham jessebraham removed the chip:esp32s3 Issue related to ESP32-S3 chip label Aug 19, 2024
@tom-borcin tom-borcin added chip:esp32s3 Issue related to ESP32-S3 chip and removed chip:esp32s3 Issue related to ESP32-S3 chip labels Oct 7, 2024
@tom-borcin tom-borcin added the investigation Not needed for 1.0, but don't know if we can support without breaking the driver. label Dec 18, 2024
@bjoernQ bjoernQ mentioned this issue Jan 9, 2025
6 tasks
@MabezDev
Copy link
Member

As per the pending PR, this can be done, and if we wanted it could even be added post 1.0.

@MabezDev MabezDev added 1.0 non-breaking Not needed for 1.0 and can be supported without breaking the driver. and removed 1.0-blocker investigation Not needed for 1.0, but don't know if we can support without breaking the driver. labels Jan 10, 2025
@github-project-automation github-project-automation bot moved this from Todo to Done in esp-rs Jan 17, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
1.0 non-breaking Not needed for 1.0 and can be supported without breaking the driver. peripheral:spi SPI peripheral
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

5 participants