Example 1: Load a program into memory, starting at address 0Example 2: Load the same program above, starting at address 3000 000 000 004 023 000 034 200 000 003 001 344 006Example 3: Load a program that includes comments003: 004 023 000 034 200 000 003 001 344 006// Lab Exercise 6 // (From the Laboratory Exercises book) Add Input to A, display A, then stop If bit 7 of input is 1, set A=0 000: 000 A 000 B 000 X 021 P 004: 000 Halt (waiting for input) 272 Skip if Input bit 7 is set 377 344 Jump Direct Unconditional 021 (to [Start]) 004 Add A Memory 377 (Add Input to A) 013: 034 Store A Memory 200 (Show Result) 134 Store B Memory 377 (Clear Input) 344 Jump Unconditional 004 (program stops) 021: 023 Load A Immediate [Start] 000 344 Jump Direct Unconditional 024: 013
Break when the Program Counter reaches address 035003 = 035 --- =
Break when the Program Counter reaches 035 and the A register contains a 0003 = 035 And 000 = 000
Break when either the A or B register contains a 7000 = 007 Or 001 = 007
Break when the B register contains a 7 and the X register does notNote: The user is not notified when a break condition is met. The run light even stays on.001 = 007 Not 002 = 007