Other Parts Discussed in Thread: SYSCONFIG, CC3200
Dear Support:
I am needing to increase the drive strength of my CC1352P1 that is interfacing to some I2C peripherals where the CC1352 is not pulling down the I2C line to ground with what is currently set with the SDK pin settings for the drive strength.
I thought the way to do this was the following:
PIN_Config I2CPinTable[] =
{
CC1352P1_LAUNCHXL_I2C0_SDA0 | PIN_INPUT_EN | PIN_PULLUP | PIN_OPENDRAIN | PIN_DRVSTR_MAX,
CC1352P1_LAUNCHXL_I2C0_SCL0 | PIN_INPUT_EN | PIN_PULLUP | PIN_OPENDRAIN | PIN_DRVSTR_MAX,
PIN_TERMINATE
};
PIN_State pinState;
PIN_Handle hPin;
hPin = PIN_open( &pinState, I2CPinTable );
I did this in my application after I made the I2C_open call so that it would use these new settings, but it does not work. I also tried following this with the following:
PINCC26XX_setMux( hPin, CC1352P1_LAUNCHXL_I2C0_SDA0, IOC_PORT_MCU_I2C_MSSDA );
PINCC26XX_setMux( hPin, CC1352P1_LAUNCHXL_I2C0_SCL0, IOC_PORT_MCU_I2C_MSSCL );
which didn't help. I also tried this:
PIN_setConfig( hPin, PIN_BM_DRVSTR, PIN_ID( CC1352P1_LAUNCHXL_I2C0_SDA0 ) | PIN_DRVSTR_MAX );
PIN_setConfig( hPin, PIN_BM_DRVSTR, PIN_ID( CC1352P1_LAUNCHXL_I2C0_SCL0 ) | PIN_DRVSTR_MAX );
and it still didn't work. The I2C module was working properly, just not pulling the I2C pins down to ground which is that I need this to do.
So I went into the I2CCC26XX.c file in the SDK and found where the similar kind of operation was done. In this file, there was this:
static int I2CCC26XX_initIO(I2C_Handle handle, void *pinCfg) {
...
i2cPinTable[i++] = i2cPins.pinSDA | PIN_INPUT_EN | PIN_PULLUP | PIN_OPENDRAIN;
i2cPinTable[i++] = i2cPins.pinSCL | PIN_INPUT_EN | PIN_PULLUP | PIN_OPENDRAIN;
i2cPinTable[i++] = PIN_TERMINATE;
which I changed to this:
i2cPinTable[i++] = i2cPins.pinSDA | PIN_INPUT_EN | PIN_PULLUP | PIN_OPENDRAIN | PIN_DRVSTR_MAX;
i2cPinTable[i++] = i2cPins.pinSCL | PIN_INPUT_EN | PIN_PULLUP | PIN_OPENDRAIN | PIN_DRVSTR_MAX;
i2cPinTable[i++] = PIN_TERMINATE;
and pulled this file into my CCS project and built it and it worked - this was able to pull down the I2C lines so my peripheral would respond. So I am confused. Can you tell me what I am missing so that I can do this from my application and not have to modify the SDK source code to the I2C driver to get this to work? Please advise.
Thanks,
Tim