TWI is a two-wire interface that controls and monitors the device state through registers.

Main Features

  • I2C compatible up to 400 kHz
  • TWI clock supports 100 kHz to 1 MHz

A GPIO pin can be set as an interrupt pin, see GPIO — General purpose input/output.

Interface supply

TWI is supplied by VDDIO. It is recommended to connect VDDIO to a BUCK output, VOUT1, or VOUT2. VDDIO must be present in all operating modes of the chip, except in Ship and Hibernate modes.

Addressing

The 7-bit slave address is 110 1011.

The registers have 16-bit addressing and 8-bit data. The upper address byte is the register instance base address (bank address). The lower byte is the offset within an instance (bank).

Figure 1. TWI write example

TWI write example
Figure 2. TWI read example

TWI read example