To become familiar with HC11 and using BUFFALO utilities, interacting using the terminal program, transferring files, editing-assembling-loading programs and executing them.
Enter the following program: b6 30 00 f6 30 01 1b b7 30 02 3f beginning at $2100 using memory modify. What you type is shown in bold-faced underlined text. Remarks are shown in script font.
First enter the program using memory modify command. You enter each byte followed by a space. When you are done, press enter key. Warning: backspace does not work. So make sure that you make no errors! In the following ## indicates arbitrary numbers
>mm 2100
2100 ## B6 ## 30 ##
Now execute memory dump command to see what is in memory. This should match what you entered using memory modify command. If not, go back and fix any differences.
>md 2100 210F
2100 B6 30 ## ## ## ## ## ## ## ## ## ## ## ## ## ##
Run your program using the call command.
>call 2100
Nothing much seems to happen! Dump memory in locations $3000-300F. Change the value in locations $3000, and 3001 (using memory modify) and rerun the program and copy the values in locations $3000-$3002. You should collect three different sets of data and explain the results in your write-up.
Next you will trace through the program by executing one instruction at a time. First you have to modify the program counter by using the register modify command
>rm
####
####
p- 2100
####
This sets the program counter to $2100. Now trace through the program using the trace command
>t
####
>t
####
asm lab1
Note: You can also go to DOS and run the same command. In either case, make sure that asm.exe is in the path, and the current directory is A: (or where ever the lab1.asm file is). If there are no errors, you should see two new files: lab1.lst and lab1.s19 (you may want to look at these files to see what they look like).
> load t
>call 2000