States Of The Registers After Command Execution - Yamaha V9938 Programmer's Manual

Msx-video
Table of Contents

Advertisement

4.6. States of the registers after command execution

Setting up VDP registers for command execution is a significant task for programmer
and CPU, and it will be wise to use already existing values in the registers for the next
command execution or for further work with video memory. For this purpose programmer
should know the resulting states of most important VDP registers. Please see the table
below. Note that if program is going to use sequence of the VDP commands which use
resulting values of registers from previous commands, it is important to disable interrupts
so that interrupt handler routing would not accidentally change values in VDP registers and
thus break the whole command sequence.
CMR H is a higher nibble of the command register R#46; CMR L is a lower nibble of
the command register r#46. ARG is an argument register R#45.
The resulting values of SY*, DY* and NY* are in dots and can be calculated using
equations below:
• If DIY=0 then SY*=SY+N; DY*=DY+N
• If DIY=1 then SY*=SY-N; DY*=DY-N
• NY*=NY-N
LINE command =
SX
SY
HMMC
-
-
YMMM -
*
HMMM -
*
HMMV
-
-
LMMC
-
-
LMCM
-
*
LMMM
-
*
LMMV
-
-
LINE
-
-
SRCH
-
-
PSET
-
-
POINT -
-
Legend:
- Unchanged
* Coordinate at the command end (SY*, DY*) or color code
# Count (NY*) when the end of the screen was detected
© 1985 ASCII CORP. / NIPPON GAKKI CO.
if MAJ=0 then N=N-1 ????
DX
DY
NX
-
*
-
-
*
-
-
*
-
-
*
-
-
*
-
-
-
-
-
*
-
-
*
-
-
*
-
-
-
-
-
-
-
-
-
-
Page 94 of 108
NY
CLR
CMR
H
#
-
0
#
-
0
#
-
0
#
-
0
#
-
0
#
-
0
#
-
0
#
-
0
-
-
0
-
-
0
-
-
0
-
*
0
© 2010-2015 Eugeny Brychkov
CMR L ARG
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents