Browse Publications Technical Papers 2010-36-0157

Program Overlay Mechanism for Engine Control Module 2010-36-0157

As the complexity and size of algorithms dedicated to EMS continually grows more hardware resources, like processing speed and memory are demanded, increasing the cost of the final product (ECUs in this case). This paper presents a technique aimed at saving flash memory space by pulling pieces of executable binary code out of the microprocessor's flash area and storing them in an external device like an EEPROM. When the application needs to execute that piece of code stored at EEPROM, it will request it to be downloaded into an available RAM memory area and run it from there. For such it is required that some sort of allocation technique be applied once the RAM size is by far much smaller than the EEPROM storage device's size meaning that the whole content of EEPROM cannot be downloaded single shot into RAM. It happens to be necessary a strategy to break the flash application code down in smaller pieces to be stored at EEPROM.
This technique can be summarized in 6 steps:
Software development at the host platform phase: 1. Provide a strategy to decide what part of the current implementation is worth to be moved to EEPROM. 2. Separate that part of code by redesigning and refactoring the current application. 3. Compile and link that code so it can be separately stored at EEPROM.
Software running at the target platform phase: 4. Check if the code has been already downloaded in to RAM. 5. If not, look up the RAM and find a free space to house the code. 6. Download the code from EEPROM to RAM. 7. Execute it in RAM.
This algorithm is an alternative approach to the very well known industry standard memory managers base on the implementations of "Best Fit," "Worst Fit," "Sequential Fit," as well as the combination of them.


Subscribers can view annotate, and download all of SAE's content. Learn More »


Members save up to 40% off list price.
Login to see discount.
Special Offer: With TechSelect, you decide what SAE Technical Papers you need, when you need them, and how much you want to pay.