Microcontroller 2

अब Quizwiz के साथ अपने होमवर्क और परीक्षाओं को एस करें!

for (number=0; number<=0x10; number +=2) PORTD=number; 0 1 2 3 4 5 6 7 8 9 A B C D E F 10 11 12 13 What is the final value send to PORTD?

10

for (number=0; number<=0x10; number +=2) PORTD=number; 0 1 2 3 4 5 6 7 8 9 A B C D E F 10 11 12 13 What is the final value for number?

12

for (number=0; number<=0x8; number +=2) PORTD=number; 0 1 2 3 4 5 6 7 8 9 A B C D E F 10 11 12 13 What is the final value send to PORTD?

8

for (number=0; number<=0x8; number +=2) PORTD=number; 0 1 2 3 4 5 6 7 8 9 A B C D E F 10 11 12 13 What is the final value of the number?

A

for (number=0; number<0x10; number +=2) PORTD=number; 0 1 2 3 4 5 6 7 8 9 A B C D E F 10 11 12 13 What is the final value send to PORTD?

E

8 LEDs are connected to PORTD. After writing the statement "TRISD =0b11111111;" , how many LEDs can be lighted up.

NONE

Assuming PORTB bit 1 is connected to LED1 , write an instruction to light the LED1 display.

PORTBbits.RB1=1;

Assuming PORTB bit 1 is connected to LED1, write a bit-wise instruction to configure the LED1 display.

TRISBbits.TRISB1=0;

Assuming PORTC bit 7 is connected to SW7, write an byte-wise instruction to configure the SW7 in binary code

TRISC=ob11111111;

Assuming PORTC bit 7 is connected to SW7, write an byte-wise instruction to configure the SW7 in hex code

TRISC=oxFF;

Assuming PORTC bit 7 is connected to SW7, write an bit-wise instruction to configure the SW7

TRISCbits.TRISC7=1;

Why do we need byte-oriented instruction?

To optimise program execution time.

Write a statement to declare an array Module which will store the following integer data: 0x0A, 0x0B, 0x0C, 0x0D, 0x0E, 0x0F, 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16 and 0x17.

int const Module[14]={0x0A, 0x0B, 0x0C, 0x0D, 0x0E, 0x0F, 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16 , 0x17};


संबंधित स्टडी सेट्स

Selected Florida Statues and Rules Quiz 1

View Set

LSAT Valid/Invalid Argument Forms

View Set

Chapter 15: The Value of Synergy

View Set

Chapter 28: Caring for Clients with Heart Failure

View Set

Principals of Business Management Exam 2

View Set

Purpose of Life and Health Insurance

View Set

Transitional Justice Study Guide

View Set

Ch. 6 What Does Representative Democracy Involve?

View Set