Skip to main content
tkjmail2
Associate III
April 10, 2010
Question

Load hex code from SD card and execute

  • April 10, 2010
  • 5 replies
  • 1161 views
Posted on April 10, 2010 at 23:15

Load hex code from SD card and execute

#sd-efsl-hex
    This topic has been closed for replies.

    5 replies

    tkjmail2
    tkjmail2Author
    Associate III
    May 17, 2011
    Posted on May 17, 2011 at 13:46

    Any examples or code snippets would be preciated!

    Thomas

    picguy2
    Associate III
    May 17, 2011
    Posted on May 17, 2011 at 13:46

    Load raw biunary into RAM.  Or you could decode a hex file for the same result.  Once your code is in RAM simply jump or call it.  You may want to relocate your interrupt vector. 

    Most code executes faster out of flash ROM because there are seperate busses.

    tkjmail2
    tkjmail2Author
    Associate III
    May 17, 2011
    Posted on May 17, 2011 at 13:46

    I have absolutely no idea how to do this :(

    Any help would be appreciated!

    repzak
    Associate II
    May 17, 2011
    Posted on May 17, 2011 at 13:46

    Hello,

    Maybe you could look how the circle_os is made from the Primer2.

    I think they have a array with pointers to all the functions there is embedded in the OS, this list is as i remember placed fixed after the IRQ vectors.

    Then you can call these functions from the ''application'' there is on ram.

    The same way you need to let the OS know which appliaction to run and the pointer to that.. maybe you have several calls in the application, then you could let the first 10 words in the application be pointers to the functions in the applications.

    Kasper
    btan
    Associate II
    May 17, 2011
    Posted on May 17, 2011 at 13:46

    Hello Thoamas,

    I'm trying to read/write HEX data to SD card to be read later on a PC using EFSL.  Had not much luck searching for sample code from ST.  Could you post you sample code?

    Thanks,

    Ben