Struct lpc43xx::i2c0::RegisterBlock [] [src]

#[repr(C)]
pub struct RegisterBlock { pub conset: CONSET, pub stat: STAT, pub dat: DAT, pub adr0: ADR0, pub sclh: SCLH, pub scll: SCLL, pub conclr: CONCLR, pub mmctrl: MMCTRL, pub adr1: ADR, pub adr2: ADR, pub adr3: ADR, pub data_buffer: DATA_BUFFER, pub mask: [MASK; 4], }

Register block

Fields

0x00 - I2C Control Set Register. When a one is written to a bit of this register, the corresponding bit in the I2C control register is set. Writing a zero has no effect on the corresponding bit in the I2C control register.

0x04 - I2C Status Register. During I2C operation, this register provides detailed status codes that allow software to determine the next action needed.

0x08 - I2C Data Register. During master or slave transmit mode, data to be transmitted is written to this register. During master or slave receive mode, data that has been received may be read from this register.

0x0c - I2C Slave Address Register 0. Contains the 7-bit slave address for operation of the I2C interface in slave mode, and is not used in master mode. The least significant bit determines whether a slave responds to the General Call address.

0x10 - SCH Duty Cycle Register High Half Word. Determines the high time of the I2C clock.

0x14 - SCL Duty Cycle Register Low Half Word. Determines the low time of the I2C clock. SCLL and SCLH together determine the clock frequency generated by an I2C master and certain times used in slave mode.

0x18 - I2C Control Clear Register. When a one is written to a bit of this register, the corresponding bit in the I2C control register is cleared. Writing a zero has no effect on the corresponding bit in the I2C control register.

0x1c - Monitor mode control register.

0x20 - I2C Slave Address Register. Contains the 7-bit slave address for operation of the I2C interface in slave mode, and is not used in master mode. The least significant bit determines whether a slave responds to the General Call address.

0x24 - I2C Slave Address Register. Contains the 7-bit slave address for operation of the I2C interface in slave mode, and is not used in master mode. The least significant bit determines whether a slave responds to the General Call address.

0x28 - I2C Slave Address Register. Contains the 7-bit slave address for operation of the I2C interface in slave mode, and is not used in master mode. The least significant bit determines whether a slave responds to the General Call address.

0x2c - Data buffer register. The contents of the 8 MSBs of the DAT shift register will be transferred to the DATA_BUFFER automatically after every nine bits (8 bits of data plus ACK or NACK) has been received on the bus.

0x30 - I2C Slave address mask register

Trait Implementations

Auto Trait Implementations

impl Send for RegisterBlock

impl !Sync for RegisterBlock