You have two weeks to work on this lab. This lab is due at the end of your assigned lab period the week of November 11th.
Program requirements:
Load a BCD value from Port E.
Test for legal 2 digit BCD value.
Count the number of illegal values input, and stop when the error count hits 255.
output all 1's on Port B when error value is detected.
convert legal BCD input to binary value.
Store up to 100 binary values in memory.
Output the converted result to Port B when indicated by the handshake protocol.
-Count the number of values translated.
-output all (up to 100) stored values on the Port B,
When count of stored values hits 100
or
when the handshake protocol says to Dump values.
-Use PORT A for the following handshake protocol:
| Port A(input) | Port A(output) | ||||||
| a2 | a1 | a0 | a6 | a5 | a4 | a3 | Status/note |
| 0 | 0 | 1 | . | . | . | . | Port E ready to be read, and input values are 2 BCD digits |
| 0 | 1 | 0 | . | . | . | . | Dump all Stored Values on Port B |
| 0 | 0 | 0 | . | . | . | . | No new data, and no action yet |
| 1 | 0 | 0 | . | . | . | . | Show converted output on Port B |
| . | . | . | 0 | . | . | 1 | Ready to read Port E |
| . | . | . | . | . | 1 | . | Error on Data Conversion |
| . | . | . | . | 1 | . | 0 | Output of values in progress |
| . | . | . | 1 | . | . | 0 | Number of stored values is 100. |
For this lab, use the following simulator setup:
Use the keypad for input on Port A.
Use 8 switches for input on Port E.
Hook the LCD to Port B for output of converted values.
Hook the LEDs to Port A pins for the I/O handshake protocol.
Feel free to email comments and suggestions to
DrAcken@acken.com