APJ ABDUL KALAM TECHNOLOGICAL UNIVERSITY Previous Years Question Paper & Answer

Course : B.Tech

Semester : SEMESTER 6

Subject : Embedded System

Year : 2018

Term : MARCH

Scheme : 2015 Full Time

Course Code : EC 308

Page:74





PDF Text (Beta):

Multiple inheritance (deriving a class from many parents).

Exceptional handling.

Virtual base classes. ۱

. Classes for IO streams. [Two library functions are cin (for character(s) in) and cour (for च

out).] The 1/0 stream class library provides for the input and output streams of characters -
1]

supports pipes, sockets and file management features.
5.6.3 Optimization of Codes in Embedded C++ Programs to Eliminate ‏ين‎

Disadvantages

Embedded system codes can be optimized when using an OOP language by the following
1. Declare private as many classes as possible. It helps in optimizing the generated codes.
2. Use char, int and boolean (scalar data types) in place of the objects (reference data types) as बाघ `
and use local variables as much as feasible. |
3. Recover memory already used once by changing the reference to an object 1

A special compiler for an embedded system can facilitate the disabling of specific features Provided ig
C++. Embedded C++ is a version of C++ that provides for ೩ selective disabling of the aforementioned featur,
so that there is a less run-time overhead and less run-time library. The solutions for the library functions ஐ
available and ported in © directly. The IO stream library functions in an embedded C++ compiler are ‏م وزج‎
entrant. Hence using embedded C++ compilers or the special compilers make the C++ a significantly mop
powerful coding language than C for embedded systems.

GNU C/C++ compilers (called gcc) find extensive use in C++ environment in embedded softwar
development. Embedded C++ is a new programming tool with a compiler that provides a small run-tim
library. It satisfies small run-time RAM needs by selectively de-configuring features like template, multipk
inheritance, virtual base class and so on, when there is a less run-time overhead and when the less run-tim
library-using solutions are available. Selectively removed (de-configured) features could be template, ‏حہ‎
‎time type identification, multiple inheritance, exceptional handling, virtual base classes, 10 streams and
foundation classes. [Examples of foundation classes are GUIs (graphic user interfaces). Exemplary GUIs at
buttons, checkboxes or radios.]

An embedded system C++ compiler (other than gcc) is Diab compiler from Diab Data. It also provides ۰۱
target (embedded system processor) with specific optimization of the codes. The run-time analysis tool ٠
check the expected run-time error and give a profile that is visually interactive. |



Embedded system programmers use C++ due to the OOP features of software reusability, ‏ال ماد‎

polymorphism, function over-riding and overloading along with the portability with the C codes and it

line assembly codes. C++ also provides for overloading of operators. Embedded C++ is a C++ version,

which makes large program development simpler by providing OOP features of using an object, which

binds state and behaviour and which is defined by an instance of a class. We use objects in a way ‘hi
_ munimizes memory needs and run-time overheads in the system.

= de
5.7 EMBEDDED PROGRAMMING IN JAVA
5.7.1 Java Programming Basics

Java programming starts from coding for the classes. A class has members. A field is like a variable 0 ಸ್‌
in C. A method defines the operations on the fields, similar to function in ©. Table 5.3 summarizes the

Similar Question Papers