From a95cd423cc1320968a678ab0c01fd7471e133940 Mon Sep 17 00:00:00 2001 From: Florent Kermarrec Date: Fri, 9 Mar 2018 18:53:57 +0100 Subject: [PATCH] libboard/sdram: add gap for write leveling --- artiq/firmware/libboard/sdram.rs | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/artiq/firmware/libboard/sdram.rs b/artiq/firmware/libboard/sdram.rs index 246b51fff..a42e5c668 100644 --- a/artiq/firmware/libboard/sdram.rs +++ b/artiq/firmware/libboard/sdram.rs @@ -132,6 +132,12 @@ mod ddr { if !incr_delay() { break } dq = ptr::read_volatile(dq_addr); } + + // Get a bit further into the 0 zone + #[cfg(kusddrphy)] + for _ in 0..32 { + incr_delay(); + } } while dq == 0 {