this post was submitted on 03 Aug 2023
8 points (90.0% liked)
Embedded
452 readers
1 users here now
This sub is dedicated to discussion and questions about embedded systems: "a controller programmed and controlled by a real-time operating system (RTOS) with a dedicated function within a larger mechanical or electrical system, often with real-time computing constraints."
founded 2 years ago
MODERATORS
you are viewing a single comment's thread
view the rest of the comments
view the rest of the comments
Yes, this community is stil alive.
I don't really have an exact answer to your question, as I don't write Rust, and I've never used a Raspberry Pi for electronics, but I have some educated input:
Presumably, the crate just exposes pre-defined config objects that you call in your code.
From what I recall, no, you can't use any of the pins on the Raspberry Pi as generic IO (all this information that you are looking for is in the datasheets of the devices that you are using) -- some pins are dedicated for power, etc.
Generally speaking, yes, if you want to use a generic I/O as an output, then you must configure it as such.