0% found this document useful (0 votes)
179 views10 pages

Embedded Interview Questions PDF 1675182402

This document contains 125 interview questions related to embedded systems topics such as linker files, memory types, testing types, pointers, variable scope, data structures, RTOS concepts, microcontroller architecture, and more. The questions cover a wide range of foundational and advanced embedded systems engineering concepts.

Uploaded by

mahmoud mohamed
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
179 views10 pages

Embedded Interview Questions PDF 1675182402

This document contains 125 interview questions related to embedded systems topics such as linker files, memory types, testing types, pointers, variable scope, data structures, RTOS concepts, microcontroller architecture, and more. The questions cover a wide range of foundational and advanced embedded systems engineering concepts.

Uploaded by

mahmoud mohamed
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 10

ns

Embedded

io
st
ue
Q
Interview
W
IE
RV
TE

Questions
IN
D
CE
N
VA
AD

Sohaib Dar
&
C
SI
BA
1. Linker file/linker script.
2. Linked List.
3. Difference between boot-loader and startup code.
4. Memories types.
5. Microcontroller Memory Segments.
6. Reentrant and non reentrant functions
7. contents of.c and .h files
8. Static and Dynamic Architecture.

ns
9. Testing Types.

io
10. What do you know about Call by Reference.

st
11. General questions about pointers like NULL pointer, dangling pointer, pointers

ue
arithmetic
12. What do you know about const keyword and its usage with pointer.

Q
13. What do you know about variable scope and life-time.

W
14. Different types of RAM.

IE
15. What do you know about software development cycle.
RV
16. The usage of the typedef keyword.
17. What is the difference between the waterfall Model and V-Model ?
TE

18. What will happen if function return the address of one of its local variables?
19. What do you know about Stack Overflow.
IN

20. What do you know about #Pragma.


D

21. What is the difference between Structure and Union ? difference between static,
CE

dynamic and automatic memory allocation ?


22. Talk about your Embedded Diploma Project.
N

23. What is the difference between RAM and ROM.


VA

24. What do you know about Inline Function.


AD

25. How to use a global variable from another file.C.


26. What is the usage of the #pragma
&

27. C Compilation Process in details.


28. Difference between MACROS and Functions.
C
SI

29. How to define the Memory mapped registers without using library.
BA

30. Difference between EEPROM and Flash-EEPROM.


31. Types of memories in MC and segments of SRAM and FLASH.
32. What is size of character, integer, integer pointer, character pointer?
33. What is void pointer and what is its use?
34. Can structures be passed to the functions by value?
35. Why cannot arrays be passed by values to functions?
36. Advantages and disadvantages of using macro and inline functions?
37. What happens when recursion functions are declared inline?
38. #define cat(x,y) x##y concatenates x to y. But cat(cat(1,2),3) does not expand but
gives preprocessor warning. Why?
39. Can you have constant volatile variable? Yes, you can have a volatile pointer?
40. ++*ip increments what? it increments what ip points to
41. malloc (sizeof(0)) will return — valid pointer
42. How can you define a structure with bit field members?
43. Which parameters decide the size of data type for a processor ?
44. What is job of preprocessor, compiler, assembler and linker ?
45. What is the difference between static linking and dynamic linking ?
46. Data declarations: using the variable a, give definitions for the following:

ns
47. a) int a; // An integer

io
b) int *a; // A pointer to an integer

st
c) int **a; // A pointer to a pointer to an integer

ue
d) int a[10]; // An array of 10 integers
e) int *a[10]; // An array of 10 pointers to integers

Q
f) int (*a)[10]; // A pointer to an array of 10 integers

W
g) int (*a)(int); // A pointer to a function that takes an integer as an argument

IE
and returns an integer
RV
h) int (*a[10])(int); // An array of ten pointers to functions that take an integer
argument and return
TE

an integer
IN
D
CE

48. Building Process in details


49. Difference between static, extern, volatile and register keywords
N

50. Difference reentrant & non-reentrant API's and between Sync and Async API's.
VA

51. Write function to measure the duty cycle of a signal


AD

52. C Code to count number of ones in the binary of an integer number


53. Algorithm Scheduler – Dispatcher in RTOS
&

54. Priority inheritance and inversion


55. Static and Extern with function and global variable
C
SI

56. Write function to send / get character using SPI with polling and interrupt
BA

57. Difference between using polling and interrupt


58. Dynamic Arch. Types
59. Why While(1) is more deterministic than ROTS
60. Write function to read input analog signal using ADC ch_1
61. Difference between primitive and the non-primitive kernel
62. Describe USART frame and I2C Frame
63. Describe AUTOSAR Layers Arch.
64. What happens when interrupt occurs in details
65. Synch. Vs Asych communication types Difference between Mutex and Semaphore
Binary vs counting semaphore
66. Control Unit and CPU main components Difference between Microcontroller and
Microprocessor
67. Difference between non-preemptive and preemptive kernels
68. Dead lock issue and how to solve it .
69. Watchdog timer
70. Interrupt Circuit
71. Interrupt Life cycle
72. Difference between priority Inversion and priority Inheritance.
73. C function to count the maximum number of consecutive one's in 8-bit binary
number

ns
io
74. BSW layered Architectures

st
75. Complier errors – Liner errors – preprocessor errors.

ue
76. Why use critical section
77. What is block scope?.

Q
78. Function to get the number of ZERO's and One's in the binary of a character

W
variable.

IE
79. RTOS footprint
RV
80. Why RTOS??
81. Call by reference and call by value
TE

82. Stack overflow problem Macro like function vs function Function vs inline
function
IN

83. Testing Techniques


D

84. UART vs USART


CE

85. Bus Arbitration


86. What is Interrupt latency? How to reduce it?
N

87. Using Bit fields


VA

88. Bit Manipulation using bit masking


AD

89. Difference between big endian and little endian


90. Software Modularity 66. Real Time analysis
&

91. Typedef vs #define


92. Time Triggering
C
SI

93. MCAL , HAL layers


BA

94. Integration Testing


95. Unit Testing
96. Misra Rules.
97. Compiler Optimization.
98. Linked list
99. Stack vs Queue.
100.Design Constrains
101.Microcontroller Constrains
102. Insert node between two nodes in double linked list.
103.Debugger – Simulator – Emulator
104.Microcontroller Architecture
105.Delete node between two nodes in double linked list
106.Append node in double linked list.
107.Using static with local vs with global
108.Function scope vs file scope
109.Write function to toggle led with 1 sec without using
delay function
110. ARM Architecture
111. Pipelining , Pipelining limitation
112. Paging Technique

ns
113. Bank switching Technique

io
114. How to write code more optimized?

st
115. Foreground Background is more deterministic than RTOS

ue
116. Why RTOS is more responsiveness than While(1)
117. Static Architecture

Q
118. Function prototype and header file content

W
119. RAM section

IE
120.LIFO vs FIFO
RV
121.V model
122.Software life cycle
TE

123.White Box and Black Box


124.What are static variables?
IN

125.What are volatile variables?


D

126.What do you mean by const keyword ?


CE

127.What is interrupt latency?


128.How you can optimize it?
N

129.What is size of character, integer, integer pointer, character pointer?


VA

130.What is NULL pointer and what is its use?


AD

131.What is void pointer and what is its use? 9.What is ISR?


132.What is return type of ISR?
&

133.Can we use any function inside ISR?


134.Can we use printf inside ISR?
C
SI

135.Can we put breakpoint inside ISR?


BA

136.How to decide whether given processor is using little endian format or big endian
format ?
137.What is Top half & bottom half of a kernel?
138.Difference between RISC and CISC processor.
139.What is the difference between hard real-time and soft real-time OS?
140.What type of scheduling is there in RTOS?
141.What is priority inversion?
142.What is priority inheritance?
143.How many types of IPC mechanism you know?
144.What is semaphore?
145.What is spin lock?
146.What is difference between binary semaphore and mutex?
147.What is virtual memory?
148.What is kernel paging?
149.Can structures be passed to the functions by value?
150.Why cannot arrays be passed by values to functions?
151.Advantages and disadvantages of using macro and inline functions?
152.What happens when recursion functions are declared inline?
153.#define cat(x,y) x##y concatenates x to y. But cat(cat(1,2),3) does not expand but
gives preprocessor warning. Why?

ns
154.Can you have constant volatile variable? Yes, you can have a volatile pointer?

io
155.++*ip increments what? it increments what ip points to

st
156.Operations involving unsigned and signed — unsigned will be converted to

ue
signed
157.Which way of writing infinite loops is more efficient than others? there are 3ways.

Q
158.Who to know whether system uses big endian or little endian format and how to

W
convert among them?

IE
159.What is forward reference w.r.t. pointers in c?
RV
160.How is generic list manipulation function written which accepts elements of any
kind?
TE

161.What is the difference between embedded systems and the system in which RTOS
is running?
IN

162.How can you define a structure with bit field members?


D

163.How do you write a function which takes 2 arguments - a byte and a field in the
CE

byte and returns the value of the field in that byte?


164.Which parameters decide the size of data type for a processor ?
N

165.What is job of preprocessor, compiler, assembler and linker ?


VA

166.What is the difference between static linking and dynamic linking ?


AD

167.How to implement a WD timer in software ?


168.⦁why stack would overflow
&

169.⦁How to protect the stack from overflow


170.⦁what is CAN (types of frames, error check types)
C
SI

171.⦁what is bootloader and where it is located in memory


BA

172.⦁what is continent of bootloader code


173.⦁what is Round Robin in RTOS
174.⦁What do u know about AUTOSAR
175.⦁What is RTE
176.⦁communication protocols (UART, SPI, I2C)
177.⦁CAN Bus and LIN (if you know)
178.⦁Embedded C concepts
179.⦁Reentrant and non-reentrant functions, and How to convert one to another
180.⦁Interrupts and Handlers
181.⦁Difference between mutex and semaphore
182.⦁Coding (swap two variables without temp var, arithmetic operation on array
passed by reference)
183.⦁How to change the entry point (main)
184.⦁How to communicate with multi slave with only 4 wires in SPI (No dizzy chain)
185.⦁difference between SPI and I2C
186.⦁How to control motor speed (SW, HW)
187.⦁EEPROM with I2C (Frame) reading and writing
188.⦁Timers
189.⦁C key-words
190.⦁How to use volatile pointers and its importance

ns
191.⦁Differences between inline function, MACRO function, and function

io
192.⦁delay for 1 sec with timer

st
193.⦁ADC types and modes

ue
194.⦁Bit manipulation
195.⦁Keypad (connection and hardware)

Q
196.⦁CPU load in RTOS

W
197.⦁How to calculate CPU load without knowing each task execution time (hint: Idle

IE
task)
RV
198.⦁How to know number is big endian or little endian, and how to convert from one
to another
TE

199.⦁white block and black block (SW design)


200.⦁wild pointer
IN

201.⦁ADC temp sensor


D

202.⦁ICU usage
CE

203.⦁Memory segments
204.⦁Priority inversion, priority inheritance, priority ceiling protocol, Deadlock.
N

205.⦁interprocess communication in RTOS


VA

206.⦁pre-emptive and non-preemptive functions


AD

207.⦁Scheduling algorithms
208.What's The Startup Code?
&

209.What's The Bootloader?


210.What's a CallBack Function? Usage Examples?
C
SI

211. Null, Void, Dangling, Wild Pointers in C


BA

212.What's A Segmentation Fault?


213.What’s the difference between array and pointer in C?
214.Constant pointer Vs pointer to a constant
215.What are Macros in C? Pros and Cons?
216.What does it mean to have a static function?
217.What’s an inline function in C?
218.What's A Reentrant Function in C?
219.What’s memory padding and alignment?
220.What’s the C Preprocessor’s Function?
221.Functions of #define, #if, #pragma
222.How to prevent multiple inclusion of header files? Why?
223.Explain The Embedded C Build Process (Detailed Steps)
224.What do you know about MISRA C rules?
225. Do you think we can write recursive code in embedded C? why yesor no?
226. Static vs Dynamic memory allocation in C
227. What's Memory Fragmentation?
228. What’s dynamic memory allocation? And why it’s avoided in embedded C?
229.Can you include a .c File into another .c file?
230.How to set, clear, and toggle a single bit of a register in C?
231.Discuss RISC vs CISC processors

ns
232.What’s pipelining? How does it affect CPU performance?

io
233.What are the differences between Harvard & Von Neumann

st
Architectures?

ue
234.What are the differences between a Microcontroller & a Microprocessor?
235.What are the differences between RAM & ROM?

Q
236.What are the differences between FLASH & EEPROM?

W
237.What is Endianness? Little and Big

IE
238.What’s Bit Banging?
RV
239.What’s Bit Banding?
240.Differences between 8-Bit and 32-Bit architectures?
TE

241.What’s DMA? Give example applications for DMA


242.Using a timer, measure the execution time of a C function
IN

243.Using a timer, generate software PWM signal


D

244.Using a timer, measure a digital pulse width


CE

245.Using a timer, measure a digital signal’s frequency


246.Write the equations and select the parameters to generate a 1ms timer interrupt
N

247.What’s the watchdog timer (WDT)? When and Why it’s used?
VA

248.When should you kick the WDT?


AD

249.Can we send and return data from ISR?


250.Can we call other functions inside ISR?
&

251.Explain interrupt execution sequence


252.State the types of interrupts
C
SI

253.Vectored VS Non-Vectored interrupts


254.Explain Interrupts late arrival – ARM
BA

255.Explain Interrupts tail-chaining – ARM


256.What’s NVIC in ARM Cortex?
257.Explain interrupts nesting
258.What’s interrupt latency? What causes it?
259.How can you measure interrupt latency?
260.How can we reduce the interrupt latency?
261.What’s the interrupt vector table? Where it’s stored? Can you change its location?
262.What’s PWM? How does it work? And What are the parameters of a PWM Signal?
263.How to generate multiple software PWM signals with 1 timer?
264.How to measure pulse width with ICU (input capture unit)?
265.How to measure the frequency of a signal with ICU?
266.How to measure the duty cycle of a signal with ICU?What’s PWM resolution? How
to control it?
267.How to implement a software ICU?
268.Using PWM, create a DAC system
269.Generate 2 software PWM signals with controllable duty cycle and phase
difference
270.How does ADC work? What are the ADC types?
271.Explain ADC sampling time and acquisition time

ns
272.How to pick the proper sampling rate for ADC?

io
273.What’s the effect of analog input impedance on the ADC’s reading?

st
274.What’s ADC channels cross-coupling? How to eliminate it?

ue
275.Write code to read temperature with ADC
276.Using 8-Bit DAC, write code to generate a sawtooth waveform @ 50Hz

Q
277.Using 8-Bit DAC, write code to generate a triangular waveform @ 50Hz

W
278.Using 8-Bit DAC, write code to generate a sine waveform @ 50Hz

IE
279.Compare between SPI and I2C
RV
280.Which offers the highest data rate among SPI, I2C, UART protocols?
281.Which port to use for onboard high-speed communication? Why?
TE

282.At the same baud rate which would send more data SPI or UART? Why?
283.How does UART communication work?
IN

284.What’s the UART frame structure?


D

285.What’s Baud Rate and Bit Rate?


CE

286.Differences between UART and USART


287.What’s parity bit in UART?
N

288.is UART synchronous or asynchronous protocol?


VA

289.is UART Full-duplex or Half-duplex communication?


AD

290.What’s the pin sampling rate for the UART receiver?


291.Can UART be a multi-slave protocol?
&

292.Give some example applications in which UART is a good choice as a


communication port
C
SI

293.Write code to send 1000 bytes of data with UART


BA

294.How does SPI communication work?


295.Define the SPI clock phase and polarity
296.What are SPI mode numbers 0,1, 2, 3
297.How to daisy-chain some SPI devices?
298.How many slaves can SPI master communicate to?
299.Can an SPI slave initiate a communication?
300.Is SPI a synchronous or asynchronous protocol?
301.Give some example applications in which SPI is a good choice as a
communication port
302.What do you think sets the upper limit for SPI speed?
303.How does I2C communication work?
304.What are the basic elements of I2C transactions?
305.How many slaves can be addressed on the I2C bus?Is I2C a
306.synchronous or asynchronous protocol?
307.What are start and stop conditions?
308.What is arbitration in I2C? Why it’s useful?
309.Give some example applications in which I2C is a good choice as a
310.communication port
311. What would happen if two masters wanted to send data to the same
312.slave at the exact same moment?

ns
313.What’s The CPU Load?

io
314.What’s the scheduler? List down some scheduling algorithms

st
315.What’s a deadlock and when does it occur?

ue
316.Differences between Mutex and Semaphores
317.What’s the priority ceiling?

Q
318.What’s the priority inversion?

W
319.What’s the priority inheritance?

IE
320.Write a FreeRTOS task implementation in c
RV
321.Preemptive vs Non-Preemptive kernels
322.What’s the speed range for the CAN bus?
TE

323.What’s the speed range for LIN?


324.Applications For CAN and LIN
IN

325.Differences between CAN and LIN


D

326.Why CAN bus has 2 resistors at both ends?


CE

327.What happens when 2 CAN nodes transmit data with the same id at
328.the same time?
N

329.What do you know about AUTOSAR?


VA

330.What’s SWC?What’s the RTE? It’s functions?


AD

331.What do you know about iso26262 and functional safety?


332.What’s JTAG?
&

333.Simulator VS Emulator
C
SI
BA

You might also like