Assembly language program to simulate

Assignment Help Basic Computer Science
Reference no: EM13935803

ou are to write an assembly language program to simulate paper tape output from user supplied input

The program performs the following functions:

It first reads a number of decimal digits from the keyboard, with a maximum of 8 digits possible (and a minimum of one digit). Non-digits are

ignored, as well as input beyond 8 digits. You should count the number of digits, and also store them in an array for future reference. Examples:

138
53339
66666666

Input terminates when the RETURN character is typed, or when the maximum of 8 input digits has been reached.

The program now generates paper tape output. This format is based on the well known 'Morse Code', which consists of 'dots' and 'dashes'. On paper tape, a 'dash' is represented by a hole in the bottom half of the paper, and a 'dot' by a hole in the top half. The program
simulates the hole by printing the letter 'o'.

The Morse Codes for the digits are as follows:

0 -----
1 .----
2 ..---
3 ...--
4 ....-
5 .....
6 -....
7 --...
8 ---..
9 ----.

The paper tape output for the number 138 would now be:

o ooo oo
oooo ooooo

Here are some hints on how to write the program.

Define the morse code as a series of consecutive dc.b statements. Since all codes have the same length of 5, it will be straightforward to
calculate where the start of each code can be found. For example, the morse code for the digit 2 starts 2*5 = 10 bytes from the start, and
occupies the next 5 bytes. YOU ARE NOT ALLOWED TO USE SEPARATE LABELS FOR THE INDIVIDUAL CODES (this leads to massive code duplication, and it will cost you a lot of marks).

The program is best implemented as two nested FOR loops. You will have to go through the input twice, once to print the dots and once to print the dashes, deciding at each position within each digit, whether an 'o' or a space needs to be printed.

Submission: Submit a SINGLE PDF FILE on Blackboard, containing both the program source code and documentation. DO NOT provide the source code in the form of screen dumps - this is very difficult to read and impossible to annotate properly. Instead, copy and paste the program from a text editor such as Notepad.

Reference no: EM13935803

Questions Cloud

How uva ltd can reduce economic exposure to exchange rate : Its sales to Thai customers are denominated in baht. Explain how UVA Ltd can reduce its economic exposure to exchange rate fluctuations.
Why do hcos strive for transformational styles : Why do high performing HCO's strive for transformational styles? Is this just the current fad or is there another that you would suggest
What is intermediate moisture food : List 20 antimicrobials used in food manufacturing and specify the maximum allowance of each one in food. What are bacteriocins, list 5 of them and provide examples of applications in foods.
How alright can reduce economic exposure to exchange rate : About 10% of Albany's operating expenses are in Australian dollars; all other expenses are in pounds. Explain how Alright can reduce its economic exposure to exchange rate fluctuations.
Assembly language program to simulate : The program now generates paper tape output. This format is based on the well known 'Morse Code', which consists of 'dots' and 'dashes'. On paper tape, a 'dash' is represented by a hole in the bottom half of the paper, and a 'dot' by a hole in the..
Aspects traits and attributes of leadership : Questions: A) What aspects traits and attributes of leadership are evident from analysing the speech? B) Identify and comment on how the speech is being articulated and delivered.
Find the discharge for free flow : A 3-inch diameter orifice cut in a thin orifice plate conveys flow from a deten- tion basin with water level at elevation 472.00 feet. The center of the orifice is at elevation 467.50 feet. Find the discharge for free flow.
Explain how a firm can hedge its translation exposure : Hedging translation exposure. Explain how a firm can hedge its translation exposure. Exchange rate effects on earnings. Explain how an MNC's consolidated earnings are affected when foreign currencies depreciate.
Leadership for the sustainability of the health system : Leadership for the Sustainability of the Health System: Part 1-A Literature Review. Health Workforce Australia.

Reviews

Write a Review

Basic Computer Science Questions & Answers

  Describe operating model for business process integration

Describe the chosen operating model in terms of business process integration. Compare the selected organization to the sample organizations using the chosen operating model in terms of business process integration.

  How can you minimize the quantization error

How can you minimize the quantization error - Just a simple and quick answer and please no copy and paste.

  Dimensions of system dependability

"Dimensions of System Dependability" Please respond to the following: Consider the four principal dimensions of dependability. Choose two dimensions, describe them, and explain the relationship between your chosen dimensions. Provide at least two ..

  Give the main advantages of a dynamic implementation

Give the main advantages of a dynamic implementation of a list of items over a static implementation.

  The following is an access verification technique

10. The following is an access verification technique, listing several files and the access allowed for a single user. Identify the control technique used here, and for each, explain the type of access allowed. a. File_1   R-E-   b. File_12   RWE-   ..

  Compare and contrast the available accessories potential

apple ipads continue to be successful. the samsung galaxy tab is one 1 of ipads competitors. use the internet and

  Calculates the velocity and momentum of an object

Write a program that does the following: Calculates the Velocity and Momentum of an object. The formula for the velocity is V=d/t and the formula for Momentum is m=mass*velocity. Your program should consist of two functions: Passing By Values (..

  What is the balance factor at the root node after the insert

Insert 100 in the AVL tree of Figure 11-36. The resulting tree must be an AVL tree. What is the balance factor at the root node after the insertion?

  What is intermodulation distortion

What is intermodulation distortion? What sorts of signals are susceptible to this form of distortion?In addition, identify two situations in which error-free transmission is crucial to business processes. Instructions:•Your research essay should be ..

  Design a program that will read a file of employee records

Design a program that will read a file of employee records containing employee number, employee name, hourly pay rate, and regular hours worked and overtime hours worked. The company pays its employees weekly, according to the following rules:Regular..

  What is the effect of the following statements

what is the effect of the following statements?

  Show the background on the layer beneath

show the background on the layer beneath

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