Advertisement
jh_elec

Untitled

Sep 7th, 2018
139
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.48 KB | None | 0 0
  1. init:
  2. ldi r16, low(ramend)
  3. out spl, r16
  4. ldi r16, high(ramend)
  5. out sph, r16
  6.  
  7. ldi tmp , 1<<4
  8. out DDRD , tmp
  9. ldi tgl , 1<<4
  10.  
  11. tgrel:
  12. rcall ledoff
  13. rcall delay1ms
  14. rcall ledon
  15. rjmp tgrel
  16.  
  17. delay1ms:
  18. .equ c1ms = 16000;
  19. ldi R25,HIGH(c1ms)
  20. ldi R24,LOW(c1ms)
  21. delay:
  22. sbiw R24,1 ; herunter zaehlen
  23. brne delay ; zaehle bis Null
  24. ret
  25.  
  26.  
  27. ledoff:
  28. sbr tmp , 4
  29. out PORTD , tmp
  30. ret
  31. ledon:
  32. cbr tmp , 4
  33. out PORTD , tmp
  34. ret
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement