2023-02-09 08:07 PM
Hi,
I am using 16Mbit Sram (IS61WV102416DBLL)
The Sram-MCU (STM32L4R9AII6) schematic is as follows
"Chip Select NE1" default pins are used on the MCU side
I added FMC and detailed pin Configuration as "fmc_ram.pdf"
Code :
#define SRAM_BANK_ADDR (uint32_t)0x60000000
#define LEN 100
uint16_t tx[LEN];
uint16_t rx[LEN];
int main(void)
{
HAL_Init();
SystemClock_Config();
MX_GPIO_Init();
MX_FMC_Init();
for(uint16_t i=0;i<LEN;i++){ // fill tx Buffer
tx[i] = i;
}
HAL_SRAM_Write_16b(&hsram1,(uint32_t *)SRAM_BANK_ADDR, tx, LEN);
HAL_SRAM_Read_16b(&hsram1,(uint32_t *)SRAM_BANK_ADDR, rx, LEN);
while (1);
}
why is it increasing by 2 steps ?