From: hackbard Date: Sun, 14 Nov 2004 14:00:41 +0000 (+0000) Subject: some fixes X-Git-Url: https://hackdaworld.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=f5978909739fc45f947d06d5027778e4683779e4;p=my-code%2Fatmel.git some fixes --- diff --git a/beginners/rgb_mali.asm b/beginners/rgb_mali.asm index ca83557..3b9815d 100644 --- a/beginners/rgb_mali.asm +++ b/beginners/rgb_mali.asm @@ -14,6 +14,14 @@ ; defines & equals .def zero = r0 .def one = r1 +.def countrgb = r2 +.def desc = r3 +.equ RUP = 0 +.equ RDOWN = 1 +.equ GUP = 2 +.equ GDOWN = 3 +.equ BUP = 4 +.equ BDOWN = 5 .def tmp = r16 .def uart_count = r17 .def count = r18 @@ -25,10 +33,13 @@ .equ rgb = 1 .def OUTR = r23 .def FULLR = r24 +.def tmp2 = r25 .equ LED_R = PD2 .equ LED_G = PD3 .equ LED_B = PD4 .equ LED_PORT = PORTD +.equ CM1 = 85 +.equ CM2 = 170 ; ; interrupt voctors @@ -44,7 +55,7 @@ reti ; timer/counter compare reti ; timer/counter overflow 1 -rjmp INC_RGB +rjmp DO_IT ; timer/counter overflow 0 reti ; uart rx complete @@ -63,7 +74,7 @@ INIT: ; alloc stack pointer ldi r16,low(RAMEND) out SPL,r16 -; timer: clock/1024 +; timer: clock/8 ldi tmp,((1<