Write a program sequence that places the value in address

Assignment Help Programming Languages
Reference no: EM13774919

Question 1. Dynamic memory requires _____ that is not needed for other types of memory.

refresh

data bus buffer

address decoder

dual power supply

Question 2. What is the maximum size of main memory for a processor with a 23-bit address bus?

Eight Mbyte

23 Mbytes

Three Mbytes

8,000,000 bytes

None of the above

Question 3. In a CPU with a 16-bit program counter, what is the maximum, directly accessible code space?

64Kbytes

32KB

2KB

4KB

None of the above

Question 4. The circuit that performs the instruction "ADDA" in the HCS12 CPU is

MMU.

ALU.

cache.

accumulator.

Question 5. Operations performed by the ALU include

decoding instructions.

coordinating data transfer to and from the ALU.

addition and subtraction.

All of the above

None of the above

Question 6. What direction does data flow on a READ bus cycle?

From the CPU to memory or I/O port

From memory or an I/O port into the CPU

From the bus into a memory location

All of the above

None of the above

Question 7. Which of the following is an assembly directive?

"loop:"

"ds.b 1"

"adda"

"bitb"

Question 8. The HCS12 uses _____.

Little Endian

Big Endian

Both A and B

None

Question 9. Which statement about CodeWarrior assembly language is true?

It is case sensitive.

Instructions must start in column other than 1.

Labels never start at Column 1.

All of the above

None of the above

Question 10. Which of the following is wrong?

LDY #$55

LDY #$255

LDY #$20000

LDY #5000

Question 11. What is the value in Accumulator B after the execution of the code below?

ORG $2000

XYZ DC.B 0, 1, 2, 4

ORG $8000

LDY #XYZ

LDAA #04

LDAB #02

BACK ADDB 0, Y

INY

DECA

BNE BACK

HERE BRA HERE
$04

$09

$07

$1009

None of the above

Question 12.The instruction "subb $100" will

subtract the content of Accumulator B from $100.

subtract $100 from Accumulator B.

subtract the content of memory at Address $100 from Accumulator B.

subtract the content of Accumulator B from the content of memory at Address $100.

Question 13. What will be the value in Accumulator A after the following program is executed?

ORG $2000

DATA1 DC.B $55

ORG $8000

LDAA DATA1

LDAB #8

BACK LSLA

DECB

BNE BACK

HERE BRA HERE
63

55

0

1

Question 14. Which flag is used to see if the signed data are correctly added together?

V

C

Z

H

Question 15. In the following program, what is the largest number that Register B can take?

L1 CLRA

NOP

NOP

DECB

BNE L1
255

100

0x200

0x99

Question 16. What C-language construct does the following assembly code implement?

LDAB #10

L1: ADDA 0, x

INX

DECB

BNE L1

Loop

If

If /else

All of the above

None of the above

Question 17. Assume that PORTB has a value of 0x37. Which of the following gives us Unpacked BCD for 7?

PORTB= PORTB & 0x37;

PORTB= PORTB | 0x30;

PORTB= PORTB | 0x0F;

PORTB= PORTB & 0x0F;

Question 18. Fill in the blank to get 0x36 on PORTB.

unsigned char BCD_Byte = 0x67;

unsigned char x;

x= BCD_Byte & 0xF0;

_____;

PORTB = x | 0x30;

x=x>>4;

x=x>>2;

x=x<<4;

x=x<<2;

Question 19. The following program creates square wave pulses on PB0. What is the duty cycle?

ORG

$8000

LDS

#$4000

LDAA

#$FF

STAA

DDRB

BACK

BSET

PORTB,%00000001

JSR

DELAY

BCLR

PORTB,%00000001

JSR

DELAY

JSR

DELAY

BRA

BACK

75%

66%

33%

25%

Question 20. Find the value for PORTB after the execution of the following code:

PORTB = 0x66 ^ 0xFF;

PORTB = 0x66

PORTB = 0x99

PORTB = 0x0F

PORTB = 0x33

Question 21. Write a program sequence that places the value in Address $1000 into Accumulator A and places the value in Address $1001 in Accumulator B. Then, add these values together and store the result in Location $1002.

Question 22. Where is the return address of the subroutine stored when a subroutine is called? How is this return address retrieved at the end of the subroutine?

Question 23. Write a C statement to set Bit 3 of variable foo without changing other bits.

Question 24. Write a HCS12 assembly-language program that counts all even numbers from a 10-variable, byte-sized array and moves the odd numbers to a new array.

Question 25. Write a C program for a HCS12 microcontroller that writes the value, 0x78, to Memory Location VAR1 and then calls a delay function. The delay function should generate a delay of 0.25 milliseconds. Then, send the pattern 0x99 to Memory Location VAR2 and call the delay function one more time. Repeat this operation eight times using a for loop. Assume that the bus clock frequency is 24MHz. Write the delay using inline assembly language.

Verified Expert

This paper answers the multiple choice question of the low level programming like C, HSC12 controller and assembly programming. It also contains the program in the assembly language that make use of the conditional statement and the array and also the basic information about the control flow and logic about the program.

Reference no: EM13774919

Questions Cloud

Explains the legal criteria for civil commitment : Create a 10- to 15-slide multimedia presentation that explains the legal criteria for civil commitment, competency to stand trial, and Not Guild by Reason of Insanity (NGRI)
How does medical parole or release fit into this discussion : Which of these arguments do they think have merit? What values underlie each position? How does medical parole or release fit into this discussion? Provide alternative solutions to the problem and discuss their overall impacts
Write an essay about animal farm : Write an essay about animal farm. composing one of the messages that the pigeons carry to other farms to tell of the Rebellion.
Determine how environmental and innate factors lead : Determine how environmental and innate factors lead to delinquencies. examine the types and examples of juvenile delinquency or crime
Write a program sequence that places the value in address : Write a program sequence that places the value in Address $1000 into Accumulator A and places the value in Address $1001 in Accumulator B. Then, add these values together and store the result in Location $1002.
Write four paragraphs about the movie gladiator : Write four paragraphs about the movie gladiator.
What are the main arguments : An annotated bibliography examines scholarly articles and books on a certain issue and provides a summary of each. The purpose is to offer an overview of the literature on a topic
What facts may weigh in favor of or against chou : What facts may weigh in favor of or against Chou in terms of the parties' objective intent to contract
Explain the multilingual situation in the us : Define "language diversity" and explain the multilingual situation in the US. State your perspectives/argument. Relate how language one speaks may shape his/her identities in public or private.

Reviews

inf774919

8/29/2016 3:08:20 AM

I appreciate for quick delivery of task in this price. You really charged very less from others. I checked the same assignment on 7 more other services but they were asking for high price due to less time, but you did not do so. Thanks for having such a great service, will update you with my new assignments soon.

Write a Review

Programming Languages Questions & Answers

  Write a haskell program to calculates a balanced partition

Write a program in Haskell which calculates a balanced partition of N items where each item has a value between 0 and K such that the difference b/w the sum of the values of first partition,

  Create an application to run in the amazon ec2 service

In this project you will create an application to run in the Amazon EC2 service and you will also create a client that can run on local machine and access your application.

  Explain the process to develop a web page locally

Explain the process to develop a Web page locally

  Write functions

These 14 questions covers java class, Array, link list , generic class.

  Programming assignment

If the user wants to read the input from a file, then the output will also go into a different file . If the user wants to read the input interactively, then the output will go to the screen .

  Write a prolog program using swi proglog

Write a Prolog program using swi proglog

  Create a custom application using eclipse

Create a custom Application Using Eclipse Android Development

  Create a application using the mvc architecture

create a application using the MVC architecture. No scripting elements are allowed in JSP pages.

  Develops bespoke solutions for the rubber industry

Develops bespoke solutions for the rubber industry

  Design a program that models the worms behavior

Design a program that models the worm's behavior.

  Writing a class

Build a class for a type called Fraction

  Design a program that assigns seats on an airplane

Write a program that allows an instructor to keep a grade book and also design and implement a program that assigns seats on an airplane.

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd