Unit - 5 Embedded System Development

Download as pptx, pdf, or txt
Download as pptx, pdf, or txt
You are on page 1of 25

SUBJECT : EMBEDDED SYSTEMS

UNIT – III
EMBEDDED SYSTEM DEVELOPMENT

KRISHNA PRASAD SATAMRAJU


ASSOCIATE PROFESSOR
DEPARTMENT OF CSE (IOT)
ES DEVELOPMENT ENVIRONMENT

• The most important characteristic of E.S is the cross-platform


development technique.
• The primary components in the development environment are the
host system, the target system and many connectivity solutions
between the host and the target E.S.
• The development tools offered by the host system are the cross
complier, linker and source-level debugger.
• The target embedded system offers a dynamic loader, link loader, a
monitor and a debug agent.
• Set of connections are required between the source computer and the
target system.
• These connections can be used for transmitting debugger information
between the host debugger and the target debug agent.
Integrated Development Environment (IDE)

• In E.S IDE stands for an integrated environment for developing


and debugging the target processor specific embedded firmware.

• An IDE is also known as integrated design environment or


integrated debugging environment.

• IDE is a software package which bundles a “Text Editor”, “Cross-


compiler”, ”Linker” and a “Debugger”.

• IDE is a software application that provides facilities to computer


programmers for software development.
• IDEs can either command line based or GUI based.
COMPONENTS OF IDE
IDE consists of:
1. Text Editor or Source code editor
2. A compiler and an interpreter
3. Build automation tools
4. Debugger
5. Simulators
6. Emulators and logic analyzer
• The example of IDE is Turbo C/C++ which provides platform on windows for
development of application programs with command line interface.
• The other category of IDE is known as Visual IDE which provides the
platform for visual development environment , ex- Microsoft Visual C++.
• IDEs used in Embedded firmware are slightly different from the generic IDE
used for high level language based development for desktop applications.
• In Embedded applications the IDE is either supplied by the target
processor/controller manufacturer or by third party vendors or as Open
source.
CROSS COMPILERS
• Cross compilation is the process of converting a source code written
in high level language to a target processor/controller understandable
machine code.
• The conversion of the code is done by software running on a
processor/controller which is different from the target processor.
• The software performing this operation is referred as the Cross-
compiler.
• In other words cross-compilation the process of cross platform
software/firmware development.
• A cross complier is a compiler that runs on one type of processor
architecture but produces object code for a different type of processor
architecture.
NEED/ADVANTAGES OF CROSS COMPILERS
• By using cross compliers we can not only develop complex E.S but reliability
can be improved and maintenance is easy.
• Knowledge of the processor instruction set is not required.
• Register allocation and addressing mode details are managed by the compiler.
• The ability to combine variable selection with specific operations improves
program readability.
• Keywords and operational functions that more nearly resemble the human
thought process can be changed.
• Program development and debugging time will be dramatically reduced when
compared to assembly language programming.
• The library files that are supplied provide may standard routines that may be
incorporated into our application.
• Existing routine can be reused in new programs by utilizing the modular
programming techniques available with C.
• The C language is very portable and very popular.
TYPES OF FILES GENERATED ON CROSS COMPILATION

• The various files generated during cross-compilation process are:

1. List File

2. Hex File (.hex)

3. Pre-processor Output file

4. Map File (File extension linker dependent)

5. Object File (.obj)


DISASSEMBLER
• Disassembler is a utility program which converts machine codes into target
processor specific Assembly instructions. The process of converting
machine codes into Assembly code is known as “Disassembling”.
• The output of the disassembler is often formatted for human-readability
rather than suitability for input to an assembler.
• The interactive disassembler allows the human user to make up mnemonic
symbols for values of code in an interactive session.
• A disassembler may be stand-alone or interactive.
• A stand-alone disassembler when executed generates an assembly language file
which can be examined.
• Interactive shows the effect of any change the user makes immediately.
DECOMPILER

• Decompiler is the utility program for translating machine codes into


corresponding high level language instructions.
• A decompiler converts the executable program code into some form
of higher-level programming language so that it can be read by a
human.
• The decompiler does not reconstruct the original source code and its
output is far less intelligible to a human than original source code
• The are many reasons for decompilation such as understanding a
program, recovering the source code for purposes of achieving or
updating, finding viruses, debugging programs and translating
obsolete code.
SIMULATOR
• Simulator and emulators are two important tools used in embedded
system development.
• Simulator is a software tool used for simulating the various
conditions for checking the functionality of the application
firmware.
• It is a host-based program that simulates the functionality and
instruction set of the target processor.
• The features of Simulator based debugging are :
1. Purely software based
2. Doesn’t require a real target system
3. Very primitive
4. Lack of Real –time behavior.
SIMULATOR
• Simulation is used whenever trying things in the physical world would be
inconvenient, and expensive. It allows experimenter to try things with
more control over parameters and better insight into the results.
• Simulating an embedded computer system can be broken down into five
main parts:
• The computer board itself, the piece of hardware containing one or more processor,
executing the embedded software.
• The software running on the computer board. This includes the user applications , also
the boot ROM or BIOS, hardware drivers, OS and various libraries.
• The communication network or networks that the board is connected to and over which
the software communicates with software on other computers.
• The environment in which the computer operates and that it measures using sensors
and affects using actuators.
• The user interface exposed to a human user of the system.
EMULATORS
• It is a piece of hardware that exactly behaves like the real microcontroller chip with all
its integrated functionality.
• It is the most powerful debugging of all.
• A microcontroller’s functions are emulated in real-time and non-intrusively.
• All emulators contain 3 essential function:
1. The emulator control logic, including emulation memory
2. The actual emulation device
3. A pin adapter that gives the emulator’s target connector the same “package” and pin
out as the microcontroller to be emulated.
• An emulator is a piece of hardware that looks like a processor, has memory like a
processor, and executes instructions like a processor but it is not a processor.
• The advantage is that we can probe points of the circuit that are not accessible inside a
chip.
• It is a combination of hardware and software.
DEBUGGER

• It is a special program used to find errors or bugs in other programs. A


debugger allows a programmer to stop a program at any point and
examine and change the values of the variables.
• A debugger or debugging tool is a computer program that is used to
test and debug other programs. Some of the debuggers offer two
modes of operation like full or partial simulation.
• A crash happens when the program cannot normally continue because
of a programming bug.
• EXAMPLE- The program might have tried to use an instruction not
available on the current version of the CPU to access unavailable or
protected memory.
• When program crashes or reaches a preset condition the debugger
shows the position in the original code if it is a source-level debugger
or symbolic debugger.
TYPES OF FIRMWARE DEBUGGING
• Incremental EEPROM Burning Technique
• This is the most primitive type of firmware debugging technique where the code is
separated into different functional code units. Instead of burning the entire code into the
EEPROM chip at once, the code is burned in incremental order, where the code
corresponding to all functionalities are separately coded, cross-compiled and burned into
the chip one by one.
• Inline Breakpoint Based Firmware Debugging
• Inline breakpoint based debugging ensure that firmware execution is reaching up to a
specified point, insert an inline debug code immediately after the point.
• The debug code is a printf() function which prints a string given as per the firmware. You
can insert debug codes (printf()) commands at each point where you want to ensure the
firmware execution is covering that point.
• Monitor Program Based Firmware Debugging
• Monitor program based firmware debugging is the first adopted invasive method for
firmware debugging.
• In this approach a monitor program which acts as a supervisor is developed. The monitor
program controls the downloading of user code into the code memory, inspects and
modifies register/memory locations; allows single stepping of source code, etc.
TYPES OF FIRMWARE DEBUGGING

Monitor Program Based Firmware Debugging


TYPES OF FIRMWARE DEBUGGING
• In-Circuit Emulator (ICE)
• On Chip Firmware Debugging (OCD)
• Advances in semiconductor technology has brought out new dimensions to target firmware
debugging. Almost all processors/controllers incorporate built in debug modules called On
Chip Debug ( OCD) support.
• Some vendors add ‘on chip software debug support’ through JTAG (Joint Test Action Group)
port. Processors/controllers with OCD support incorporate a dedicated debug module to the
existing architecture. Usually the on-chip debugger provides the means to set simple
breakpoints, query the internal state of the chip and single step through code. The signal lines
of JTAG protocol are explained below.
• Test Data In (TDI): It is used for sending debug commands serially from remote debugger to
the target processor.
• Test Data Out (TDO): Transmit debug response to the remote debugger from target CPU.
• Test Clock (TCK): Synchronizes the serial data transfer.
• Test Mode Select (TMS): Sets the mode of testing.
• Test Reset (TRST): It is an optional signal line used for resetting the target CPU.
• The serial data transfer rate for JTAG debugging is chip dependent. It is usually within the
range of 10 to 1000 MHz.
TARGET HARDWARE DEBUGGING
• Magnifying Glass (Lens)

• Multimeter

• Digital CRO

• Logic Analyzer

• Function Generator
TARGET HARDWARE DEBUGGING –
BOUNDARY SCAN
• As the complexity of the hardware increase, the number of chips
present in the board and the interconnection among them may also
increase.
• The device packages used in the PCB become miniature to reduce the
total board space occupied by them and multiple layers may be
required to route the interconnections among the chips which makes
it very difficult to debug the hardware using magnifying glass,
multimeter, etc. to check the interconnection among the various
chips.
• Boundary scan is a technique used for testing the interconnection
among the various chips, which support JTAG interface, present in
the board.
TARGET HARDWARE DEBUGGING –
BOUNDARY SCAN
HDL BASED VLSI DESIGN PROCESS
ELECTRONIC DESIGN AUTOMATION TOOLS

• Electronic design automation (EDA), also referred to as electronic


computer-aided design (ECAD), is a category of software tools for
designing electronic systems such as integrated circuits and printed
circuit boards.
• The design of a PCBA using ECAD software is a sequential
process, consisting of the following steps:
• Schematic Generation (Capture)
• PCB Layout
• Simulation
• ECAD Integration 
ELECTRONIC DESIGN AUTOMATION TOOLS
• The process of building a PCB was a tedious and time
consuming process in ancient times where the designers
sketch the required connections using pen, pencil and ruler
on papers and the finished sketch was used for etching the
connections on a copper plate and it took weeks and
months time to finish a PCB.

• The more the inter connections involved in the hardware,


the more difficult was the process. The accuracy and
finishing of the PCB was highly dependent on the artistic
skills of the designer.
HARDWARE SOFTWARE CO-DESIGN
HSCD PROCESS
END OF UNIT - V

You might also like