Enum max7301::expander::transactional::Strategy [−][src]
Control how TransactionalIO::write_back
will batch writes to modified pins.
Variants
This strategy will issue writes such that only the ports that have had output values
explicitly set through the OutputPin
impl will be altered.
This is the safest but least efficient write back strategy.
This strategy will relax the write back batching so that it may overwrite any port that had
its state read and cached in the most recent refresh
call.
This means that some port registers may be “stomped” by writing values that match the
values they had when refresh
was called. This is true regardless of whether the port is
configured as an input or output pin, however ports configured as inputs will remain in
input mode and the superfluous write to that port is not observable.
This strategy will further relax the write-back batching so that may potentially overwrite
any port, even if the previous value was not read in a refresh
.
Any ports that were not read in a refresh
will be overwritten with an undefined value.
This strategy makes most efficient use of the bus when most pins are output pins, but is
only usable if you call port_pin
for every port you care about, and either
- Explicitly set every pin whose value you care about before each
write_back
call, or - Call
refresh
first before setting any pins.
Auto Trait Implementations
impl RefUnwindSafe for Strategy
impl Send for Strategy
impl Sync for Strategy
impl Unpin for Strategy
impl UnwindSafe for Strategy
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,