2014-03-17 03:34 AM
Hi,
I'm starting to develop an application where I'll manage EEprom data by I2C. Is there a complete example for stm32F0discovery? Thanks2014-03-17 05:22 AM
It's for the EVAL board, but could be ported.
STM32F0xx_StdPeriph_Lib_V1.1.0\Project\STM32F0xx_StdPeriph_Examples\I2C\I2C_EEPROM2014-03-21 04:09 AM
Thanks Clive1,
I did as you said and it all works, but I have a problem. When I need to do continuousreads o writes, my project doesn't work. My code:if(nciclo == 0){
eeWriteBuffer(Tx1Buffer, 0, BUFFER_SIZE2);
eeWaitEepromStandbyState();
eeWriteBuffer(Tx2Buffer, 32, BUFFER_SIZE2);
eeWaitEepromStandbyState();
nciclo = 1;
}else{
eeRead(Rx1Buffer, 0, (uint16_t *)(&NumDataRead));
eeRead(Rx2Buffer, 32, (uint16_t *)(&NumDataRead));
nciclo = 0;
}
This code is into a task which is called every 100msec. The first time writes page0 and page1,
the second time reads page0 and page1. When I read Rx1Buffer is ok, instead Rx2Buffer is empty. Why? Is there an instruction to wait the next write/read?