I2C Module Operation

15.2.8 I2C Interrupts

The I2C module has one interrupt vector for eight interrupt flags listed in Table 15−3. Each interrupt flag has its own interrupt enable bit. When an interrupt is enabled, and the GIE bit is set, the interrupt flag will generate an interrupt request.

Table 15−3.I 2C Interrupts

Interrupt

Interrupt Condition

Flag

 

 

 

ALIFG

Arbitration-lost. Arbitration can be lost when two or more transmitters

 

start a transmission simultaneously, or when the software attempts

 

to initiate an I2C transfer while I2CBB = 1. The ALIFG flag is set when

 

arbitration has been lost. When ALIFG is set the MST and I2CSTP

 

bits are cleared and the I2C controller becomes a slave receiver.

NACKIFG

OAIFG

No-acknowledge interrupt. This flag is set when an acknowledge is expected but is not received in master mode. NACKIFG is used in master mode only.

Own-address interrupt. This flag is set when another master has addressed the I2C module. OAIFG is used in slave mode only.

ARDYIFG

RXRDYIFG

Register-access-ready interrupt. This flag is set as described for the below conditions.

Master transmitter, I2CRM = 0: All data sent

Master transmitter, I2CRM = 1: All data sent and I2CSTP set

Master receiver, I2CRM = 0: I2CNDAT number of bytes received and all data read from I2CDR

Master receiver, I2CRM = 1: Last byte of data received, I2CSTP set, and all data read from I2CDR

Slave transmitter: STOP condition detected

Slave receiver: STOP condition detected and all data read from I2CDR

Receive ready interrupt/status. This flag is set when the I2C module has received new data. RXRDYIFG is automatically cleared when I2CDR is read and the receive buffer is empty. A receiver overrun is indicated if bit I2CRXOVR = 1. RXRDYIFG is used in receive mode only.

TXRDYIFG

GCIFG

Transmit ready interrupt/status. This flag is set when the I2C module is ready for new transmit data (master transmit mode) or when another master is requesting data (slave transmit mode). TXRDYIFG is automatically cleared when I2CDR and the transmit buffer are full. A transmit underflow is indicated if I2CTXUDF = 1. Unused in receive mode.

General call interrupt. This flag is set when the I2C module received the general call address (00h). GCIFG is used in receive mode only.

STTIFG

START condition detected interrupt. This flag is set when the I2C

 

module detects a START condition while in slave mode. This allows

 

the MSP430 to be in a low power mode with the I2C clock source

 

inactive until a master initiates I2C communication. STTIFG is used

 

in slave mode only.

 

 

15-18USART Peripheral Interface, I2C Mode

Page 332
Image 332
Texas Instruments MSP430x1xx manual 15.2.8 I2C Interrupts, 3.I 2C Interrupts, Interrupt Interrupt Condition Flag

MSP430x1xx specifications

The Texas Instruments MSP430x1xx series is a family of ultra-low-power microcontrollers that are highly regarded in the embedded systems community for their versatility and performance. Designed for applications ranging from portable instrumentation to low-power industrial devices, the MSP430x1xx combines flexibility and efficiency with advanced features tailored for energy-sensitive applications.

One of the standout characteristics of the MSP430x1xx is its ultra-low-power operation. This series offers several low-power modes that can significantly extend battery life in portable devices. The microcontroller can be in active mode, low-power mode, or even in a deep sleep state, allowing developers to optimize power consumption based on the application's requirements. In fact, some configurations can operate at just a few microamps, making it ideal for battery-operated devices.

Another key feature is the 16-bit RISC architecture that provides powerful processing capabilities while maintaining a low power profile. The MSP430x1xx series supports a maximum clock speed of 16 MHz, allowing for efficient task execution while consuming minimal energy. This architecture ensures that programs run smoothly while the microcontroller remains energy efficient.

The MSP430x1xx is equipped with various integrated peripherals, including analog-to-digital converters (ADCs), timers, and communication interfaces like UART, SPI, and I2C. The inclusion of a powerful ADC enables the microcontroller to handle sensor readings with high accuracy, making it suitable for applications like environmental monitoring and medical devices. The integrated timers provide essential functionality for real-time applications, allowing for event-driven programming and precise timing control.

Memory options in the MSP430x1xx series are also robust, with configurations offering flash memory sizes from 1 KB to 64 KB. This flexibility allows developers to choose the optimal memory size for their specific applications, accommodating a wide range of requirements.

Additionally, the MSP430x1xx microcontrollers are designed with a wide operating voltage range, typically from 1.8V to 3.6V, making them compatible with various power sources and further enhancing their usability in diverse applications.

In summary, the Texas Instruments MSP430x1xx series of microcontrollers is an excellent choice for developers seeking low-power, high-performance solutions for embedded applications. With an efficient architecture, a rich set of peripherals, and flexible memory options, these microcontrollers are positioned to meet the growing demands of modern electronic designs, particularly in battery-powered and energy-sensitive applications.