Practice assembly problems

These exams are assembly programming practice (old Exam 1, but not structured like Exam this semester) Here are four old exams that you can use to study. Another example The process is

  1. download zip file with project, link to be provided
  2. unzip project
  3. open project in Keil 5.x
  4. add your EID into code in exam1.s file near the top
  5. run in simulator, see low grade
  6. edit exam1.s, build, debug over and over until time is up or get a 100
  7. Right-click the UART window, select all and execute Copy to clipboard, paste into appropriate field of the Exam 1.
  8. upload your exam1.s assembly file in the assignments section
The magic code combines, your EID, exam number, and score. It is all in Cortex M assembly running on the simulator. It has an autograder.

Exam 1

Addendum used in Exam1:  Addendum1 Topics include
Memory access
  - Read/write to global RAM space
  - 8/16/32 bits
  - Signed and unsigned
Registers and stack
  - Temporary variables in registers
  - Use Stack to save(PUSH) and restore(POP)
Arithmetic operations
  - ADD SUB MUL SDIV UDIV   - You will not be tested on overflow/underflow
Shift operations
  - Shifting fixed or a variable number of times
Logical operations
Control structures
  - if-then
  - if-then-else
  - while
  - do-while
  - for-loop
  - Implementation
  - Input parameters with R0,R1,R2...
  - Output parameter with R0
  - Return with BX LR
  - Call functions with BL
  - Functions that invoke other functions need to save LR
  - Pointer/base to array passed by reference in R0
  - You will have the option to access with
    + Index, address is base+precision*index or
    + Pointer, Next pointer is pointer+precision
  - Size is either fixed/known or passed as a number in R1
  - 8/16/32-bit data, signed or unsigned

Old Exam1  (old 9S12 exams) See Lecture 6 for study guide
  Quiz1ASp11FunSize.pdf  old Valvano exam converted to TM4C123 (I don't have solution to this one)
  Quiz1ASp12FunSize.pdf  old Valvano exam converted to TM4C123 (I don't have solution to this one)
  Quiz1AF12.pdf   Quiz1AF12sol.pdf This is a Valvano exam, Fall 2012
  Exam1Practice1.pdf  Exam1Practice1Sol.pdf 
  Exam1Practice3.pdf  Exam1Practice3Sol.pdf 
  Exam1F13A.pdf  Exam1F13Asol.pdf   Exam1F13B.pdf  Exam1F13Bsol.pdf    Fall 2013 exams
  Exam1Sp14.pdf      Spring 2014  (I don't have solution to this one)
  Exam1F14sol.pdf Solutions to Fall 2014 exam 1
  Exam1Sp15.pdf   Exam1Sp15sol.pdf Spring 2015 exam 1
  Exam1Sp16.pdf   Exam1Sp16sol.pdf Spring 2016 exam 1
  Exam1Sp17.pdf   Sp17_EE319K_Exam1_Solution.pdf Spring 2017 exam 1
  Exam1F17.pdf   Exam1F17sol.pdf Fall 2017 exam 1
  Exam1Sp18.pdf   Exam1Sp18sol.pdf Spring 2018 exam 1
  Exam1F18.pdf   Exam1F18sol.pdf Fall 2018 exam 1
  Sp19_EE319K_Exam1.pdf   Sp19_EE319K_Exam1_sol.pdf Spring 2019 exam 1
  Exam1F19A.pdf  Exam1F19Asol.pdf   Exam1F19B.pdf  Exam1F19sol.pdf   Fall 2019 exam 1
  Sp20_EE319K_Exam1.pdf   Sp20_EE319K_Exam1_sol.pdf Spring 2020 exam 1

Exam2 - Fall 2022 (30% assembly, 70% C)

For topics see Lec10.pptx PowerPoint, find lectures on Lecture Page

Download many practice exams:
C/assembly exams (not all exams were the same length).
  CExam2_StringCompare Easy practice Exam 2 involving ASCII strings
  CExam2_CalculusSpring2013 Medium difficulty practice Exam 2 involving Math
  CExam2_Merge Medium difficulty practice Exam 2 involving ASCII strings
  CExam2_Unicode Practice Exam 2 involving 8 and 16-bit arrays
  CExam2_PermuteCombine Medium difficulty practice Exam 2 involving Math
  CExam2_Mode Practice Exam 2 involving arrays and structures
  CExam2_DataBase Practice Exam 2 involving arrays and structures
  CExam2_ManhattanDistance Exam 2 involving math and structures
  CExam2_EKGprocess Medium difficulty
  CExam2_HeartMonitor Medium difficulty
  CExam2_StringConversions Extremely hard, string to octal
  Fall 2020 Exam2, cube volume
Assembly only exams
  Exam2_Mode8 Hard practice Exam 2 involving strings and pointers
  Exam2_ArrayOfStruct Exam 2 with structures and arrays of structures
Recent Exam2s that have process similar to this semester
  Fall 2021 Exam2, overlapping trains
  Spring 2022 Exam2, struct within a struct


  For a final exam study guide see Lec15.pptx
  FinalSp12_1968.pdf  Final exam from Spring 2012 converted to LM3S1968
  FinalF12a.pdf   FinalF12aSol.pdf Final exam Fall 2012
  FinalSp13a.pdf   FinalSp13aSol.pdf   FinalS13.pdf  S13Final.pdf   Final exam Spring 2013
  FinalF13.pdf   FinalF13Sol.pdf   Final exam Fall 2013
  FinalSp14.pdf   FinalSp14Sol.pdf    Final exam Spring 2014
  FinalF14.pdf  FinalF14Sol.pdf Final Exam Fall 2014
  FinalS15.pdf  FinalS15sol.pdf Final Exam Spring 2015
  FinalF15.pdf  (There is no solution available) Final Exam Fall 2015
  FinalS16.pdf  FinalS16sol.pdf Final Exam Spring 2016
  FinalS17.pdf  FinalS17Sol.pdfFinal Exam Spring 2017
  FinalF17.pdf  FinalF17sol.pdf Final Exam Fall 2017
  FinalS18.pdf  FinalS18Sol.pdf Final Exam Spring 2018 
  FinalF18.pdf  FinalF18sol.pdf Final Exam Fall 2018
  FinalSp19.pdf  FinalSp19sol.pdf Final Exam Spring 2019
  FinalF19.pdf  FinalF19sol.pdf Final Exam Fall 2019
  FinalSp22.pdf  FinalSp22sol.pdf Final Exam Spring 2022

This web page made by Jonathan Valvano, updated November 16, 2022 Go to Home