# RegisterBlock in k210_pac::i2c0 - Rust
Register block
Keywords: rust, rustlang, rust-lang, RegisterBlock

# Struct k210_pac::i2c0::RegisterBlock

source · [−]

    #[repr(C)]pub struct RegisterBlock {Show 38 fields
        pub con: CON,
        pub tar: TAR,
        pub sar: SAR,
        pub data_cmd: DATA_CMD,
        pub ss_scl_hcnt: SS_SCL_HCNT,
        pub ss_scl_lcnt: SS_SCL_LCNT,
        pub intr_stat: INTR_STAT,
        pub intr_mask: INTR_MASK,
        pub raw_intr_stat: RAW_INTR_STAT,
        pub rx_tl: RX_TL,
        pub tx_tl: TX_TL,
        pub clr_intr: CLR_INTR,
        pub clr_rx_under: CLR_RX_UNDER,
        pub clr_rx_over: CLR_RX_OVER,
        pub clr_tx_over: CLR_TX_OVER,
        pub clr_rd_req: CLR_RD_REQ,
        pub clr_tx_abrt: CLR_TX_ABRT,
        pub clr_rx_done: CLR_RX_DONE,
        pub clr_activity: CLR_ACTIVITY,
        pub clr_stop_det: CLR_STOP_DET,
        pub clr_start_det: CLR_START_DET,
        pub clr_gen_call: CLR_GEN_CALL,
        pub enable: ENABLE,
        pub status: STATUS,
        pub txflr: TXFLR,
        pub rxflr: RXFLR,
        pub sda_hold: SDA_HOLD,
        pub tx_abrt_source: TX_ABRT_SOURCE,
        pub dma_cr: DMA_CR,
        pub dma_tdlr: DMA_TDLR,
        pub dma_rdlr: DMA_RDLR,
        pub sda_setup: SDA_SETUP,
        pub general_call: GENERAL_CALL,
        pub enable_status: ENABLE_STATUS,
        pub fs_spklen: FS_SPKLEN,
        pub comp_param_1: COMP_PARAM_1,
        pub comp_version: COMP_VERSION,
        pub comp_type: COMP_TYPE,
        /* private fields */
    }

Expand description

Register block

## Fields

`con: CON`

0x00 - Control Register

`tar: TAR`

0x04 - Target Address Register

`sar: SAR`

0x08 - Slave Address Register

`data_cmd: DATA_CMD`

0x10 - Data Buffer and Command Register

`ss_scl_hcnt: SS_SCL_HCNT`

0x14 - Standard Speed Clock SCL High Count Register

`ss_scl_lcnt: SS_SCL_LCNT`

0x18 - Standard Speed Clock SCL Low Count Register

`intr_stat: INTR_STAT`

0x2c - Interrupt Status Register

`intr_mask: INTR_MASK`

0x30 - Interrupt Mask Register

`raw_intr_stat: RAW_INTR_STAT`

0x34 - Raw Interrupt Status Register

`rx_tl: RX_TL`

0x38 - Receive FIFO Threshold Register

`tx_tl: TX_TL`

0x3c - Transmit FIFO Threshold Register

`clr_intr: CLR_INTR`

0x40 - Clear Combined and Individual Interrupt Register

`clr_rx_under: CLR_RX_UNDER`

0x44 - Clear RX_UNDER Interrupt Register

`clr_rx_over: CLR_RX_OVER`

0x48 - Clear RX_OVER Interrupt Register

`clr_tx_over: CLR_TX_OVER`

0x4c - Clear TX_OVER Interrupt Register

`clr_rd_req: CLR_RD_REQ`

0x50 - Clear RD_REQ Interrupt Register

`clr_tx_abrt: CLR_TX_ABRT`

0x54 - Clear TX_ABRT Interrupt Register

`clr_rx_done: CLR_RX_DONE`

0x58 - Clear RX_DONE Interrupt Register

`clr_activity: CLR_ACTIVITY`

0x5c - Clear ACTIVITY Interrupt Register

`clr_stop_det: CLR_STOP_DET`

0x60 - Clear STOP_DET Interrupt Register

`clr_start_det: CLR_START_DET`

0x64 - Clear START_DET Interrupt Register

`clr_gen_call: CLR_GEN_CALL`

0x68 - I2C Clear GEN_CALL Interrupt Register

`enable: ENABLE`

0x6c - Enable Register

`status: STATUS`

0x70 - Status Register

`txflr: TXFLR`

0x74 - Transmit FIFO Level Register

`rxflr: RXFLR`

0x78 - Receive FIFO Level Register

`sda_hold: SDA_HOLD`

0x7c - SDA Hold Time Length Register

`tx_abrt_source: TX_ABRT_SOURCE`

0x80 - Transmit Abort Source Register

`dma_cr: DMA_CR`

0x88 - I2C DMA Control Register

`dma_tdlr: DMA_TDLR`

0x8c - DMA Transmit Data Level Register

`dma_rdlr: DMA_RDLR`

0x90 - DMA Receive Data Level Register

`sda_setup: SDA_SETUP`

0x94 - SDA Setup Register

`general_call: GENERAL_CALL`

0x98 - ACK General Call Register

`enable_status: ENABLE_STATUS`

0x9c - Enable Status Register

`fs_spklen: FS_SPKLEN`

0xa0 - SS, FS or FM+ spike suppression limit

`comp_param_1: COMP_PARAM_1`

0xf4 - Component Parameter Register 1

`comp_version: COMP_VERSION`

0xf8 - Component Version Register

`comp_type: COMP_TYPE`

0xfc - Component Type Register

## Auto Trait Implementations

### impl !RefUnwindSafe for RegisterBlock

### impl Send for RegisterBlock

### impl !Sync for RegisterBlock

### impl Unpin for RegisterBlock

### impl UnwindSafe for RegisterBlock

## Blanket Implementations

source

### impl<T> Any for T where
T: 'static + ?Sized,

source

#### fn type_id(&self) -> TypeId

Gets the `TypeId` of `self`. Read more

source

### impl<T> Borrow<T> for T where
T: ?Sized,

const: unstable · source

#### fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more

source

### impl<T> BorrowMut<T> for T where
T: ?Sized,

const: unstable · source

#### fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more

source

### impl<T> From<T> for T

const: unstable · source

#### fn from(t: T) -> T

Returns the argument unchanged.

source

### impl<T, U> Into<U> for T where
U: From<T>,

const: unstable · source

#### fn into(self) -> U

Calls `U::from(self)`.

That is, this conversion is whatever the implementation of `From<T> for U` chooses to do.

source

### impl<T, U> TryFrom<U> for T where
U: Into<T>,

#### type Error = Infallible

The type returned in the event of a conversion error.

const: unstable · source

#### fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.

source

### impl<T, U> TryInto<U> for T where
U: TryFrom<T>,

#### type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

const: unstable · source

#### fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.