BeeProg2

 
For the proper functioning of this website we recommend to turn on JavaScript.
 

Extracting data from Atmel AVR8/16 .elf project

Before you start:


If you already didn't do that, install the WinAVR software, which can be downloaded from: http://sourceforge.net/projects/winavr/files/WinAVR/
Without this software you won't be able to extract the data from your project file.

Step by step manual


STEP-01

Run command prompt






STEP-02


USE “dir” and “cd” commands to get into folder, where the project is saved

dir – shows list of files in current folder

cd <Folders_name> - will enter the desired folder

cd .. - will step out from the current folder



Please note, fact that our example is located in the directory “avrworkspace” does not mean, that your project has to be located in the same directory “avrworkspace”.

STEP-03


Using the command “avr-readelf -l <project_name.elf>” you can display the program headers and section's header stored in the project file.
In other words project contents, that you can extract



STEP-04


use command “avr-objcopy -O binary -j .text <project_name.elf> flash.bin”
It will create flash.bin file and extract the flash contents into it.



STEP-05


use command “avr-objcopy -O binary -j .eeprom <project_name.elf> eeprom.bin”
Creates eeprom.bin file and extract an eeprom contents into it.



STEP-06


use command “avr-readelf -x .fuse <project_name.elf>”
it will display the fuse bits setting.



STEP-07


use command “avr-readelf -x .lock <project_name.elf>”
it will display the lock bits setting.



STEP-08

Erase the whole buffer.




STEP-09

Load EEPROM data




STEP-10

Load Flash Data.




STEP-11

Set the correct fuse bit settings.




STEP-12

Set the correct Lock settings.





Presov, January 2012
Update: April 2015
Author: Jan Drab, Elnec



Return to Application notes

Products

Misc

exhibitions

okraj

Scandinavian Electronics Event

24th - 26th Apr 2018
Kista Science City, Stockholm Sweden
booth no.: C09:50
exhibitor: InstrumentCenter

All exhibitions »