Download GTU (Gujarat Technological University) BE/BTech (Bachelor of Engineering / Bachelor of Technology) 2018 Winter 5th Sem New 2151001 Microcontroller And Interfacing Ec Previous Question Paper
1
Seat No.: ________ Enrolment No.___________
GUJARAT TECHNOLOGICAL UNIVERSITY
BE - SEMESTER ?V (NEW) EXAMINATION ? WINTER 2018
Subject Code:2151001 Date:20/11/2018
Subject Name:Microcontroller and Interfacing (EC)
Time: 10:30 AM TO 01:00 PM Total Marks: 70
Instructions:
1. Attempt all questions.
2. Make suitable assumptions wherever necessary.
3. Figures to the right indicate full marks.
MARKS
Q.1 (a) Discuss criterion to select microcontroller. 03
(b) Explain conditional branch instructions BREQ and BRNE with
examples. Write an AVR ALP to toggle PA0 pin 100 times using
conditional branch instruction.
04
(c) Discuss SPI bus protocol with reference to AVR microcontroller. 07
Q.2 (a) Write an AVR ALP to find number of 0s in 0x99. 03
(b) Explain the functions of following pins: 1. TCK 2. RXD 3. AREF 4.
RESET.
04
(c) What are the serial interrupts available in AVR microcontroller? Write
interrupt routine to receive data through serial port (RxD) pin and
display data on PORTB. Initialize serial port registers and enable serial
port interrupts in main program.
07
OR
(c) Write an AVR C program to convert (1) packed BCD 0x29 to ASCII
and display the bytes on PORT B and PORT C (2) ASCII digits of ?4?
and ?7? to packed BCD and display them on PORT B.
07
Q.3 (a) Write an AVR ALP to load I/O register of Port B with the value 0x55
and complement I/O register of Port B 10 times.
03
(b) Explain usage of AVR status register. 04
(c) Explain with diagram, DC motor interfacing with AVR. 07
OR
Q.3 (a) Write an AVR C program to toggle all the bits of Port B 100 times. 03
(b) What is need of RTC? Explain interfacing of RTC with AVR
microcontroller.
04
(c) Draw Interfacing diagram to interface LCD with AVR Microcontroller.
Use Port D to drive data lines. Connect RS pin of LCD with PA0 and
Enable pin with PA1. Ground R/W pin of LCD.
07
Q.4 (a) Compare: CISC and RISC architecture. 03
(b) List different shift and rotate instructions and explain any two with
proper example.
04
(c) Write an AVR C program to generate square wave of 60% duty cycle
on Port B.1 bit using Timer0. Analyze the program.
07
OR
Q.4 (a) Discuss the steps for execution of branch instruction in AVR 03
(b) List addressing modes of AVR and explain any two with example. 04
(c) Write an AVR C program to generate square wave with a period of
12.5microsecond on Port B.3 bit using Timer0 in normal mode. Assume
crystal frequency = 8 MHz.
07
Q.5 (a) Explain Bitwise AND and Bitwise OR operators with example. 03
www.FirstRanker.com www.FirstRanker.com
www.FirstRanker.com
FirstRanker.com - FirstRanker's Choice
www.FirstRanker.com
1
Seat No.: ________ Enrolment No.___________
GUJARAT TECHNOLOGICAL UNIVERSITY
BE - SEMESTER ?V (NEW) EXAMINATION ? WINTER 2018
Subject Code:2151001 Date:20/11/2018
Subject Name:Microcontroller and Interfacing (EC)
Time: 10:30 AM TO 01:00 PM Total Marks: 70
Instructions:
1. Attempt all questions.
2. Make suitable assumptions wherever necessary.
3. Figures to the right indicate full marks.
MARKS
Q.1 (a) Discuss criterion to select microcontroller. 03
(b) Explain conditional branch instructions BREQ and BRNE with
examples. Write an AVR ALP to toggle PA0 pin 100 times using
conditional branch instruction.
04
(c) Discuss SPI bus protocol with reference to AVR microcontroller. 07
Q.2 (a) Write an AVR ALP to find number of 0s in 0x99. 03
(b) Explain the functions of following pins: 1. TCK 2. RXD 3. AREF 4.
RESET.
04
(c) What are the serial interrupts available in AVR microcontroller? Write
interrupt routine to receive data through serial port (RxD) pin and
display data on PORTB. Initialize serial port registers and enable serial
port interrupts in main program.
07
OR
(c) Write an AVR C program to convert (1) packed BCD 0x29 to ASCII
and display the bytes on PORT B and PORT C (2) ASCII digits of ?4?
and ?7? to packed BCD and display them on PORT B.
07
Q.3 (a) Write an AVR ALP to load I/O register of Port B with the value 0x55
and complement I/O register of Port B 10 times.
03
(b) Explain usage of AVR status register. 04
(c) Explain with diagram, DC motor interfacing with AVR. 07
OR
Q.3 (a) Write an AVR C program to toggle all the bits of Port B 100 times. 03
(b) What is need of RTC? Explain interfacing of RTC with AVR
microcontroller.
04
(c) Draw Interfacing diagram to interface LCD with AVR Microcontroller.
Use Port D to drive data lines. Connect RS pin of LCD with PA0 and
Enable pin with PA1. Ground R/W pin of LCD.
07
Q.4 (a) Compare: CISC and RISC architecture. 03
(b) List different shift and rotate instructions and explain any two with
proper example.
04
(c) Write an AVR C program to generate square wave of 60% duty cycle
on Port B.1 bit using Timer0. Analyze the program.
07
OR
Q.4 (a) Discuss the steps for execution of branch instruction in AVR 03
(b) List addressing modes of AVR and explain any two with example. 04
(c) Write an AVR C program to generate square wave with a period of
12.5microsecond on Port B.3 bit using Timer0 in normal mode. Assume
crystal frequency = 8 MHz.
07
Q.5 (a) Explain Bitwise AND and Bitwise OR operators with example. 03
www.FirstRanker.com www.FirstRanker.com
www.FirstRanker.com
www.FirstRanker.com
2
(b) Write an AVR ALP to perform 253/10, store remainder in R20 register
and quotient in R21 register.
04
(c) Explain Look-up table concept in AVR with example. 07
OR
Q.5 (a) Compare: Macros and Subroutines. 03
(b) Write an AVR ALP for multiplication of two 8 bit data. 04
(c) Discuss I
2
C bus protocol with appropriate diagram. 07
*************
www.FirstRanker.com www.FirstRanker.com
www.FirstRanker.com
FirstRanker.com - FirstRanker's Choice
This post was last modified on 20 February 2020