From aaa42fdc6777832e982d7a61aebeea55ebb49275 Mon Sep 17 00:00:00 2001 From: Jean THOMAS Date: Thu, 30 Jul 2020 16:59:41 +0200 Subject: [PATCH] Remove write logging and change loop conditions --- examples/firmware/main.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/examples/firmware/main.c b/examples/firmware/main.c index 0f8e0d5..6344848 100644 --- a/examples/firmware/main.c +++ b/examples/firmware/main.c @@ -65,6 +65,7 @@ void isr(void) { } int main(void) { + const int kNumIterations = 65536; uart_writestr("Firmware launched...\n"); uart_writestr("DRAM init... "); @@ -81,14 +82,11 @@ int main(void) { uart_writestr("DRAM test... \n"); volatile uint32_t *ram = 0x10000000; - for (size_t i = 0; i < 1000; i++) { - uart_writestr("Writing to 0x"); - uart_writeuint32(&ram[i]); - uart_write('\n'); + for (size_t i = 0; i < kNumIterations; i++) { ram[i] = 0xDEAF0000 | i*4; } - for (size_t i = 0; i < 1000; i++) { + for (size_t i = 0; i < kNumIterations; i++) { if (ram[i] != (0xDEAF0000 | i*4)) { uart_writestr("fail : *(0x"); uart_writeuint32(&ram[i]); -- 2.30.2