[comp.sys.handhelds] chip 2.25 question

steve@gumby.Altos.COM (Steve Scherf) (04/02/91)

Come on, people! I know there are a bunch of Chip 48 hackers out there!
I will repeat my question again, in case you all forgot it. I know somebody
out there has the answer! Don't be lazy!

---------
I have an esoteric question about two instructions in the Chip 48 machine
code. If this has already been discussed here, please bear with me as I
have not been reading this group for the past 4 or 5 months.

In the original document from gson@niksula.hut.fi there is a one-line
description of each of the instructions and their opcodes. Two in particular
are described ambiguously; these are the instruction to do a left shift one bit
and the analogous instruction to do a right shift. The documentation states
that the opcode for a right shift of register VX is 8XY6 where X is the
hex digit after the 'V' in VX. That's all fine and dandy, but what's 'Y'?
This is a single register operation, so why is there a 'Y' in the opcode?
Similarly, the left shift opcode is 8XYE with no obvious reason for a 'Y'.

Also, not actually having written a Chip 48 program yet, can anyone tell me
what the byte ordering for a two byte instruction is? Is it big-endian like
sprites?

Thanks in advance!
-- 
Steve Scherf
steve@Altos.COM    ...!{sun|sco|pyramid|amdahl|uunet}!altos!steve

These opinions are solely mine, but others may share them if they like.

akcs.zoom@hpcvbbs.UUCP (Erin Catto) (04/04/91)

Hey Steve, I'm currently writing a CHIP 48 game.  I write the
instructions in Wicke's ASC format.  Just look at an ASC encoding of a
game to figure out the byte ordering.  The first five digits are identify
the object as a string, so they're always the same on any CHIP 48
program.  The next five digits is the hex size (bytes) of the on line
listing without prefix or suffix.  The last four characters is the
checksum of the resulting object. Anyway, commands are entered as
follows:  8XY6 => X86Y .  I don't know about the 'Y' and luckily I
haven't had to use it.
                             
                               Zoom