Seminar Topics & Project Ideas On Computer Science Electronics Electrical Mechanical Engineering Civil MBA Medicine Nursing Science Physics Mathematics Chemistry ppt pdf doc presentation downloads and Abstract

Full Version: A Generic MCU Description Methodology with Dependency Evaluation
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Abstract— The widespread use of micro-controllers in the
fields of education and application development have led to the
need for a generic initialization code generator tool to aid
tertiary students as well as developers. With this aim a generic
description methodology for MCUs was developed by the
authors of this paper. The description methodology bundled
with a java based MCU Initialization Code Generator software
was put to test using data from the H8S-2377 MCU. This paper
presents a thorough analysis of the structural aspects of an
MCU, the various features of MCU peripherals and
initialization sequences to evaluate the completeness of the
MCU description methodology. To this effect we identified the
dependency problem whereby the setting for certain registers
in an MCU is a mathematical function of other register
settings. This feature of an MCU register, referred to as a
dependency, is not supported by the current description
methodology. As a result, the user has to manually calculate
the function to initialize the dependent register. In this paper,
we present a solution to the dependency problem by allowing
users to enter the mathematical function in the MCU
description, parsing the function in the Code Generator
software to evaluate the dependency and subsequently
assigning the calculated value to the dependent register in the
initialization sequence.
I. INTRODUCTION
In the recent years there has been a paradigm shift in
embedded systems development with the adoption of modelbased
design techniques. Automatic code generation forms a
vital aspect of model-based design in helping developers
reduce development time and achieve cost effectiveness. A
major consequence of this shift has been the increased focus
on architectural aspects as compared to algorithmic aspects
of embedded systems design [1]. Thus in the recent years
there has been a growing importance in academia to better
equip engineers as result of such change with the necessary
tools and skill sets.
In light of the above research, we developed the MCU
Initialization Code Generator based on a generic MCU
Description Methodology [2]. This tool would benefit
students and engineers new to embedded systems
development in better understanding the MCU structure and
avoiding having to go through lengthy hardware manuals.
The MCU Initialization Code Generator is a GUI based tool
developed using a 3-tier software architecture as follows:
• Tier 1 – Graphic User Interface
• Tier 2 – Code Generation
• Tier 3 – MCU Description
The GUI dynamically reads the MCU description and
presents the user with the available initialization settings in
the form of drop-downs and textboxes. The initialization
code sequence is then generated based on the user’s selection
and the MCU description in tier 3. By providing access to
the MCU description, the tool allows users to contribute to
the definitions of and observe the MCU structure. A similar
architecture is followed by MakeApp, a third-party code
generator and chip configuration software developed by IAR
Systems. However, the description format used by MakeApp
is proprietary and supports only a few families of microcontrollers
[3].
With the wide number of micro-controllers available in
the industry today, a generic description methodology allows
users to create definitions for multiple MCUs therefore
providing a flexible framework. This is of particular
significance to the industry, whereby engineers now need
work with only one code generator tool for different MCUs.
To support such a requirement, the idea is to separate the
code generation software to the specific details of individual
MCUs. Therefore, we use a XML[4] scheme to describe the
individual micro-controller’s functionality and an intelligent
GUI system to interface with this XML scheme to form the
required code generator. The scalability, flexibility offered
and wide use of XML in several projects [5], [6] as a format
for data interchange make it ideal for code generation
applications. Research in XML schema based code
generation in distributed systems shows that users desired to
build a system that takes simple interface definitions as input
to generate the necessary run-time and glue code for
applications to span different technologies [7]. A similar
analogy can be applied to embedded systems code
generation.
In the first half of this paper, an analysis of a typical
MCU structure, constraints and initialization code sequence
is conducted. This is then compared to the various
components of the MCU description methodology. The aim
of this analysis is to check for completeness of the
description methodology. Throughout the paper, our analysis
is performed in the context of the Renesas H8S-2377 MCU
[8]. The H8S-2377 is a 16 bit micro-controller with a wide
range of peripherals such as Timer, Serial Communication,
A/D Converter and so on and hence is representative of most
MCUs. In section III we identify and discuss the dependency
problem in the description methodology proposed in [2].