Jump to content

EEPROM Usage on my Midio128 Project


kpete
 Share

Recommended Posts

Hi all,

I am modifying the Midio128 V3 software for an organ project.  This unit will add Midi voices to an existing Rodgers 840 electronic organ.  I want to save my stop information in the EEPROM on the LPC board rather than on the SD card since it might not be available all the time.  I understand how to add it to my build since Midio128 doesn't use it at all.  My question is: Do I have to worry about any reserved addresses that might be used by things like the boot loader?  And has this software been used in other projects and found to work?

 

Pete

Link to comment
Share on other sites

Hi Pete,

 

the bootloader stores the configuration values in a special flash section to avoid any conflict.

Which means, that the EEPROM is free for other purposes.

 

A simple usage example for the EEPROM driver can be found here: http://svnmios.midibox.org/listing.php?repname=svn.mios32&path=%2Ftrunk%2Fapps%2Fmisc%2Fusb_osc_midi_proxy%2F

See presets.*

 

The driver is included from the Makefile, and configured in mios32_config.h:

 

// EEPROM emulation
#define EEPROM_EMULATED_SIZE 128

// magic number in EEPROM - if it doesn't exist at address 0x00..0x03, the EEPROM will be cleared
#define EEPROM_MAGIC_NUMBER 0x47114200

 

Note: it's called "emulation" due to historical reasons. For the MBHP_CORE_LPC17 module the external EEPROM.

 

The magic number should be something different than 0x4711* (which is normally used by my own projects) - it's used to identify the data structure format inside the EEPROM (see presets.c)

 

Best Regards, Thorsten.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

×
×
  • Create New...