Re: [cc65] ca65 .charmap directive

From: Ullrich von Bassewitz <uz1musoftware.de>
Date: 2010-03-21 11:29:47
On Sat, Mar 20, 2010 at 09:31:14PM -0400, rhurst@bidmc.harvard.edu wrote:
> Thanks for the quick reply.  Your example, plus removing the "-t vic20"
> option on the ca65 command-line, allowed this to work.  From reading this
> directive's documentation, I would have thought that not to be the case, but
> it is ...

The problem with -t vic20 is that it will preset the character translation
map. So in

        .charmap 'A', $01

the character constant 'A' is is not $41 but $C1, which will make the
directive translate the source character $C1 into $01.

If you use the ASCII codes instead of character constants like

        .charmap $41, $01
        .charmap $42, $02
        .charmap $43, $03
        .asciiz  "ABC"

it will work regardless of the current translation map.

Regards


        Uz


-- 
Ullrich von Bassewitz                                  uz@musoftware.de
----------------------------------------------------------------------
To unsubscribe from the list send mail to majordomo@musoftware.de with
the string "unsubscribe cc65" in the body(!) of the mail.
Received on Sun Mar 21 11:29:55 2010

This archive was generated by hypermail 2.1.8 : 2010-03-21 11:29:59 CET