cancel
Showing results for 
Search instead for 
Did you mean: 

How to get I2C interface to read MaCID using STM32L476.

RShiv.1
Senior

Hi,

I tried getting the I2C connected by going to STMcube and selecting I2C..then generating code which is attached.

I am stll not able to see any I2C connection happening..I also tried using HAL_I2C_IsDeviceReady...but I am getting ret value as 1 which is not HAL_OK...it is HAL_ERROR.Kindly let me know which are the other HAL driver needs to be initaited so as to get the I2C up and also able to read MACID using I2C.

Thanks and regards

Ravi chandran

1 REPLY 1
RShiv.1
Senior

Also kindly let me know do I need to use HAL_I2C_MSp_INIT for this??...if I am selecting HAL from STM cube I do not get HAL_I2C_Msp_Init. so is this necessary for I2C to work????kindly let me know