Struct esp32c2_hal::pac::spi2::ctrl::W
pub struct W(_);
Expand description
Register CTRL
writer
Implementations§
§impl W
impl W
pub fn dummy_out(&mut self) -> BitWriterRaw<'_, u32, CTRL_SPEC, bool, BitM, 3>
pub fn dummy_out(&mut self) -> BitWriterRaw<'_, u32, CTRL_SPEC, bool, BitM, 3>
Bit 3 - 0: In the dummy phase, the FSPI bus signals are not output. 1: In the dummy phase, the FSPI bus signals are output. Can be configured in CONF state.
pub fn faddr_dual(&mut self) -> BitWriterRaw<'_, u32, CTRL_SPEC, bool, BitM, 5>
pub fn faddr_dual(&mut self) -> BitWriterRaw<'_, u32, CTRL_SPEC, bool, BitM, 5>
Bit 5 - Apply 2 signals during addr phase 1:enable 0: disable. Can be configured in CONF state.
pub fn faddr_quad(&mut self) -> BitWriterRaw<'_, u32, CTRL_SPEC, bool, BitM, 6>
pub fn faddr_quad(&mut self) -> BitWriterRaw<'_, u32, CTRL_SPEC, bool, BitM, 6>
Bit 6 - Apply 4 signals during addr phase 1:enable 0: disable. Can be configured in CONF state.
pub fn fcmd_dual(&mut self) -> BitWriterRaw<'_, u32, CTRL_SPEC, bool, BitM, 8>
pub fn fcmd_dual(&mut self) -> BitWriterRaw<'_, u32, CTRL_SPEC, bool, BitM, 8>
Bit 8 - Apply 2 signals during command phase 1:enable 0: disable. Can be configured in CONF state.
pub fn fcmd_quad(&mut self) -> BitWriterRaw<'_, u32, CTRL_SPEC, bool, BitM, 9>
pub fn fcmd_quad(&mut self) -> BitWriterRaw<'_, u32, CTRL_SPEC, bool, BitM, 9>
Bit 9 - Apply 4 signals during command phase 1:enable 0: disable. Can be configured in CONF state.
pub fn fread_dual(&mut self) -> BitWriterRaw<'_, u32, CTRL_SPEC, bool, BitM, 14>
pub fn fread_dual(&mut self) -> BitWriterRaw<'_, u32, CTRL_SPEC, bool, BitM, 14>
Bit 14 - In the read operations, read-data phase apply 2 signals. 1: enable 0: disable. Can be configured in CONF state.
pub fn fread_quad(&mut self) -> BitWriterRaw<'_, u32, CTRL_SPEC, bool, BitM, 15>
pub fn fread_quad(&mut self) -> BitWriterRaw<'_, u32, CTRL_SPEC, bool, BitM, 15>
Bit 15 - In the read operations read-data phase apply 4 signals. 1: enable 0: disable. Can be configured in CONF state.
pub fn q_pol(&mut self) -> BitWriterRaw<'_, u32, CTRL_SPEC, bool, BitM, 18>
pub fn q_pol(&mut self) -> BitWriterRaw<'_, u32, CTRL_SPEC, bool, BitM, 18>
Bit 18 - The bit is used to set MISO line polarity, 1: high 0, low. Can be configured in CONF state.
pub fn d_pol(&mut self) -> BitWriterRaw<'_, u32, CTRL_SPEC, bool, BitM, 19>
pub fn d_pol(&mut self) -> BitWriterRaw<'_, u32, CTRL_SPEC, bool, BitM, 19>
Bit 19 - The bit is used to set MOSI line polarity, 1: high 0, low. Can be configured in CONF state.
pub fn hold_pol(&mut self) -> BitWriterRaw<'_, u32, CTRL_SPEC, bool, BitM, 20>
pub fn hold_pol(&mut self) -> BitWriterRaw<'_, u32, CTRL_SPEC, bool, BitM, 20>
Bit 20 - SPI_HOLD output value when SPI is idle. 1: output high, 0: output low. Can be configured in CONF state.
pub fn wp_pol(&mut self) -> BitWriterRaw<'_, u32, CTRL_SPEC, bool, BitM, 21>
pub fn wp_pol(&mut self) -> BitWriterRaw<'_, u32, CTRL_SPEC, bool, BitM, 21>
Bit 21 - Write protect signal output when SPI is idle. 1: output high, 0: output low. Can be configured in CONF state.
pub fn rd_bit_order(
&mut self
) -> FieldWriterRaw<'_, u32, CTRL_SPEC, u8, u8, Unsafe, 2, 23>
pub fn rd_bit_order(
&mut self
) -> FieldWriterRaw<'_, u32, CTRL_SPEC, u8, u8, Unsafe, 2, 23>
Bits 23:24 - In read-data (MISO) phase 1: LSB first 0: MSB first. Can be configured in CONF state.
pub fn wr_bit_order(
&mut self
) -> FieldWriterRaw<'_, u32, CTRL_SPEC, u8, u8, Unsafe, 2, 25>
pub fn wr_bit_order(
&mut self
) -> FieldWriterRaw<'_, u32, CTRL_SPEC, u8, u8, Unsafe, 2, 25>
Bits 25:26 - In command address write-data (MOSI) phases 1: LSB firs 0: MSB first. Can be configured in CONF state.
Methods from Deref<Target = W<CTRL_SPEC>>§
pub unsafe fn bits(&mut self, bits: <REG as RegisterSpec>::Ux) -> &mut W<REG>
pub unsafe fn bits(&mut self, bits: <REG as RegisterSpec>::Ux) -> &mut W<REG>
Writes raw bits to the register.
Safety
Read datasheet or reference manual to find what values are allowed to pass.