Hi all,
Been playing with a LED matrix 7 x 5
My software works ok, but if i make a minor change, It stops working.
To start with i issued high / low commands to switch the rows on or of, but decided to change to e.g. let pinsb = %00000001
This worked fine with all but the last line. When I change the Col_5 routing on line 42 from high / low commands to the pinsb = command it stops working. Any ideas on whats going wrong? Works with all the other sections above...
The same happens when I do the same to the last routine too
Been playing with a LED matrix 7 x 5
My software works ok, but if i make a minor change, It stops working.
To start with i issued high / low commands to switch the rows on or of, but decided to change to e.g. let pinsb = %00000001
This worked fine with all but the last line. When I change the Col_5 routing on line 42 from high / low commands to the pinsb = command it stops working. Any ideas on whats going wrong? Works with all the other sections above...
The same happens when I do the same to the last routine too
Code:
; using 18m2 to drive 7 x 5 led matrix
; Row Pins bank b = led row
; 0 = 1 , 1 = 2 , 2 = 3 , 4 = 5 , 5 = 6 , 6 = 7, 7 = N.C
;
; c.0 = cOLUM 1
; c.1 = cOLUM 2
; c.2 = cOLUM 3
; c.6 = cOLUM 4
; c.7 = cOLUM 5
setfreq m32 ; set clock
do
gosub Col_1 ; enable col1
let pinsb = %11111110 ; set rows
gosub clr
gosub Col_2
let pinsb = %11111100
gosub clr
gosub Col_3
let pinsb = %11111000
gosub clr
gosub Col_4
let pinsb = %11110000
gosub clr
gosub Col_5
low b.0
low b.1
low b.2
low b.3
low b.4
high b.5
high b.6
gosub clr
loop
; WRIGHT TO ScREEN clear
CLr:
pause 10
let pinsb = %00000000
return
Col_1: ; cOLUM 1
let pinsc = %11111110
return
Col_2: ; cOLUM 2
let pinsc = %11111101
return
Col_3: ; cOLUM 3
let pinsc = %11111011
return
Col_4: ; cOLUM 4
let pinsc = %10111111
return
Col_5: ; cOLUM 5
high c.0
high c.1
high c.2
high c.6
low c.7
return