Advertisement
bytesiz3d

Untitled

Jan 14th, 2021
151
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.84 KB | None | 0 0
  1. ; Destination Addressing Modes
  2.  
  3. ; Direct
  4. mov A, R0; 0
  5. ; A[0] = Address of B[0]
  6. mov X, (R0)+; 2
  7. ; A[1] = Address of B[0]
  8. mov X, (R0)+; 4
  9. ; A[1] = Address of B[1]
  10. mov Y, -(R0); 6
  11. ; A[2] = Address of B[2]
  12. mov Z, 1(R0); 8
  13.  
  14. ; Indirect
  15. mov A, R0; 11
  16. ; B[0] = Address of B[0]
  17. mov X, @(R0)+; 13
  18. ; B[1] = Address of B[0]
  19. mov X, @(R0)+; 15
  20. ; B[1] = Address of B[1]
  21. mov Y, @-(R0); 17
  22. ; B[2] = Address of B[2]
  23. mov Z, @1(R0); 19
  24.  
  25. mov A, R0; 22
  26. mov (R0)+, R1; 24, R1 = 37
  27. mov (R0)+, R1; 25, R1 = 38
  28. mov (R0)+, R1; 26, R1 = 39
  29.  
  30. mov B, R0; 27
  31. mov (R0)+, R1; 29, R1 = 37
  32. mov (R0)+, R1; 30, R1 = 38
  33. mov (R0)+, R1; 31, R1 = 39
  34.  
  35. ; Starting address, values...
  36. define A 33,0,0,0 ;32
  37. ; Starting address, values...
  38. define B 37,0,0,0 ;36
  39.  
  40. define X 37 ; 40, Address of B[0]
  41. define Y 38 ; 41, Address of B[1]
  42. define Z 39 ; 42, Address of B[2]
  43.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement