6502 EXAMPLE 1

Example 1

8-Bit Data Transfer
Purpose: Move the contents of memory location 0041to memory location 0042.

Sample Problem:
             (0040) = 6C
Result:  (0041) = 6C


Source Program:

.ORG  0                
LDA #$6C
STA    $41
LDA   $41
STA  #$42


After you compile this code will copy value 6C from memory $41 to  $42.



No comments:

Post a Comment