253 emu math

Come to class as there may be corrections, changes and additions.   Substantial accumulating late penalty.

  • Create an assembly project using emu8086
  • Call the file MATH.asm
  • Hand in to your class account on assigned server by deadline (see: handing in assignments)

      See: emu8086 library tutorial: print, printn, print_num, print_num_uns
      See: emu8086 library tutorial: procedures
    Use 8 bit and 16 bit registers as needed. Use the MOV and ADD instructions as needed. Use the PRINT_NUMS and PRINT_NUMS_UNS procedures. Use the PRINTN macro. 0. Use the PRINTN macro to print your name to the screen. 1. Store the biggest 8 bit unsigned number that you can store in AL (binary) & display it as an unsigned decimal. Advance the cursor to the next line. 2. Store the biggest 16 bit unsigned number that you can store in AX (hex) & display it as an unsigned decimal. Advance the cursor to the next line. 3. Store the smallest 16 bit unsigned number that you can store in AX (hex) & display it as an unsigned decimal. Advance the cursor to the next line. 4. Store the biggest 16 bit signed number that you can store in AX (hex) & display it as a signed decimal. Advance the cursor to the next line. 5. Store the smallest 16 bit signed number that you can store in AX (hex) & display it as a signed decimal. Advance the cursor to the next line. 6. Create a 16 bit variable called year and initialize to your birth year. Add that variable to the CX register and display the sum as an unsigned decimal number. Advance the cursor to the next line. 7. Use the PRINTN macro to print your name to the screen.
    Look at and UNDERSTAND the LIST FILE!!!! Note Macros vs. Procedures
    BONUS: Make "advance the cursor to next line" into a procedure and call it each time you want to advance to next line.
    Document the code! Use GOOD variable names!
  •