Eeprom m24m02-RD with HAL_I2C_Mem_Write and HAL_I2C_Mem_Read issue.
Hi all!
I'm facing a problem to get the eeprom working since whenever i try to write a page (256 bytes) or partial page with HAL_Mem routines the read function seems to read at the beginning wrong informations.
First of all i wish to clarify what eeprom code i've got on my board. In the figure below i'm seeing 24M02RD but the right name should be 24m02DR. Why? is the code correct? What does k737k mean?

As you can see the SCL and SDA lines are pulled up with 10K resistors and the bus is shared among several devices where everyone has its own unique address.
The device is supplied with a 3v3 voltage and uC used is STM32F429ZI. A2 phisycal address is tied to VSS.
Clock speed is 100000 and APB1 is 42MHz APB2 is 84MHz .
Before talking about my problem i want to say that during the tests the device has always answered with ACK and i2c peripheral had never got stuck with busy or hal_error codes. Furthermore the waveforms seems to be perfect with longer time than the eeprom datasheet requirements. (Unfortunately i can't attach the image here)
i'm going to show my test code below:
uint8_t tmp_buf_w[256], tmp_buf_r[256], i;
for(i=0; i < 256; i++) tmp_buf_w[i] = i;
HAL_I2C_Mem_Write(hi2c2, 0xA0, 0x0000, 0x0002, tmp_buf_w, 256, 1000);
HAL_I2C_Mem_Read(hi2c2, 0xA0, 0x0000, 0x0002, tmp_buf_r, 256, 1000);I'm seeing that after that routine the first 31 bytes are corrupted and starting from the 32nd byte the tmp_buf_r is the same of tmp_buf_w.
It shouldn't be related to the 32 bytes page boundary because if i change memory address e.g. 256 or 512 this limit change. i.e. the buffer is corrupted for the first 10 or 15 bytes.
Any suggestions?
