EE319Ktest3A - EE319K Spring 2007 Quiz 3A Page 1 First Middle Initial Last This is a closed book exam You must put your answers on this piece of

Info iconThis preview shows pages 1–6. Sign up to view the full content.

View Full Document Right Arrow Icon
EE319K Spring 2007 Quiz 3A Page 1 Mark W. Welker April 25, 2007 5:10pm- 6:10 pm First:________________ Middle Initial: _____ Last:____________________ This is a closed book exam. You must put your answers on this piece of paper only. You have 60 minutes, so allocate your time accordingly. Please read the entire quiz before starting. (5) Question 1. (5) Question 2. (5) Question 3. (5) Question 4. (5) Question 5. (5) Question 6. (5) Question 7. (5) Question 8. (5) Question 9. (5) Question 10. (10) Question 11. (5) Question 12.
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
EE319K Spring 2007 Quiz 3A Page 2 Mark W. Welker April 25, 2007 5:10pm- 6:10 pm (5) Question 13. (5) Question 14. (5) Question 15. (10) Question 16. (10) Question 17.
Background image of page 2
EE319K Spring 2007 Quiz 3A Page 3 Mark W. Welker April 25, 2007 5:10pm- 6:10 pm For questions 1 and 2, consider the following C program. xxxx short V=4; void function(void) { yyyy short W=4; } (5) Question 1. What qualifier should be used for yyyy so that W is permanently allocated in RAM? Select from signed, unsigned, volatile, const, static, extern (5) Question 2. What qualifier should be used for xxxx so that V is allocated in ROM? Select from signed, unsigned, volatile, const, static, extern This Fifo queue can hold up to eight 16-bit data values, and the picture shows it currently is holding four values . Address Contents $3000 $3002 $3004 $3006 $1979 $3008 $2010 GetPt $300A $1842 $300C $2005 $300E PutPt (5) Question 3. First, assume we call Fifo_Put . What will be the new PutPt after we call Fifo_Put ? (5) Question 4. Next, assume we call Fifo_Get . What value is returned after we call Fifo_Get ?
Background image of page 3

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
EE319K Spring 2007 Quiz 3A Page 4 Mark W. Welker April 25, 2007 5:10pm- 6:10 pm (5) Question 5. Which 6812 assembly program calls the subroutine, sub, 500 times? 1. ldaa #500 ;initialize counter loop jsr sub ;call the subroutine dbne A,loop ;decrement loop ;counter 2. ldx #500 ;initialize counter loop jsr sub ;call the subroutine dbne X,loop ;decrement loop ;counter 3. Ldy #$500 ;initialize counter Loop jsr sub ;call the subroutine dbne Y,loop ;decrement loop ;counter 4. ldab #500 ;initialize counter loop jsr sub ;call the subroutine dbeq B,loop ;decrement loop ;counter 5. None of these choices is correct.
Background image of page 4
EE319K Spring 2007 Quiz 3A Page 5 Mark W. Welker April 25, 2007 5:10pm- 6:10 pm Questions 6 and 7 involve the following assembly code. main lds #$4000 ldy #1000 pshy ; pass 16-bit in parameter on stack jsr sub1 puly ; balance stack stop data set xxx ; binding of 16-bit local variable in set yyy ; binding of 16-bit input parameter sub1 pshx ; save register X tsx ; RegX stack frame leas -2,s ; allocate 16-bit local variable called data ;****body of the subroutine ldd in ,x ; get a copy of in parameter std data ,x ; store into local variable data ;****end of body leas 2,s ; deallocate data pulx ; restore register X rts ; return (5) Question 6. What value should you use in the yyy position to implement the binding of the parameter, in ? (5) Question 7.
Background image of page 5

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Image of page 6
This is the end of the preview. Sign up to access the rest of the document.

This note was uploaded on 05/02/2008 for the course EE 319K taught by Professor Bard during the Spring '08 term at University of Texas at Austin.

Page1 / 12

EE319Ktest3A - EE319K Spring 2007 Quiz 3A Page 1 First Middle Initial Last This is a closed book exam You must put your answers on this piece of

This preview shows document pages 1 - 6. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online