Im newbie to microcontrollers and picbasic and i'm trying to drive a simple 5x7 led matrix with an 16f628A, i connect the PORTB to the rows and PORTA from PORTA.0 to PORTA.4 to the columns
but the 5th column doesn't show anything.
It's a single 5x7 led matrix.
here's the code:
DEFINE INTOSC
TRISA=0
TRISB=0
loop:
PORTA.0 = 1
PORTB = %01111110 'COLUM DATA
pause 2
PORTA.0 = 0
PORTA.1 = 1
PORTB = %01111110
PAUSE 2
PORTA.1 = 0
PORTA.2 = 1
PORTB = %00000000
PAUSE 2
PORTA.2 = 0
PORTA.3 = 1
PORTB = %01111110
PAUSE 2
PORTA.3 = 0
PORTA.4 = 1
PORTB = %01111110
PAUSE 2
PORTA.4 = 0
GOTO loop
END
i know it could be made easier but im just experimenting with PICBASIC
I wanna make PORTA all DIGITAL OUTPUT
can someone help me?
i just wanna make it show "TE AMO MAMA" letter by letter on the 5x7 led matrix
Bookmarks