pub struct Lpuart { /* private fields */ }Expand description
LPUART.
Implementations§
Source§impl Lpuart
impl Lpuart
pub const unsafe fn from_ptr(ptr: *mut ()) -> Self
pub const fn as_ptr(&self) -> *mut ()
Sourcepub const fn verid(self) -> Reg<NVerid, R>
pub const fn verid(self) -> Reg<NVerid, R>
Version ID. Documented reset, not a live capability probe.
Sourcepub const fn param(self) -> Reg<NParam, R>
pub const fn param(self) -> Reg<NParam, R>
Parameter. The transmit and receive FIFOs each contain eight entries; burst address windows are aliases, not FIFO depth.
Sourcepub const fn global(self) -> Reg<Global, RW>
pub const fn global(self) -> Reg<Global, RW>
Global. RST holds all LPUART logic/registers except GLOBAL in reset until software clears it; no minimum delay is required before clearing. This is not a wrapper mode or clock control.
Sourcepub const fn pincfg(self) -> Reg<Pincfg, RW>
pub const fn pincfg(self) -> Reg<Pincfg, RW>
Pin Configuration. Change TRGSEL only with transmitter and receiver disabled. The raw trigger selector does not establish chip routing.
Sourcepub const fn baud(self) -> Reg<NBaud, RW>
pub const fn baud(self) -> Reg<NBaud, RW>
Baud Rate. Change configuration only with transmitter and receiver disabled. OSR encodings 1 and 2 are reserved; OSR 3..6 requires BOTHEDGE.
Sourcepub const fn stat(self) -> Reg<NStat, RW>
pub const fn stat(self) -> Reg<NStat, RW>
Status. MSF/TSF and RDRF/TC/TDRE/RAF are read-only. MA2F/MA1F/PF/FE/NF/OR/IDLE/RXEDGIF/LBKDIF are write-one-to-clear; avoid read-modify-write. Some flags also participate in DATA access clearing sequences. Change MSBF/AME/LBKFE only with both directions disabled, RXINV/RWUID with receiver disabled, and BRK13 with transmitter disabled. On affected masks ERR051629 can prevent TC from asserting after flushing TX FIFO with CTS negated and TXCTSE set; no workaround is implemented here.
Sourcepub const fn ctrl(self) -> Reg<Ctrl, RW>
pub const fn ctrl(self) -> Reg<Ctrl, RW>
Control. Bit6 is reserved in both detailed N manuals, despite N23 XML exposing DOZEEN. Change M/M7/PE/ILT/RSRC/LOOPS configuration only with transmitter and receiver disabled as specified by the field descriptions. R9T8/R8T9 read receive bits but write transmit bits; read-modify-write does not preserve the transmit value. Enabling TE can queue an idle preamble; RE/TE may remain set until the current character finishes after disable.
Sourcepub const fn data(self) -> Reg<NData, RW>
pub const fn data(self) -> Reg<NData, RW>
Data. Reads pop the receive FIFO and participate in automatic status-flag clearing; writes push the transmit FIFO. These are distinct read/write views, not ordinary storage; do not read-modify-write. Receive-only status bits must not be interpreted as transmit commands. FRETSC writes select a special character with T9 and require T8..T0 zero.
Sourcepub const fn match_(self) -> Reg<Match, RW>
pub const fn match_(self) -> Reg<Match, RW>
Match Address. Write MA1/MA2 only while the corresponding BAUD.MAEN1/MAEN2 is disabled.
Sourcepub const fn modir(self) -> Reg<NModir, RW>
pub const fn modir(self) -> Reg<NModir, RW>
MODEM IrDA. Change RTSWATER/RXRTSE with receiver disabled, TXRTSE/TXRTSPOL with transmitter disabled, and TNP/IREN with both disabled. Do not enable RXRTSE and TXRTSE together.
Sourcepub const fn fifo(self) -> Reg<NFifo, RW>
pub const fn fifo(self) -> Reg<NFifo, RW>
FIFO. RXFIFOSIZE/TXFIFOSIZE/RXEMPT/TXEMPT are read-only; RXUF/TXOF are write-one-to-clear; RXFLUSH/TXFLUSH are flush commands. Avoid read-modify-write. The register description requires writes with CTRL.RE/TE zero and FIFO empty; FIFO operations also have specific command/flag semantics.
Sourcepub const fn water(self) -> Reg<NWater, RW>
pub const fn water(self) -> Reg<NWater, RW>
Watermark. TXCOUNT and RXCOUNT are read-only. Write only with CTRL.TE zero.
Sourcepub const fn dataro(self) -> Reg<NDataro, R>
pub const fn dataro(self) -> Reg<NDataro, R>
Data Read-Only. Returns DATA without removing the receive FIFO entry.
Sourcepub const fn msr(self) -> Reg<Msr, RW>
pub const fn msr(self) -> Reg<Msr, RW>
MODEM Status. Delta flags are write-one-to-clear; pin-state bits are read-only. Pad configuration affects observed reset values; the generated default is the documented reset, not sampled pin state. Do not read-modify-write.
Sourcepub const fn reir(self) -> Reg<Reir, RW>
pub const fn reir(self) -> Reg<Reir, RW>
Receiver Extended Idle. Change only with receiver disabled; zero disables extended idle and the minimum enabled interval is one idle character.
Sourcepub const fn teir(self) -> Reg<Teir, RW>
pub const fn teir(self) -> Reg<Teir, RW>
Transmitter Extended Idle. Change only with transmitter disabled; zero disables extended idle and the minimum enabled interval is one idle character.
Sourcepub const fn hdcr(self) -> Reg<Hdcr, RW>
pub const fn hdcr(self) -> Reg<Hdcr, RW>
Half Duplex Control. Raw controls, not a mode or pin-ownership operation.
Sourcepub const fn tocr(self) -> Reg<Tocr, RW>
pub const fn tocr(self) -> Reg<Tocr, RW>
Timeout Control. Counters 0/1 monitor the receiver; 2/3 monitor the transmitter.
Sourcepub const fn tosr(self) -> Reg<Tosr, RW>
pub const fn tosr(self) -> Reg<Tosr, RW>
Timeout Status. TOZ is read-only; each TOF bit is write-one-to-clear and disables its counter when set. Do not read-modify-write.
Sourcepub const fn timeout(self, n: usize) -> Reg<Timeout, RW>
pub const fn timeout(self, n: usize) -> Reg<Timeout, RW>
Timeout N. Write only when the corresponding timeout is disabled or its timeout flag is set. Counters 0/1 monitor receive; 2/3 monitor transmit.
Sourcepub const fn tcbr(self, n: usize) -> Reg<Tcbr, W>
pub const fn tcbr(self, n: usize) -> Reg<Tcbr, W>
Transmit Command Burst aliases of DATA, not independent storage. A 32-bit or low-halfword write pushes one FIFO entry; a low-byte write stages data until the high byte is written. Upper-halfword byte/halfword writes are ignored. The field payload is 16 bits but register access remains 32 bits.
Sourcepub const fn tdbr(self, n: usize) -> Reg<Tdbr, W>
pub const fn tdbr(self, n: usize) -> Reg<Tdbr, W>
Transmit Data Burst aliases of DATA, not independent storage or 256 FIFO entries. A word pushes four bytes DATA0 first, with three wait states; a halfword pushes two bytes with one wait state. Bytes use CTRL R8T9/R9T8 for upper data bits and zero-extend FRETSC. UART/SPI views overlap physically; selection is external to this model.