Thanks for all the info. I’m still planning on doing this, I’ve been getting into native code (to expose processor features and render graphics, etc.). I bet I can pull it off. Aside from your help (someday I will be one of you) the guy who sits on my left is a Russian mathematician who writes native code for microprocessors (specifically the STM Cortex-M line for a few years). The guy to my right is a seasoned electrical engineer. I’m not I’m trying to be lazy asking for walkthroughs or code, in my mind that’s one of the best things about netmf. I have have been given permission to share our hardware code. Eventually it will have been worth helping me.
Along those lines, what about using RAM over SPI? Seems like it’s been done before. My flash runs at 30-100Mhz (or something like that) but it’s slow writing (reading is decent) and it will eventually die. I can’t responsibly use it for many things I’d like to cache.
I feel a tad sorry for early adopters. The Watchdog feature works fine (even if it isn’t pretty). …But the SPI BusyPin needs work. Before reading data you need to sync up with the BusyPin (so you don’t read in the middle of the first dataset), etc. I’ll get that sorted out soon.
Part of why I love netmf is that it gives me an excuse to learn more native code. I’ll try an add a new CPP file for memory init, but if I run into problems I’ll just use IO_Init for now and let someone else tackle that issue later.
This seems simple enough. I do need to use both internal and external, but I don’t need to load the firmware into RAM so I won’t be modifying the scatter files.
…We’re about to build a new board with external memory so I’ll be getting to this project in the next few weeks. Thanks again so much.
I’m planning on using the IS62WV25616BLL which will give me 512KB (~$5). A few years ago I never would have considered that a significant amount of memory. Now it seems like more than enough.
I’m waiting on my new boards with the SRAM. I will be posting my runtime binary and source once I’ve got it working.
But Synchronous Dynamic Random Access Memory is not Static Random Access Memory. I don’t think it’s supported out of the box. You could do something creative (http://www.myplace.nu/avr/dram/index.htm) but that’s not a good solution since it wastes CPU cycles and is sort of slow.
Now when I run my app I see these lines in the debug output…
Invalid address 20000a50 and range 4 Ram Start 60000000, Ram end 60800000
Invalid address 20000abc and range 4 Ram Start 60000000, Ram end 60800000
Invalid address 200074d0 and range 4 Ram Start 60000000, Ram end 60800000
Of course, so I adjusted the scatterfile and now it doesn’t boot. Which means my init code probably isn’t working properly? I’ll be getting back to this in a day or so, I had to switch to other priorities for now.
Ok, I had to change my addressing from 16bits to 8bits because I didn’t connect my UB and LB pins from the SRAM to my MCU. :\ This also means I only have access to 256KB instead of 512KB. I’ll get that fixed eventually, for now I’m fine with things as they are.
Much thanks to everyone for helping me make this happen!