SlotH, I inadvertently copied the code twice. Sorry about that.....
Dave Purola,
N8NTA
SlotH, I inadvertently copied the code twice. Sorry about that.....
Dave Purola,
N8NTA
SlotH, I haven't had my coffee this morning and so I got my first cup and looked at the post. Wow this code won't work so, here it is fixed...
STROBE VAR PORTB.2
CHARACTER VAR BYTE 'ASCII CHARACTER FOR DIGIT ENCODING
COLLUM VAR BYTE [5] 'OUTPUT COLLUM DATA ARRAY
INDEX VAR BYTE 'INDEX COUNTER FOR DISPLAY OUTPUT
************************************************** ******************
CHARTABL: 'CHARACTER LOOK-UP TABLE FOR COLLUMS
' ************************************************** ******************
IF CHARACTER > 31 THEN
' " ","!",""","#","$","%","&","'","(",")","*","+", ",",
'"-",".","/","0","1","2","3","4","5","6","7","8","9",":",";", "<","=",">","?",
'"@","A","B","C","D","E","F","G","H","I","J","K"," L","M","N","O","P","Q","R",
'"S","T","U","V","W","X","Y","Z","[","\","]","^","_","`","a","b","c","d","e",
'"f","g","h","i","j","k","l","m","n","o","p","q"," r","s","t","u","v","w","x",
'"y","z","{","|","}","~"]
COL1:
LOOKUP CHARACTER - 32,[$00,$00,$00,$14,$24,$23,$36,$00,$1C,$00,$14,$08,$0 0,_
$08,$00,$20,$3E,$00,$42,$21,$18,$27,$3C,$01,$36,$0 6,$00,$00,$08,$14,$00,$02,_
$32,$7E,$7F,$3E,$7F,$7F,$7F,$3E,$7F,$00,$20,$7F,$7 F,$7F,$7F,$3E,$7F,$3E,$7F,_
$46,$01,$3F,$1F,$3F,$63,$07,$61,$7F,$02,$00,$04,$4 0,$00,$20,$7f,$38,$38,$38,_
$08,$0c,$7f,$00,$00,$7f,$00,$7c,$7c,$38,$7c,$08,$7 c,$48,$04,$3c,$1c,$3c,$44,_
$0c,$44,$08,$00,$00,$00],COLLUM(0)
COL2:
LOOKUP CHARACTER - 32,[$00,$00,$07,$7F,$2A,$13,$49,$05,$22,$00,$08,$08,$5 0,_
$08,$60,$10,$51,$42,$61,$41,$14,$45,$4A,$71,$49,$4 9,$36,$56,$14,$14,$41,$01,_
$49,$11,$49,$41,$41,$49,$09,$41,$08,$41,$40,$08,$4 0,$02,$04,$41,$09,$41,$09,_
$49,$01,$40,$20,$40,$14,$08,$51,$41,$04,$00,$02,$4 0,$01,$54,$48,$44,$44,$54,_
$7E,$52,$08,$44,$20,$10,$41,$04,$08,$44,$14,$14,$0 8,$54,$3F,$40,$20,$40,$28,_
$50,$64,$36,$00,$00,$08],COLLUM(1)
COL3:
LOOKUP CHARACTER - 32,[$00,$4F,$00,$14,$7F,$08,$55,$03,$41,$41,$3E,$3E,$3 0,_
$08,$60,$08,$49,$7F,$51,$45,$12,$45,$49,$09,$49,$4 9,$36,$36,$22,$14,$22,$51,_
$79,$11,$49,$41,$41,$49,$09,$49,$08,$7F,$41,$14,$4 0,$0C,$08,$41,$09,$51,$19,_
$49,$7F,$40,$40,$38,$08,$70,$49,$41,$08,$41,$01,$4 0,$02,$54,$44,$44,$44,$54,_
$09,$52,$04,$7D,$40,$28,$7F,$18,$04,$44,$14,$14,$0 4,$54,$44,$40,$40,$30,$10,_
$50,$54,$41,$7F,$41,$04],COLLUM(2)
COL4:
LOOKUP CHARACTER - 32,[$00,$00,$07,$7F,$2A,$64,$22,$00,$00,$22,$08,$08,$0 0,_
$08,$00,$04,$45,$40,$49,$4B,$7F,$45,$49,$05,$49,$4 9,$00,$00,$41,$14,$14,$09,_
$41,$11,$49,$41,$22,$49,$09,$49,$08,$41,$3F,$22,$4 0,$02,$10,$41,$09,$21,$29,_
$49,$01,$40,$20,$40,$14,$08,$45,$00,$10,$41,$02,$4 0,$04,$54,$44,$44,$48,$54,_
$01,$52,$04,$40,$44,$44,$40,$04,$04,$44,$14,$18,$0 4,$54,$40,$20,$20,$40,$28,_
$50,$4C,$00,$00,$36,$08],COLLUM(3)
COL5:
LOOKUP CHARACTER - 32,[$00,$00,$00,$14,$12,$62,$50,$00,$00,$1C,$14,$08,$0 0,_
$08,$00,$02,$3E,$00,$46,$31,$10,$39,$30,$03,$36,$3 E,$00,$00,$00,$14,$08,$06,_
$3E,$7E,$36,$22,$1C,$41,$01,$7A,$7F,$00,$01,$41,$4 0,$7F,$7F,$3E,$06,$5E,$46,_
$31,$01,$3F,$1F,$3F,$63,$07,$43,$00,$20,$7F,$04,$4 0,$00,$78,$38,$20,$7F,$18,_
$02,$3E,$78,$00,$3D,$00,$00,$78,$78,$38,$08,$7C,$0 8,$20,$20,$7C,$1C,$3C,$44,_
$3C,$44,$00,$00,$08,$04],COLLUM(4)
ENDIF
FOR INDEX = 0 TO 4
STROBE = 0 ' Enable deactivated
PORTD = COLLUM(INDEX)
STROBE = 1 ' Enable activated
Pauseus 1
NEXT INDEX
RETURN
I hope this helps....
Dave Purola,
N8NTA
first of all, thanks Davethis looks pretty interesting!
Is there any easy method for reading a whole string, or should i just do like this:
CHARACTER = "H"
gosub CHARTABL
CHARACTER = "E"
gosub CHARTABL
CHARACTER = "L"
gosub CHARTABL
CHARACTER = "L"
gosub CHARTABL
CHARACTER = "O"
gosub CHARTABL
Or perhaps you got a better alternative?
SlotH, Yes, if you just want to place individual characters but the strings you are talking about, where are they comming from?
Dave Purola,
N8NTA
They are preprogrammed in the code. Anyway, it's solved now.
Here's a picture of the almost finished result:
http://megadrome.elixant.com/SlotH/LCD5.jpg
(It's Swedish)
So thanks for the help Dave!
That's a really great display job!
gratulerar!
Last edited by mister_e; - 20th August 2006 at 20:19.
Steve
It's not a bug, it's a random feature.
There's no problem, only learning opportunities.
Bookmarks