Type Alias rp2040_pac::dma::sniff_ctrl::W

source ·
pub type W = W<SNIFF_CTRL_SPEC>;
Expand description

Register SNIFF_CTRL writer

Aliased Type§

struct W { /* private fields */ }

Implementations§

source§

impl W

source

pub fn en(&mut self) -> EN_W<'_, SNIFF_CTRL_SPEC>

Bit 0 - Enable sniffer

source

pub fn dmach(&mut self) -> DMACH_W<'_, SNIFF_CTRL_SPEC>

Bits 1:4 - DMA channel for Sniffer to observe

source

pub fn calc(&mut self) -> CALC_W<'_, SNIFF_CTRL_SPEC>

Bits 5:8

source

pub fn bswap(&mut self) -> BSWAP_W<'_, SNIFF_CTRL_SPEC>

Bit 9 - Locally perform a byte reverse on the sniffed data, before feeding into checksum.

Note that the sniff hardware is downstream of the DMA channel byteswap performed in the read master: if channel CTRL_BSWAP and SNIFF_CTRL_BSWAP are both enabled, their effects cancel from the sniffer’s point of view.

source

pub fn out_rev(&mut self) -> OUT_REV_W<'_, SNIFF_CTRL_SPEC>

Bit 10 - If set, the result appears bit-reversed when read. This does not affect the way the checksum is calculated; the result is transformed on-the-fly between the result register and the bus.

source

pub fn out_inv(&mut self) -> OUT_INV_W<'_, SNIFF_CTRL_SPEC>

Bit 11 - If set, the result appears inverted (bitwise complement) when read. This does not affect the way the checksum is calculated; the result is transformed on-the-fly between the result register and the bus.

source

pub unsafe fn bits(&mut self, bits: u32) -> &mut Self

Writes raw bits to the register.

§Safety

Passing incorrect value can cause undefined behaviour. See reference manual