From 1c50a03cfd17090f39004849c79e1e6ce8874e05 Mon Sep 17 00:00:00 2001 From: barthess Date: Sat, 25 Oct 2014 15:54:24 +0300 Subject: FSMC. SDRAM. Added safety mask for SDRTR register --- os/hal/ports/STM32/LLD/FSMCv1/fsmc_sdram.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'os') diff --git a/os/hal/ports/STM32/LLD/FSMCv1/fsmc_sdram.c b/os/hal/ports/STM32/LLD/FSMCv1/fsmc_sdram.c index 25da179..e635323 100644 --- a/os/hal/ports/STM32/LLD/FSMCv1/fsmc_sdram.c +++ b/os/hal/ports/STM32/LLD/FSMCv1/fsmc_sdram.c @@ -125,7 +125,7 @@ static void _sdram_init_sequence(const SDRAMConfig *cfgp) { /* Step 8: Set clock.*/ _sdram_wait_ready(); - SDRAMD.sdram->SDRTR = cfgp->sdrtr; + SDRAMD.sdram->SDRTR = cfgp->sdrtr & FMC_SDRTR_COUNT; _sdram_wait_ready(); } -- cgit v1.2.3