2022-03-18 05:42 AM
I am trying to run example code for i2c master and slave, provided in Stm standard peripheral library from https://www.st.com/en/embedded-software/stsw-stm8069.html
But the master keeps crahing at I2C_GenerateSTART API call.
I2C_ITConfig
enableInterrupts
TxBuffer
I2C_GenerateSTART �I2C_DeInit
I2C_ITConfig
enableInterrupts
TxBuffer
I2C_GenerateSTART �I2C_DeInit
I2C_ITConfig
enableInterrupts
TxBuffer
I2C_GenerateSTART �I2C_DeInit
I2C_ITConfig
enableInterrupts
TxBuffer
I2C_GenerateSTART �I2C_DeInit
I2C_ITConfig
enableInterrupts
TxBuffer
I2C_GenerateSTART �I2C_DeInit
I2C_ITConfig
enableInterrupts
TxBuffer
I2C_GenerateSTART
The code I am trying is available at below locations
https://github.com/spsarolkar/stm8s-i2c-slave
https://github.com/spsarolkar/stm8s-i2c-master
Can someone please help me where I am going wrong. I am using SDCC compiler with platformIO. The actual processor is STM8S003F3P6