cancel
Showing results for 
Search instead for 
Did you mean: 

Problem with I2C communication between NUCLEO-F042k6 and CO2 Sensor SCD30

MPote.1
Associate II

I spend whole day traying establish communication between NUCLEO-F)42k6 and CO2 Sensor SCD30 https://www.sensirion.com/fileadmin/user_upload/customers/sensirion/Dokumente/9.5_CO2/Sensirion_CO2_Sensors_SCD30_Interface_Description.pdf

I have connected SDA line from Sensor to D2(PA12) on Nucleo and SCL from Sensor to D8(PF1).

GND from sensor connected to GND on Nucleo and VCC from sensor conected to 3.3 on Nucleo.

I'm using STM32 Workspace and in STM32CubeMX perspective I have configured GPIO pins like described above. Additionally I set No pull up and No pull down for SCL and SDA as it look like its done on sensor board by manufacurer. GPIO Mode Alternate Function Open Drain.

I'm receiving in putty terminal following output:

▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒-Buffer

▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒-Buffer

▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒-Buffer

▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒-Buffer

I will be appriciate for help with getting CO2, Huminidity and Temperature readings from this sensor. This is my beggining with STM32 and after whole day I haven't idea how to proceed with that. My code which require correction is below.

20 REPLIES 20

Hi to everybody.

Has anyone solved? Thanks.