2020-02-07 20:47:38 +01:00
|
|
|
%import c64lib
|
|
|
|
%import c64utils
|
|
|
|
%zeropage basicsafe
|
|
|
|
|
|
|
|
|
|
|
|
main {
|
|
|
|
|
|
|
|
sub start() {
|
|
|
|
|
|
|
|
c64.VMCSB |= 2 ; switch to lowercase charset
|
|
|
|
|
2020-02-08 17:38:41 +01:00
|
|
|
str s1 = "HELLO hello 1234 @[/]\n" ; regular strings have default encoding (petscii on c64)
|
|
|
|
str s2 = @"HELLO hello 1234 @[/]\n" ; TODO @-strings for alternate encoding (screencode on c64)
|
2020-02-07 20:47:38 +01:00
|
|
|
|
|
|
|
c64scr.print("\n\n\n\nString output via print:\n")
|
|
|
|
c64scr.print(s1)
|
|
|
|
c64scr.print(s2)
|
|
|
|
|
|
|
|
c64scr.print("\nThe top two screen lines are set via screencodes.\n")
|
|
|
|
ubyte i
|
2020-02-08 02:21:18 +01:00
|
|
|
for i in 0 to len(s1)-1
|
2020-02-07 20:47:38 +01:00
|
|
|
@($0400+i) = s1[i]
|
2020-02-08 02:21:18 +01:00
|
|
|
|
|
|
|
for i in 0 to len(s2)-1
|
2020-02-07 20:47:38 +01:00
|
|
|
@($0400+40+i) = s2[i]
|
|
|
|
}
|
|
|
|
}
|