MSPM0G1X0X_G3X0X TI-Driver Library  2.01.00.03
Data Fields
I2CTargetMSPM0_HWAttrs Struct Reference

I2CTargetMSPM0 Hardware attributes. More...

#include <I2CTargetMSPM0.h>

Data Fields

I2CTARGET_BASE_HWATTRS uint8_t sdaPincm
 
uint8_t sdaPinIndex
 
uint32_t sdaPinMux
 
uint8_t sclPincm
 
uint8_t sclPinIndex
 
uint32_t sclPinMux
 
DL_I2C_CLOCK clockSource
 
DL_I2C_CLOCK_DIVIDE clockDivider
 
DL_I2C_RX_FIFO_LEVEL rxIntFifoThr
 
DL_I2C_TX_FIFO_LEVEL txIntFifoThr
 
bool isClockStretchingEnabled
 
bool isAnalogGlitchFilterEnabled
 
uint16_t i2cClk
 

Detailed Description

I2CTargetMSPM0 Hardware attributes.

The baseAddr and intNum fields define the base address and the interrupt number of the I2C peripheral. These values are passed to driverlib APIs and therefore must be populated by driverlib macro definitions. These macros are found in the header files:

The powerMngrId is the Power driver resource ID for the I2C peripheral. These macros are defined in the device specific Power include file.

intPriority is the I2C peripheral's interrupt priority, This value is passed unmodified to Hwi_create().

sdaPinMux and sclPinMux are values drawn from the GPIO driver. They indicate the function for that specific IO pin that select I2C mode.

sdaPinMux and sclPinMux are values drawn from the GPIO driver. They indicate the function for that specific DIO pin that select I2C mode.

A sample structure is shown below:

const I2CMSPM0_HWAttrs I2CHWAttrs[CONFIG_I2C_COUNT] = {
{
.i2c = I2C_INST,
.intNum = I2C_INST_INT_IRQN,
.intPriority = (~0),
.sdaPin = GPIO_I2C_IOMUX_SDA,
.sdaPinIndex = GPIO_I2C_SDA_PIN,
.sdaPinMux = GPIO_I2C_IOMUX_SDA_FUNC,
.sclPin = GPIO_I2C_IOMUX_SCL,
.sclPinIndex = GPIO_I2C_SCL_PIN,
.sclPinMux = GPIO_I2C_IOMUX_SCL_FUNC,
.clockSource = DL_I2C_CLOCK_BUSCLK,
.clockDivider = DL_I2C_CLOCK_DIVIDE_1,
.txIntFifoThr = DL_I2C_TX_FIFO_LEVEL_BYTES_1,
.rxIntFifoThr = DL_I2C_RX_FIFO_LEVEL_BYTES_1,
.i2cClk = I2C_CLOCK_MHZ,
},
};

Field Documentation

§ sdaPincm

I2CTARGET_BASE_HWATTRS uint8_t I2CTargetMSPM0_HWAttrs::sdaPincm

< I2C base hardware attributes SDA Pincm value

§ sdaPinIndex

uint8_t I2CTargetMSPM0_HWAttrs::sdaPinIndex

SDA pin index

§ sdaPinMux

uint32_t I2CTargetMSPM0_HWAttrs::sdaPinMux

SDA pin function

§ sclPincm

uint8_t I2CTargetMSPM0_HWAttrs::sclPincm

SCL Pincm value

§ sclPinIndex

uint8_t I2CTargetMSPM0_HWAttrs::sclPinIndex

SCL pin index

§ sclPinMux

uint32_t I2CTargetMSPM0_HWAttrs::sclPinMux

SCL pin function

§ clockSource

DL_I2C_CLOCK I2CTargetMSPM0_HWAttrs::clockSource

I2C clock source

§ clockDivider

DL_I2C_CLOCK_DIVIDE I2CTargetMSPM0_HWAttrs::clockDivider

I2C clock divider to get the required bps

§ rxIntFifoThr

DL_I2C_RX_FIFO_LEVEL I2CTargetMSPM0_HWAttrs::rxIntFifoThr

I2C receive FIFO interrupt threshold

§ txIntFifoThr

DL_I2C_TX_FIFO_LEVEL I2CTargetMSPM0_HWAttrs::txIntFifoThr

I2C transmit FIFO interrupt threshold

§ isClockStretchingEnabled

bool I2CTargetMSPM0_HWAttrs::isClockStretchingEnabled

Clock stretching enable/disable flag

§ isAnalogGlitchFilterEnabled

bool I2CTargetMSPM0_HWAttrs::isAnalogGlitchFilterEnabled

Analog Glitch Filter enable/disable flag

§ i2cClk

uint16_t I2CTargetMSPM0_HWAttrs::i2cClk

The clock must be in MHz


The documentation for this struct was generated from the following file:
© Copyright 1995-2024, Texas Instruments Incorporated. All rights reserved.
Trademarks | Privacy policy | Terms of use | Terms of sale