Docsity

Lab Assignment 4 - Computer Organization and Program | COSC 2410, Assignments of Computer Architecture and Organization

Toggle sidebar
bg1
COSC 2410 LAB (SUM II)
ASSIGNMENT #4
DUE 07/16/2002(In Lab)
Write an Assembly Program in MASM to implement a simulation of an ATM system,
having a total of 5 users (account holders), the system permits its users to access the
system through an authenticated password (which is issued to every user) and provides to
every user the following services (options):
1) Withdraw money from user account
2) Deposit money to user account
3) Check balance of user account
4) Return to login screen
The total amount present in any account is the net balance of the respective account plus
the interest amount obtained which is computed monthly as a simple interest on a
principal amount of $500.00
The total amount in any account at any time should not fall below $500.00
The system must also display the total amount of any respective user account after the
user utilizes either deposit or withdraw services provided by the ATM system.
ATM System Operation
The system should initially prompt the user to enter the password to access its services
(this is the login screen), after the user has been authenticated; the system provides the
user with the ATM system services. If the user enters an incorrect or invalid password
then system must display an error message and again prompt the user to enter the
password.
After the user has been authenticated to access the system services, the system displays a
list services (as shown above) that the user can use with respect to its account, and
prompts the user to select any one of the system services.
Withdraw money from user account
When the user selects the first option the system should ask the user to enter the amount
the user wants to withdraw from its account. The system should display the modified
balance of the account to the user and should also change the total amount of the account.
Deposit money to user account
When the user selects the second option the system should ask the user to enter the
amount the user wants to deposit to its account. The system should display the updated
balance of the account to the user and should also change the total amount of the account.
pf3

Partial preview of the text

Download Lab Assignment 4 - Computer Organization and Program | COSC 2410 and more Assignments Computer Architecture and Organization in PDF only on Docsity!

COSC 2410 LAB (SUM II)

ASSIGNMENT

DUE 07/16/2002(In Lab)

Write an Assembly Program in MASM to implement a simulation of an ATM system, having a total of 5 users (account holders), the system permits its users to access the system through an authenticated password (which is issued to every user) and provides to every user the following services (options):

  1. Withdraw money from user account
  2. Deposit money to user account
  3. Check balance of user account
  4. Return to login screen The total amount present in any account is the net balance of the respective account plus the interest amount obtained which is computed monthly as a simple interest on a principal amount of $500. The total amount in any account at any time should not fall below $500. The system must also display the total amount of any respective user account after the user utilizes either deposit or withdraw services provided by the ATM system. ATM System Operation The system should initially prompt the user to enter the password to access its services (this is the login screen), after the user has been authenticated; the system provides the user with the ATM system services. If the user enters an incorrect or invalid password then system must display an error message and again prompt the user to enter the password. After the user has been authenticated to access the system services, the system displays a list services (as shown above) that the user can use with respect to its account, and prompts the user to select any one of the system services. Withdraw money from user account When the user selects the first option the system should ask the user to enter the amount the user wants to withdraw from its account. The system should display the modified balance of the account to the user and should also change the total amount of the account. Deposit money to user account When the user selects the second option the system should ask the user to enter the amount the user wants to deposit to its account. The system should display the updated balance of the account to the user and should also change the total amount of the account.

Check balance of user account When the user selects the third option the system should display total amount of the corresponding user account. After using any of the services described above the display should again return back to the list of the services. Return to login screen When the user selects the fourth option the system should return to the login screen. The display for all options or services provided by the system must be center aligned with respect to the current screen. Also they should possess some legible foreground and background color. Your program should also include a file called “bank.inc” which includes passwords for all account holders, their initial account balance, the rate of interest for individual accounts, date (in mm/dd/yyyy format) at which individual accounts were created. An example of the format of such a file is given as: password1 equ “abc123” password2 equ “xyz123” password3 equ “abcdef” password4 equ “678eabc” password5 equ hi amount1 equ 100000 amount2 equ 200000 amount3 equ 300000 amount4 equ 150000 amount5 equ 250000 rate1 equ 2 rate2 equ 3 rate3 equ 5 rate4 equ 6 rate5 equ 8 date1 equ 06121997 date1 equ 07101998 date1 equ 06111999 date1 equ 06092000 date1 equ 06212002 The contents of file “bank.inc” password1, amount1, rate1, date1 are variables that represent various parameters of a single account, say account 1, similarly password2,