Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- .include <m32def.inc>
- .equ fc = 16000000 ; Prozessortakt (default)
- .cseg
- .def tmp = R16
- .def tgl = R17
- .def cnt = R18
- init:
- ldi tmp , 1<<6
- out DDRC , tmp
- tgRel:
- ldi tgl , 1<<6
- eor tmp , tgl
- out PORTC , tmp
- ldi r26 , LOW ( 500 );
- ldi r27 , HIGH( 500 );
- sbiw r26 , 1
- brne Delay1ms
- rjmp tgRel
- Delay1ms:
- .equ c1ms = 16000;
- ldi R25,HIGH(c1ms)
- ldi R24,LOW(c1ms)
- rjmp delay
- Delay:
- sbiw R24,1 ; herunter zaehlen
- brne Delay ; zaehle bis Null
- nop ; zusaetzliche Verzoegerung
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement