diff --git a/bootloader/sansa_as3525.c b/bootloader/sansa_as3525.c
index 9248921..709e5d9 100644
--- a/bootloader/sansa_as3525.c
+++ b/bootloader/sansa_as3525.c
@@ -78,6 +78,39 @@ void main(void)
verbose = true;
}

+{
+ verbose = true;
+ lcd_clear_display();
+
+ int *iram_start = (int*)0x81000000;
+ int iram_size = 0x50000 / sizeof(int); /* test with bigger sizes */
+
+ int *iram, *iram_end;
+
+ /* write all memory */
+ iram = iram_start;
+ iram_end = iram + iram_size;
+ do {
+ *iram = (int)iram;
+ } while(++iram != iram_end);
+
+ /* then check all memory */
+ iram = iram_start;
+ iram_end = iram + iram_size;
+ do {
+ if(*iram != (int)iram)
+ {
+ printf("WRONG SIZE");
+ printf("BAD: 0x%8x", (int)iram);
+ while(1) ;
+ }
+ } while(++iram != iram_end);
+
+ printf("CORRECT SIZE");
+ printf("0x%8x", iram_size);
+ while(1) ;
+}
+
ret = storage_init();
if(ret < 0)
error(EATA,ret);