15.Two marks with answers
15.Two marks with answers
DEPARTMENT OF
ELECTRONICS AND COMMUNICATION ENGINEERING
Prepared by
Dr.A.Kingsly Jabakumar
Associate Professor & Head
Department of ECE
III YEAR ELECTRONICS AND COMMUNICATION ENGINEERING EVEN SEMESTER
UNIT II
EMBEDDED SYSTEMS
It is provided by CPU. This mode has privileges that user modes do not have. The ARM
instruction that puts the CPU in supervisor mode is called SWI.
These are attached to the CPU and implement some of the instructions. For example, floating-
point arithmetic was introduced into the Intel architecture by providing separate chips that
implement the floating-point instructions.
The argument of the SWI instruction is a 24-bit immediate value that is passed on to the
supervisor mode that allows the program to request various services.
•Complex algorithms
•Complex user interface
•Data must be ready by deadline
•Multirate data to be handled
•Manufacturing cost and power are critical
It is a family of RISC architectures that have been developed over many years. ARM7 is a Von
Neumann architecture, while ARM9 is Harvard architecture. It is also a load store architecture.
7.What are the instruction set features useful for embedded programming?
•Pipelining
•Superscalar execution
•Caching
They are generally implemented as a variation of interrupt. Handlers are defined for different
types of internal errors that can be generated.
It is a family of RISC architectures that have been developed over many years. ARM7 is a Von
Neumann architecture, while ARM9 is Harvard architecture. It is also load store architecture.
It supports fast interrupt requests too.
11. When is Application Specific System processors (ASSPs) used in an embedded system?
12.What are the various embedded system design model refining/partitioning techniques?
An Embedded system is one that has computer hardware with software embedded in it as one
of its most important component. The three main components of an embedded system are1.Hardware2.
Main application software3.RTOS
III YEAR ELECTRONICS AND COMMUNICATION ENGINEERING EVEN SEMESTER
.
15. Define Embedded systems.
The main three components of an embedded system are hardware main application software
RTOS.
In Von Neumann architecture the computer memory holds both data and instructions whereas
III YEAR ELECTRONICS AND COMMUNICATION ENGINEERING EVEN SEMESTER
Unified Modeling Language is used to conceptualize the various steps of the design processes
diagrams such as creating requirement and specifications, architecting the system, designing code and
designing tests.
When interrupt is encountered by the processor the control is immediately transferred to the
Interrupt Service Routine which contains the handler for the interrupt.
It is provided by CPU. This mode has privileges that user modes do not have. The ARM
instruction that puts the CPU in supervisor mode is called SWI.
These are attached to the CPU and implement some of the instructions. For example, floating-
point arithmetic was introduced into the Intel architecture by providing separate chips that
implement the floating-point instructions.
Process is a program under execution and a processor is the device that executes the program.
When the data to be fetched is present in the cache it is called Cache hit but when the data
required is not present in the cache it is called cache miss and then it has to be fetched from main
memory.
When one instruction is being executed the fetch unit is idle and this time is efficiently
utilized by prefetching the next opcode by the bus. This is called pipelining.
Used to improve CPU performance where the CPU can execute more than one instruction ata time.
III YEAR ELECTRONICS AND COMMUNICATION ENGINEERING EVEN SEMESTER
UNIT III
PROCESSES AND OPERATING SYSTEMS
Control bus carries control signals R/W’, Data Ready, Interrupt signals.
Latches are level sensitive whereas flip flops are edge sensitive, if input ports are constructed
using latches they become transparent to inputs when enabled and in most processors
wewrite‘1’ to the port to enable it which obviates the reason. So latches are a better choice for
input ports.
In Little Endian mode the lowest order byte resides in the lower order bits of the word whereas
in Big Endian mode the lowest order byte resides in the higher order bits of the word.
It is a collection of wires and it defines a protocol by which the CPU, memory and devices
communicate.
Current Program Status Register is set automatically during arithmetic, logical or shifting
operation. Negative Flag, Zero Flag, Carry Flag and Overflow Flag is present.
7. What are the different CPU buses? State the function of each one.
Bus protocol is a set of rules for communication between Processor. Memory and Devices.
Static RAM and Dynamic RAM are the two major categories of RAM.
CISC RISC
It provides a number of addressing modes It provides very few addressing modes
It has micro programmed unit with a control memory It has a hardwired unit without a control
memory
An easy compiler design Complex compiler design
It is required when a device is connected to a bus for which it is not designed for.
Direct Memory Access is used for bulk data transfers. It takes control of data bus and
processor leaves its control of the bus for a while and DMA becomes the bus master and CPU
becomes free to execute some other internal operations.
It is electrically erasable memory and can be reprogrammed inside a typical system and
allows memory to erase as blocks not as a whole.
An in lined procedure does not have a separate procedure body and procedure linkage
rather the body of the procedure is substituted in place of the procedure call.
UNIT II
EMBEDDED SYSTEMS (Assembly, Linking and Loading & Program level performance
analysis)
1.State the principle of basic compilation techniques.
High level language code is parsed and symbol table is generated and is semantically analyzed
and machine independent optimizations are done, instruction level optimizations are performed
and assembly codes are generated.
2.Give the limitations of polling technique.
Polling technique cannot be used for prioritizing the interrupt inputs, therefore high priority
requests might remain pending while Low priority requests are being served.
3.Name any two techniques used to optimize execution time of a program.
Try to use registers efficiently and analyze cache behavior to avoid cache conflicts.
4.What does a linker do?
The linker translates relative addresses into absolute addresses and produces an Executable
Binary File.
5.What is a data flow graph?
It is a model of a program with no conditionals.
6.What is the difference between Timers and Counters?
Timer has its count input connected to an periodic signal whereas Counter has its count input
connected to an aperiodic signal.
7.Define Watch Dog Timer.
It is an I/O device used for internal operation of a system. CPU’s software is designed to reset
the watch dog timer periodically and prevents it from overflowing. If program hangs then this
timer overflows and resets the processor automatically.
8.Define the function of in-circuit Emulator?
It is a specialized hardware tool that can help debug software. It is a special version of
III YEAR ELECTRONICS AND COMMUNICATION ENGINEERING EVEN SEMESTER
microprocessor that allows its internal registers to be read out when stopped.
9. What is a cross compiler?
It is compiler that runs on one type of machine but generates code for another.
10.What are the different types of Programming Model?
Data Flow Graphs, Control / Data Flow Graphs.
11.What are the power optimization strategies used for processes?
•Power up the system when the request is received
•Predictive Shutdown
Predict when the next request will arrive and start the System just in time.
12. Mention the uses of interrupt service routines?
Whenever an interrupt occurs the Interrupt Service Routine is invoked which consists of the
handler for the specific interrupt that occurs.
13.List the three conditions that must be satisfied by the re -entrant functions?
•The functions should not use variables in a non-atomic way
•The function should not call any other functions that are non-re-entrant
•The function should not be non-re-entrant by itself
14. Brief on predictive shut down.
Predictive Shutdown
Predict when the next request will arrive and start the system just in time to optimize power
consumption.
15.Why do you use infinite loop in embedded software?
Embedded software run on real time systems which keep running continuously, just for
instance an ATM machine can be considered which keeps waiting for a user to swipe his card,
which is again an aperiodic process with unlimited inter arrival time. In such cases an infinite
loop is used.
16.What is watchdog timer?
It is an I/O device used for internal operation of a system. CPU’s software is designed to
reset the watch dog timer periodically and prevents it from overflowing. If program hangs then
this timer overflows and resets the processor automatically.
17.Define kernel.
In computing, Kernel is a computer program that manages input/output requests from
III YEAR ELECTRONICS AND COMMUNICATION ENGINEERING EVEN SEMESTER
Software and translates them into a data processing instruction for the central processing unit
and other devices of a computer. It is fundamental part of a modern computer operating system
18.List the difference between General purpose OS and RTOS.
•RTOSs are used in applications where the response must be close to real time as possible, but
Oss focuses on computing throughput.
•Oss use time sharing architecture but RTOSs uses the same with few number of Processes and
also uses Event Driven Design/Architecture.
•Coding practices are much stricter for RTOSs when compared to OS.
19.What is handshaking in bus interface?
Handshaking is a process of exchanging control signals in a systematic way so that data
can be exchanged between two devices.
20.Why do you need at least one timer device in an embedded system?
Timer devices are needed in an embedded system to synchronize the operation of all the
interconnected components.
21.What is meant by Debounce Logic?
When you press a key on your computer, you expect a single contact to be recorded
by your computer. In fact, however, there is an initial contact, a slight bounce or lightening up
of the contact, then another contact as the bounce ends, yet another bounce back, and so forth.
A similar effect takes place when a switch made using a metal contact is opened. The usual
solution is a debouncing device or software that ensures that only one digital signal can be
registered within the space of a given time (usually milliseconds).
III YEAR ELECTRONICS AND COMMUNICATION ENGINEERING EVEN SEMESTER
UNIT III
PROCESSES AND OPERATING SYSTEMS (Task assignment and scheduling, Distributed
Embedded Systems)
These are a specific hardware attached to CPU buses to quickly execute certain functions. They
can provide large performance increases for applications with computational kernels that spend
a great deal of time in a small section of code.
6.Brief on Processes.
Processes are programs under execution. There are two types Light Weight and Heavy Weight
Processes.
7.List the OSI layers from lowest to the highest level of abstraction.
Physical Layer, Data Link Layer, Network Layer, Transport Layer, Session Layer, Presentation
Layer and Application Layer.
III YEAR ELECTRONICS AND COMMUNICATION ENGINEERING EVEN SEMESTER
It is the organization of a distributed embedded system, its basic units are Processing
Elements which can be instruction set processor or non programmable units also.
The scheduler decides which process has to be sent to the CPU next for execution.
The jobs can be scheduled and allocated to processing elements based on their computation
time and all the embedded networks are designed for low cost. One part of the system can be used
to diagnose the other part.
These are a specific hardware attached to CPU buses to quickly execute certain functions. They
can provide large performance increases for applications with computational kernels that spend
a great deal of time in a small section of code.
a.When the devices with which the PEs communicate are physically separated.
b.The system has component subsystems that have their own embedded processors.
c.To meet real time requirements.
The jobs can be scheduled and allocated to processing elements based on their computation
time and all the embedded networks are designed for low cost. One part of the system can be used
to diagnose the other part of the system.
Counting Semaphore : It takes a count value of integer data type and every time it is taken the
count is decremented and when it reaches zero the task is blocked. Binary Semaphore: It can take
only 0/1, when taken it takes value of 1 and when released It takes value of 0.
Priority Inheritance is the solution for Priority Inversion problem where a low priority task
executes whereas a high priority task keeps waiting. When semaphores are taken the task that has
taken the semaphore inherits the priority of the highest priority task that it blocks to avoid
priority inversion.
III YEAR ELECTRONICS AND COMMUNICATION ENGINEERING EVEN SEMESTER
Simple Mail Transfer Protocol (SMTP) is an Internet standard for electronic mail (e-mail)
transmission. First defined by RFC 821 in 1982, it was last updated in 2008 with the Extended
SMTP additions by RFC 5321 - which is the protocol in widespread use today. SMTP by default
uses TCP port 25. The Hypertext Transfer Protocol (HTTP) is an application protocol for
distributed, collaborative, hypermedia information systems. HTTP is the foundation of data
communication for the World Wide Web. Hypertext is structured text that uses logical
links(hyperlinks) between nodes containing text.
A stub is a small program routine that substitutes for a longer program, possibly to be loaded
later or that is located remotely. For example, a program that uses Remote Procedure Calls is
compiled with stubs that substitute for the program that provides a requested procedure. The stub
accepts the request and then forwards it (through another program) to the remote procedure. When
that procedure has completed its service, it returns the results or other status to the stub
which passes it back to the program that made the request.
Round-robin (RR) is one of the algorithms employed by Process Scheduler and Network
Scheduler in Computing. As the term is generally used, time slices are assigned to
each process in equal portions and in circular order, handling processes without priority (also
known as Cyclic Executive). Round-robin scheduling is simple, easy to implement, and Resource
Starvation-free. Round-robin scheduling can also be applied to other scheduling problems, such as
data packet scheduling in computer networks.
III YEAR ELECTRONICS AND COMMUNICATION ENGINEERING EVEN SEMESTER
UNIT III
PROCESSES AND OPERATING SYSTEMS (Interprocess Communication Mechanisms)
•OS defines a job which has predefined sequence of commands, programs and data as a single
unit.
• OS keeps a number a jobs in memory and executes them without any manual information.
2.Define: Multitasking
Multitasking is the process of running multiple tasks simultaneously in different ways. Examples
are Co-routines, Cooperative Multitasking and Preemptive Multitasking
The hardware and software must be designed together to make sure that the implementation not
only functions properly but also meets the goals of performance, cost and reliability.
A set-top box or set-top unit is an information appliance device that generally contains a TV-
tuner input and displays output connects to a television set and an external source of signal, turning the
source signal into content in a form that can then be displayed on the television screen or other
display device.
5.What is PDA?
Short for personal digital assistant, a handheld device that combines computing, telephone/fax,
Internet and networking features. A typical PDA can function as a cellular phone,
fax sender, Web browser and personal organizer. PDAs may also be referred to as a palmtop, hand-
held computer or pocket computer.
a. Screen Display
b. Power Section (including Battery)
c. Built in memory
d. PDA Operating System / Software
Free and open-source software (FOSS) is Computer Software that can be classified
as both Free Software and Open Source Software. That is, anyone is freely licensed to use,copy, study,
and change the software in any way, and the source code is openly shared so that people are
encouraged to voluntarily improve the design of the software. This is in contrast to Proprietary
Software, where the software is under restrictive Copyright and the source code is usually hidden from
the users.
a. Lots of ready to use components for most parts of the system. Lets you focus on the
innovative part of your product, what differentiates it.
b. You do not need to wait for months or years for some features to be implemented by others.
At least, you can implement the critical ones that you need.
c. Constant innovation. Features brought in at a quick pace, sometimes even before you need
them.
d. Possible to port Linux to a new innovative architecture. Easy to port your entire system then.
Signals are one form Inter Process Communication mechanisms where one process carries
message to nearby process. It might be of one bit length and might not hold any information by itself.
In vxworks msqQDelete( ) function is used to eliminate the message queue by freeing the
memory.
11.What are the functions of network layer and data link layer in network enabled systems.
Network Layer defines the basic end to end data transmission service. It is important in multi
hop networks. The purpose of Data link layer is Error Detection and control over a single link.
Co- processor is tightly coupled with the parent processor and performs specific designated
functions. Other I/O Programmable Processor
Keyboard/Pointer
Video decomp
Display
Speech Codec
Wireless Network Interface
III YEAR ELECTRONICS AND COMMUNICATION ENGINEERING EVEN SEMESTER
Multiprocessors are loosely coupled processors that are independent of each other in a distributed
architecture.
Hardware debugging is carried out using Logic Analyzer, In circuit emulator to check the
correctness of the system. Software debugging is implemented using Breakpoints and CPU Simulators.
There is a hardware and software platform between the application layer and
underlying peripherals in PDA but there is no network layer functions in between.
16. What is an Application Specific Instruction Set processor?
To meet highly specialized processing requirements in their SoCs, designers often turn to
application-specific instruction-set processors (ASIPs), which offer more architectural specialization as
well as instruction and data – level parallelism compared to general-purpose processors.
The cost of mistakes are very expensive in System – on – Silicon since fabrication itself takes
a long time and the chances of debugging and monitoring signals is quite impractical therefore first-
time correctness is aimed at.
It is a technique used in 1200-baud modem. This scheme transmits sinusoidal tones with 0and 1
assigned to different frequencies.
By having the modem’s transmitter send bits to its receiver or by connecting two different modems.
It is used for text compression in Data Compressor. It uses the information on the frequency of
characters to assign variable length codes to characters. If shorter bit sequences are used to
identify more frequent characters, then the length of the total sequence will be reduced.
In multirate systems, certain operations must be executed periodically and each operation is
executed at its own rate.
Scheduling is the mechanism by which tasks are dispatched to the processor according to any
policy so that the process completes by its deadline.
A process can be in any of the three scheduling states: waiting, ready, executing.
Two CPUs share a common address location, each of them see that flag indicates ready, and
both of them write to the same location leading to conflict. This problem can be solved by using
semaphores.
Signals are mechanisms used in operating systems for Inter Process Communication. It is
analogous to an interrupt but is entirely a software creation. Eg: Signals is POSIX – SIGALRM,
SIGPIPE, SIGILL, SIGSEGV.
III YEAR ELECTRONICS AND COMMUNICATION ENGINEERING EVEN SEMESTER
The need to structure programs to perform multiple tasks is the motivation behind
introducing the notion of a process. Eg: In Telephone Answering Machine – Recording a phone call
and operating the user control panel are two different tasks but both are run at different rates.
When a task with higher priority (with respect to deadline etc.,) arrives then the lower
Priority task is pre-empted since it has only a later deadline / finishing time.
Ethernet is a widely used local area network for general purpose computing. Internet uses a
fundamental protocol that provides connectionless packet based Communication. Myrinet is a
high performance network that provides a full duplex connection.
UNIT I
8051 MICROCONTROLLER
1. What is microcontroller?
A single IC which contains the microprocessor with integrated peripherals like memory,
serial ports, parallel ports, timer/counter, interrupt controller, data acquisition interfaces like
ADC, DAC is called Microcontroller. CPU ROM RAM Timers I/O Ports Serial Port
Internal blocks of Microcontroller.
2. Compare Microprocessor and Microcontroller
III YEAR ELECTRONICS AND COMMUNICATION ENGINEERING EVEN SEMESTER
The PSW consists of four math flags and two register bank select bits. The math flags are
Carry, Auxiliary Carry, and Overflow and Parity flags. The register bank select bits RS1
and RS0 are used to select any one of the four register banks of the internal RAM. At any
instant, the microcontroller can work with (or access) only one register bank, which is
selected by these bits
III YEAR ELECTRONICS AND COMMUNICATION ENGINEERING EVEN SEMESTER
10. State the function of RS1 and RS0 bits in the flag register of 8051
17. Why all pins of a port is loaded with value “FF” before using it?
All ports of 8051 are configured by default as Output port. Hence, to make it configured as
Input Port, all pins of a port are loaded with value “FF” i.e., 1111 1111.
18. Justify why the crystal oscillator frequency in 8051 is chosen as11.0592Mhz.
When an 8051 microcontroller based system is connected to an external serial
communication device, the speed of the data transfer should be in standard baud rates such as
III YEAR ELECTRONICS AND COMMUNICATION ENGINEERING EVEN SEMESTER
4800, 9600, etc. Only XTAL (Crystal Oscillator) of 11.0592 MHz can provide such standard
baud rates, after down scaling down by 12, 32 at UART and by a factor set in timer register
TH1.
value in the timer register, counting of external event can be performed using timer
UNIT IV
IOT ARCHITECTURE AND PROTOCOLS
1. Define IoT
By embedding short range mobile transceivers into a wide array of additional gadgets and
everyday items, enabling new forms of communication between people and things and between
things
IoT is the network of physical objects i.e devices, vehicles, buildings and other items embedded
with electronics, software, sensors, and network connectivity that enables these objects to
collect and exchange data.
2. How IoT differ from traditional computing
IoT data differs from traditional computing. The data can be small in size and frequent in
transmission. The numbers of devices, or nodes, that are connecting to the network are also
greater in IoT than in traditional PC computing.
3. List the characteristics of the Internet of Things
o Interconnectivity
o Heterogeneity
o Things related services
o Dynamic changes
UNIT V
IOT SYTEM DESIGN
1. List the typical IoT device
Typical IoT devices are CPU,GPU, memory interfaces, USB host, Ethernet, I/O interface like
SPI,UART and CAN ,storage interface like MMC and SD.
2. List various IoT communication protocol
IoT communication models are request/response model, publish/subscribe model,push/pull
model and exclusive pair model
3. What is python?
Python is an object oriented, high level programming language with integrated dynamic
semantics primarily for web and app development
4. List and explain features of python
Python is simple and minimalistic language
Easy to learn
Free and open source
Python supports procedure oriented programming as well as object oriented programming
Extensive libraries: The python standard library is huge indeed
Embeddable: You can embed python within your C/C++ programs to give scripting capabilities
for your programs users
5. List the benefits of python
III YEAR ELECTRONICS AND COMMUNICATION ENGINEERING EVEN SEMESTER
Python allows for a more productive coding environment than massive languages like C # and
java
Python powers Django, a complete and open source web application framework
Most automation, data mining and big data platforms rely on python
Python supports modules and packages which encourages program modularity and code reuse
6. What is Raspberry pi
Raspberry pi is the name of a series of single board computers made by tge Raspberry pi
foundation. The original Pi had a single core 700 MHz CPU and just 256 MB RAM and the
latest model has a quad core 1.4 GHZ CPU with 1 GB RAM
7. What are the different Raspberry pi model types
Model A(Introduced later as a hardware reduced model)
Model B(Introduced first and is the full hardware model)
8. Explain difference between Model A & Model B of RASPBERRY PI
Parameters Model A Model B
GPU type Video core IV Video core IV
USB port 1 2
memory 256 mb 512mb
Ethernet port Mo Ethernet port 10/100 Ethernet
SoC type Broadcom BCM2837b0 Broadcom BCM2837b0
Number of cores 4 4
Type It is hardware reduced model It is hardware reduced model
compiled software bundled in a nice format for easy installation on your raspberry pi
As Raspberry is a linux operating system it has good security features has excellent networking
capabilities
12. What is smart parking
Smart parking systems are typically obtains information about available parking spaces in a
particular geographic area and process is designed by making us eof someIot supportable
hardwares such as Raspberry pi,uridino boards etc
13. When urban centers are labeled as smart
Urban centers are labeled as smart when they leverage technologies to improve the
management of common resources such as street space or waste collection and improve the
quality of urban life for citizens