TinyArcade and the SD card reader

MagnusRunesson

  • Full Member
  • ***
    • Posts: 23
  • Eagerly awaiting TinyArcade!
    • View Profile
Will it be possible to read from the SD card in a TinyArcade app?

Both into SRAM and Flash Memory would be interesting, but I assume the Flash Memory have a limited number of writes to it?


Ben Rose

  • Administrator
  • Hero Member
  • *****
    • Posts: 357
    • View Profile
Absolutely- that's how it's able to play video/audio. These are in a completely raw format that goes straight from a RAM buffer to the screen/audio hardware- consider it more or less maxed out streaming the data from the SD card at ~430KB/s and to the screen at ~368KB/s.

It's also able to write that data from the RAM to the flash, if necessary. That's how we're doing our menu/game loading system- it's actually flashing new code from the SD card. I believe the flash is guaranteed for 25K writes. So that's fine for 'many times per day', but not fine for 'many times per second'.


MagnusRunesson

  • Full Member
  • ***
    • Posts: 23
  • Eagerly awaiting TinyArcade!
    • View Profile
Cool! And I guess writing to the SD is fine too, for save files like a high score table?

How is new code loaded into memory? Is the executable linked with all addresses PC relative, so it can be loaded anywhere into memory or does it have a reserved address space? I'm just wondering how feasible it would be to split my code up into different parts that is loaded at different times, to save Flash Memory.


 

SMF spam blocked by CleanTalk