Embedded Programming Concepts@ELF

Posted by

Please SUBSCRIBE to YouTube channel Embedkari  for further discussion on Embedded Systems.  I recommend to  use laptop/PC with headphone or at least Tablet for  watching related ELF YouTube video.

If you find something missing, Please provide feedback in comment box so that I can take corrective action.

Key TakeawayMotorola S recordABI(Application Binary Interface) and ELF(Executable Linker Format) concepts with experiments.

You may find Motorola Srecord  or HEX in many 8-bit micro-controllers program. That is helpful from the perspective of EEPROM programming and provides the start address to be loaded in Program Counter. We will quickly go through WiKi information for this.

Application Binary Interface(ABI)

As we know API (Application Program Interface) is the communication mechanism between two software components at HLL. Similarly ABI(Application Binary Interface) is the interface between two binary modules. EABI(Embedded Application Binary Interface) is used in embedded systems. ABI contains information related to Procedure calling convention,Exception handling,Debug,ELF,DWARF etc . You may refer to  ARM ABI AVR ABI  etc for detail.  The UNIX/Linux ABI detail is available at   System V ABI . 

In this blog, I will discuss  ELF(Executable_and_Linkable_Format) first which is one of the most important aspect of Embedded Programming. The  ARM ELF link provides detail for ARM architecture . ARM RealView and KEIL ARM compiler use AXF format.

Can we create a project from ELF file ? 

Yes, Most of the Eclipse based IDE provides feature to import ELF file. If you provide path of source files used to generate it, You may do source level browsing. You may use readelf or objdump  utility to read ELF file.

CASE STUDY 1: ELF from AVR,ARM Executable in Cygwin 


CASE STUDY 2: ELF from Intel,RISCV Executable in Ubuntu


We can fetch important information from ELF file only :

  • Target processor related info from ELF header
  • Program loader uses various sections of ELF
    • Program Memory
      • Text or .text  Program . Read Only
    • Data
    • Heap  :  Free Memory for dynamic allocation
    • Stack


Thanks for reading till end. I am trying to improve usability of my  site. Did you find this discussion helpful ? If so,  Please subscribe to YouTube channel Embedkarias well for additional embedded related stuff.

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.