kernelcrash / msx-rom-and-floppy-emulator

Emulate ROMs and Floppy images in MSX
MIT License
39 stars 7 forks source link

STM32F407ZET6 board compatibility #6

Closed windship closed 1 year ago

windship commented 1 year ago

Hello again, here's my another curiosity question lol

As you told, STM32F407 board has 128KB of ROM size limitation because of physical SRAM capacity. So I wondered if there are another board has more SRAM or expand feature, and I found this. It has extend SRAM points so we can get more SRAM, so it means we can load ROM bigger than 128KB in theory.

And here's my actual try:

IMG_3881 IMG_3882 IMG_3883

I just used the firmware you provided for this big board too, but yeah, it didn't work at all. I connected IO pins to follow previous process(same number & same connection).

Do I have to use another package for compile, not STM32F4-Discovery_FW_V1.1.0? Do I must change IO pin connection? Any help will be appreciated!

kernelcrash commented 1 year ago

Do you have any info about how the SRAM is memory mapped in that board? I have some of the stm32 boards that have SDRAM and they use a completely different type of memory interface such that the memory doesn't quite work like normal memory that you would attach to a CPU (you have to remember that these are microcontrollers rather than pure CPUs). In the stm32f4 this is the FMC (flexible memory controller). I think accessing SRAM still uses this FMC thing. It's an awkward thing to use as it requires initialisation, and often the dedicated pins for a SRAM or SDRAM attached conflict with pins you would like to use for other purposes.

I know for the stm32f429 board with SDRAM I had, accessing the SDRAM was complicated and slower than you would like it to be. The only way that would have been feasible would have been quite complex and have wait states inserted at appropriate points to make it work. Originally I had the idea of using the stm32f429 board with 8MB SDRAM as some kind of cheap Amiga RAM expansion .. but I ended up giving up. It just didn't work.

I'd really like the stm32f7 boards to come down in price. The F7 is quite nice. Some like the stm32f767VIT6 have 512K of ram. There is one board on aliexpress (search for "stm32f767vi development board") that looks interesting, but its still a lot more expensive than the stm32f407 boards. I have not bought one.

And before you ask, I have also tried the stm32h7 boards (like the stm32h750) and the H7 actually has a completely different architecture that makes them worse than the stm32f4 in terms of how I use these boards. The stm32f4 can drive the GPIO pins far faster than a stm32h7.

windship commented 1 year ago

The maker shop said it's "Reversed SRAM extension location". So I think it points somewhere about 'Reversed' area in this memory map: image And they saying the SRAM is 1MB. That's what I know. image

kernelcrash commented 1 year ago

In many way, trying to use the SRAM on that board is like starting a new project. There are a few things that make it a bad choice;

So , it's not like its got an extra 512K or 1MB of RAM at the same speed as the internal 192K. Yes, it's got extra RAM, but it's a lot slower and the interface to the RAM takes up a lot of the pins that you would like to use for other purposes.

windship commented 1 year ago

Whoa, thank you for detailed explanation. I couldn't understand all of your comment, but now I know "It's possible but not simple and clean". You can consider it when you have free time later. Thank you again!