You are on page 1of 5

CHAPTER-42

LABORATORY TOOLS:
Hardware diagnostic laboratory tools:
1.Volt-Ohm meter: Useful for checking the power supply voltage at source and voltage
levels at chips power input pins,

and port pins initial at start and final voltage levels

after the software run, checking broken connections, improper ground

connections, and

burnout resistances and diodes.

2. LED test: Useful for testing port outputs and when using port conditions 1 or 0 for
debugging a particular set of conditions.

3. Use of Logic Probe : Simplest hardware test device.


Handheld pen like device
with LEDs Glows green for 1and red for 0
Important tool when studying the long port-delay effects (>1s).
Delay program tests the presence of system
clock ticks.

Set of protyping tools from WindRiver:


Scope profile
Mem scope
Stetho scope
Trace scope
Code test memory,

It shows how much time the cpu spends on each function in the task or ISR
It detects the leak due to system call or another ported module.
It tracks the change in any program variable.
It finds the RTOS scheduler behaviour during task switching and note the time for various
It helps in code testing bby dynamic memory allocation analysis, controlled flow view t

Trace and coverage


Vx
works
and

coverage under various real worls situations.


It prepares the stack for sending data on the internet to test high performance switching de

networking stacks
Vx sim

It provides a virtual target for developing and debugging the codes.

4.Uses of Oscilloscope: Screen to display two signal voltages as a function of time


Displays analog as well as
digital signals as a function of time

Noise detection tool


Mal-function detection of a sudden transitions between
'0' and '1' states during a period.
5.Uses of Logic Analyser: A powerful hardware tool for checking multiple lines carrying
address, data and control bits, IO buses, ports, peripherals and clock. Recognizes only discrete
voltage conditions, '1' and '0'. Collects, stores and tracks multiple signals and bus transactions
simultaneously and successively. Reads multiple input lines (24 or 48) and later displays,

using this tool, each transaction on each of these on computer monitor (screen) observed. Also
shows states on the horizontal axis instead of time in its state mode of display. Displays the
logic states of a particular line as a function of 0and 1on another line. Catches intermittent
bugs. Does not help on a program halt due to a bug. Does not show processor register and
memory contents, if the processor uses caches then a bus examination alone may not help.
Cannot modify the memory contents and input parameters and study their effects [simulator
needed as that helps in studying these effects]

Logic Analyzer two modes of functioning:


1.

One mode: to show time on x-axis, and logic states of the clock signal, bus signals

2.

and other signals on y axis.


Second mode: to give address, data bus and other signal states from a trigger point
to examine illegal opcodes, access in protected address space and other states as a
function of a reference state.

6. Use of Bit rate meter: A measuring device that finds numbers of 1s and 0in the
preselected time spans. Measures throughput. It can estimate bits 1s and 0s in a test
message and then use bit rate meter to find whether that matches with the message.

7. In-Circuit Emulator:
Development processes using ICE:
Target debugging: Circuit for emulating target system remains independent of a particular
targeted system and processor.
A circuit for emulating target system remains independent of a particular targeted system and
processor .Emulator or ICE provides great flexibility and ease for developing various
applications on a single system in place of testing that multiple targeted systems.

An Emulator:
1.Emulates MCU inputs from sensors
2.Emulates
interfaces/systems
MCU IOsand socket to connect externally MCU

controlled

outputs

for

the

peripheral

3.Emulates target

An ICE:
1.Means In-Circuit Emulator
2.Interface COM port of a computer
3.Emulates target MCU IOs
4.ICE socket connects MCU externally
5.Uses
computerdeveloped object files and hex files for the MCU
6.Uses debugger at the computer developed files for the MCU
application.

Difference in Emulator and ICE:


1.Emulator uses the circuit consisting of the microcontroller or
processor itself. The emulator emulates the target system with extended memory and with
codes downloading ability during the edit-testdebug cycles.
2. ROM Emulator emulates only a ROM.
3. ICE uses another circuit with a card that
connects to target processor (or circuit) through a socket.

Example: Nohau emulator:

Back support hardware package and ICE Subunits:


1.Interface circuit
2.Socket
3.External Memory
4.Emulator-board display unit
5.Twenty-keys pad
6.Registers
7.Connectors

Monitor:

1. A ROM resident program at the target board or ROM emulator connected to ICE.
2. Monitors the device applications, runs for different
hardware architecture, used for debugging

Target Monitor:
1.Computer (PC) interface commands
2. Command interpreter
3. Application codes
down loaded from PC
4. Data

System Monitor functions:


1.Monitor loads the application codes, also used for corrections in codes and then test the
system.
application codes into the monitor.

2.A command for download can download a new


3.A command for reset

the program restarts the program.


4.Monitor loads the application (in hex-file) from developing system (at host) that can also be
modified later to correct the codes.

5.A part of the monitor runs


on host system.
6. Debug monitor codes are downloaded along with the locator binary image.
7. A write and a read command is used to correct or
examine the codes at the memory addresses of the system

8. Monitor controls

(inserts, removes, modifies) breakpoints as per command from debugger.


9. A breakpoint partitions the program into separate segments.
10.When a program segment runs, then there is pause at
breakpoint, then test the result observed after the run and examined, and then next segment is
run.
11. Breakpoints enable program test running between the different program segments.
12. To have controlled execution of instructions, application
loading and codes correction

13. Monitor controls (as per

command from debugger) the execution of application at full speed, as well as by single
stepping during debug phase.

Target Commands:
1.Download into monitor
2.Define Execution start address
3.Define Single step
execute
4.Define Full speed execute
5.Set breakpoints
6.Reset
breakpoints
7.Send selected codes/ IOs info for computer display

Use of System Monitor Codes for Use of System Monitor Codes for Debugging:
1. Downloaded codes in ICE may run a 'Power On Self Test' (POST) program on
bootstrapping.

2. A ROM may also have a debug monitor.


3. GNU

debugger gdb, -a downloadable freeware -may also provide the debug monitor codes for the
system.

You might also like