2018-12-04 06:55 AM
I have two ST25R3911B-DISCO boards and while recently trying to communicate over I2C - after alot of troubleshooting I discovered that the labels on P203 for SCL and SDA are incorrect and have been switched.
The schematic is correct - I traced the pins through to P203 - it appears only the silkscreen is incorrect.
On the back of the card, I have MB1325 C-01 217410690
The Q/A sticker shows a line on T1, T2, T3, T4 but interestingly, not "QA"
Let me know if I can provide additional information about these boards.
Solved! Go to Solution.
2018-12-13 05:28 AM
Dear Evan,
Yes the label SCL and SDA of P203 are swapped.
We will fix this in the next HW / SW release.
Many Thanks,
BR Travis
2018-12-12 02:00 AM
Also, in the firmware provided by ST - the I2C initialization code is also incorrect.
In the file STSW-ST25R002 - "Sources of STM32L4 based firmware for ST25R3911B-DISCO" -
In the method HAL_I2C_MspInit in stm32l4xx_hal_msp.c we find:
...
GPIO_InitStruct.Pin = GPIO_PIN_7|GPIO_PIN_8;
GPIO_InitStruct.Mode = GPIO_MODE_AF_OD;
GPIO_InitStruct.Pull = GPIO_PULLUP;
GPIO_InitStruct.Speed = GPIO_SPEED_FREQ_VERY_HIGH;
GPIO_InitStruct.Alternate = GPIO_AF4_I2C1;
HAL_GPIO_Init(GPIOB, &GPIO_InitStruct);
This is incorrect - the I2C pins for I2C 1 are PB8 and PB9, not PB7 and PB8.
The result is that, even with the pins corrected - I2C will still not work without this correction in the firmware as well.
GPIO_InitStruct.Pin = GPIO_PIN_8|GPIO_PIN_9;
2018-12-13 05:28 AM
Dear Evan,
Yes the label SCL and SDA of P203 are swapped.
We will fix this in the next HW / SW release.
Many Thanks,
BR Travis