View the step-by-step solution to:

Question

Can you write steps of how to go about writing this code for this program with explanation?

/>

take me through the step by step, even by using a flowchart! I need to understand what this program is supposed to act like and run and how to assemble the code to make the machine understand it.


need help with a program that draws lines on PennSim's graphic display, similar to an Etch A Sketch. The program user will be able to "drag" a small box in an up-down or left-right direction to draw a line, and will be able to change the color of the line that is being drawn. The learning objectives for this assignment are

:  Use load and store instructions to manipulate the content of memory.

 Use I/O routines to allow a user to interact with the program.


I don't need someone to write the code and do not intend to submit anyone's work as mine. I'm merely trying to understand how to use assembly language to better code my program.




Screen Shot 2019-10-14 at 11.13.13 PM.pngScreen Shot 2019-10-14 at 11.13.05 PM.pngScreen Shot 2019-10-14 at 11.12.51 PM.pngScreen Shot 2019-10-14 at 11.12.39 PM.png

Screen Shot 2019-10-14 at 11.12.39 PM.png

For this assignment, you will write a program that draws lines on PennSim’s graphic display, similar to an Etch A Sketch®. The program user will be able to “drag” a small box in an up-down or lefi-right
direction to draw a line, and will be able to change the color of the line that is being drawn. The learning objectives for this assignment are:
I Use load and store instructions to manipulate the content of memory. I Use I/O routines to allow a user to interact with the program. Program Specification
The program must start at address x3000. The program will manipulate the location of a 2x2 box on the screen, which we will call the Pen. The
Pen has a color and a location. The screen pixel at the Pen's current location will take on the Pen's
color. When the Pen moves, the pixels at the previous location retain their color. In other words,
moving the Pen will draw a line of a particular color. The PennSim graphics display (the “screen”) is 128 by 124 pixels. We use an (x, y) coordinate system
to describe a location on the screen. Location (0, 0) is the top left comer. The x coordinate increases as
we move to the right, and the y coordinate increases as we move down. In other words, (1, 0) is one
pixel to the right of (0, 0), and location (0, l) is one pixel below (0, 0). Location (127, 123) is the
bottom right comer of the screen. When the program begins, the Pen location must be set to (64, 62) and the color must be White. The user interacts with the program using one-character commands. The commands are typed on the
keyboard, but are not echoed to the console display. Nothing will be printed to the console during the l

Screen Shot 2019-10-14 at 11.12.51 PM.png

Screen Shot 2019-10-14 at 11.13.05 PM.png

Screen Shot 2019-10-14 at 11.13.13 PM.png

Recently Asked Questions

Why Join Course Hero?

Course Hero has all the homework and study help you need to succeed! We’ve got course-specific notes, study guides, and practice tests along with expert tutors.

  • -

    Study Documents

    Find the best study resources around, tagged to your specific courses. Share your own to gain free Course Hero access.

    Browse Documents
  • -

    Question & Answers

    Get one-on-one homework help from our expert tutors—available online 24/7. Ask your own questions or browse existing Q&A threads. Satisfaction guaranteed!

    Ask a Question
Ask Expert Tutors You can ask You can ask ( soon) You can ask (will expire )
Answers in as fast as 15 minutes