Advertisement
kator

Untitled

Mar 5th, 2017
305
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.51 KB | None | 0 0
  1. $MOD52
  2. MOV A,#00000000B
  3. MOV B,#00010000B
  4. MOV R5,#00100000B
  5. MOV R6,#00110000B
  6. start:
  7.  
  8.  
  9.  
  10. CALL delay
  11. INC A
  12. INC B
  13. INC R5
  14. INC R6
  15. CJNE A,#0aH, start
  16. MOV A,#00000000B
  17. MOV B,#00010000B
  18. MOV R5,#00100000B
  19. MOV R6,#00110000B
  20. JMP start:
  21.  
  22. z:
  23. MOV R0, #255
  24. DJNZ R0, $
  25. RET
  26.  
  27. delay:
  28. MOV R1,#0001001B
  29. DLY0: MOV R2,#0a0h
  30. DLY1: MOV R3,#0FFh
  31. DJNZ R3,$
  32. MOV P2, A
  33. call z
  34. MOV P2, B
  35. call z
  36. MOV P2, R5
  37. call z
  38. MOV P2, R6
  39. call z
  40. DJNZ R2,DLY1
  41. DJNZ R1,DLY0
  42. RET
  43. END
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement