peterfido
24.11.2007, 20:40
Mein Sub Sonderzeichen, welches ich nach initlcd aufrufe.
Da werden einige Sonderzeichen ab chr(160) definiert. Den Code habe
ich erstellt, nachdem ich das Datenblatt des T6963C studiert hatte. Evtl ist die Adresse des RAMs anzupassen, da es mit der Standardeinstellung bei mir nicht klappen wollte. Ich nutze nur die 6 Punkt breiten Fonts.
Sub Sonderzeichen()
$asm
ldi r24,&h03 ;CG-RAM
rcall _GWrite_Data
clr r24
rcall _GWrite_Data
ldi r24,&H22
rcall _GWrite_Cmd
clr r24 ;CG-RAM komplett gefüllt - 160
rcall _GWrite_Data
ldi r24,&h1c
rcall _GWrite_Data
ldi r24,&H24
rcall _GWrite_Cmd
ldi r24,&hff
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&hff
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&hff
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&hff
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&hff
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&hff
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&hff
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&hff
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&h1e ;CG-Ram gefülltes O - 161
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&hFF
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&hff
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&hff
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&hff
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&hff
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&hff
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&h1e
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&hff ;CG-Ram Antenne - 162
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&hff
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&h1e
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&h1e
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&h0c
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&h0c
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
clr r24
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
clr r24
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
clr r24 ;CG-Ram Smilie - 163
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
clr r24
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&h14
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
clr r24
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&h22
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&h1c
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
clr r24
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
clr r24
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&h30 ;CG-Ram PR - 164
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&h28
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&h30
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&h26
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&h25
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&h06
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&h05
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&h05
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&h1f ;CG-Ram PR liegend 31,5,2,32,31,5,26,32 - 165
rcall _GWrite_Data ; 1f, 05,02,20,1f,05,1a,20
ldi r24,&Hc0 ;stehend 30,28,30,26,25,6,5,5
rcall _GWrite_Cmd
ldi r24,&h05
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&h02
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&h20
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&h1f
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&h05
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&h1a
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&h20
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&h1f ;CG-Ram PC liegend 31,5,2,32,14,17,10,32 - 166
rcall _GWrite_Data ; 1f, 05,02,20,0e,11,0a,20
ldi r24,&Hc0 ; stehend 30,28,32,25,24,5,2,0
rcall _GWrite_Cmd
ldi r24,&h05
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&h02
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&h00
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&h0e
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&h11
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&h0a
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&h00
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
clr r24 ;Herz 0,36,7F,7F,3E,1C,8,0 - 167
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&hA
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&h1F
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&h1F
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&h0E
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&h04
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
clr r24
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
clr r24
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
clr r24 ;CG-Ram trauriges Smilie - 168
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
clr r24
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&h14
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
clr r24
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&h1c
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&h22
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
clr r24
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
clr r24
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
clr r24 ;CG-Ram neutrales Smilie - 169
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
clr r24
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&h14
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
clr r24
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
clr r24
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
ldi r24,&h3E
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
clr r24
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
clr r24
rcall _GWrite_Data
ldi r24,&Hc0
rcall _GWrite_Cmd
$end Asm
End Sub
Die Umlaute sind andere ASCII Codes als beim PC (siehe Datenblatt), müssen also umgewandelt werden, welches allerdings mein PC Programm übernimmt, um dem Atmel Rechenzeit zu sparen.
Powered by vBulletin® Version 4.2.5 Copyright ©2024 Adduco Digital e.K. und vBulletin Solutions, Inc. Alle Rechte vorbehalten.