Japanese
HARDWARE ManualVDP1 User's Manual
BackForward
VDP1 User's Manual/Chapter 4 System Registers

■4.4 Erase write

Before starting drawing, the sprite IC clears the contents of the frame buffer. This erasure is called erase write, and it specifies the fill area to be erased and the fill data to be written to that area. There are three registers related to erase write: erase write data register , erase write upper left coordinate register , and erase write lower right coordinate register .

■Erase write data register

The erase write data register (EWDR) defines fill data during erase write. This is a 16-bit write-only register located at address 100006H. After turning on the power or resetting, the value becomes undefined, so be sure to set the fill data.

16bit/pixel
 EWDR
100006H
(W)
 bit15
 bit14
 bit13
 bit12
 bit11
 bit10
 bit9
 bit8
 bit7
 bit6
 bit5
 bit4
 bit3
 bit2
 bit1
 bit0
Erase write data

8bit/pixel
 EWDR
100006H
(W)
 bit15
 bit14
 bit13
 bit12
 bit11
 bit10
 bit9
 bit8
 bit7
 bit6
 bit5
 bit4
 bit3
 bit2
 bit1
 bit0
Even number X coordinate erase write data Odd X coordinate erase write data

Erase write data: erase write data, bit15~0
When drawing parts to the framebuffer, VDP1 automatically clears the framebuffer. During this erase (erase write), the frame buffer is filled with the 16-bit data set in the erase write data register.

When drawing to the frame buffer is 8bit/pixel (high resolution or rotation 8), erase/write will be done in 2pixel increments.
The area to be erased and written is set by the erase write upper left coordinate register and the erase write lower right coordinate register.

■Erase write upper left coordinate register

The erase write left coordinate register (EWLR) sets the upper left coordinate of the erase write area. This is a 16-bit write-only register located at address 100008H. After turning on the power or resetting, the values will be unstable, so be sure to set the coordinates. Set unused bits to 0.

 EWLR
100008H
(W)
 bit15
 bit14
 bit13
 bit12
 bit11
 bit10
 bit9
 bit8
 bit7
 bit6
 bit5
 bit4
 bit3
 bit2
 bit1
 bit0
0 Upper left coordinate X1 Upper left coordinate Y1

Erase write upper left coordinates X1: bit14~9
Erase write upper left coordinate Y1: bit8~0

■Erase write lower right coordinate register

The erase write right coordinate register (EWRR) sets the lower right coordinate of the erase write area. This is a 16-bit write-only register located at address 10000AH. After turning on the power or resetting, the values will be unstable, so be sure to set the coordinates.

 EWRR
10000AH
(W)
 bit15
 bit14
 bit13
 bit12
 bit11
 bit10
 bit9
 bit8
 bit7
 bit6
 bit5
 bit4
 bit3
 bit2
 bit1
 bit0
Lower right coordinate X3 Lower right coordinate Y3

Erase write lower right coordinate X3: bit15~9
Erase write lower right coordinate Y3: bit8~0

16bit/pixel
Upper left coordinate X1 = register setting value x 8
Lower right coordinate X3 = register setting value x 8−1

8bit/pixel
Upper left coordinate X1 = register setting value x 16
Lower right coordinate X3 = register setting value × 16−1

Therefore, the possible values of the upper left coordinate X1 and lower right coordinate X3 are as follows.

 system
register value
 16bit/pixel
 8bit/pixel
 high resolution
 rotation 8
 Upper left coordinate X1
 Lower right coordinate X3
 Upper left coordinate X1
 Lower right coordinate X3
 Upper left coordinate X1
 Lower right coordinate X3
 0
 0
 Setting prohibited
 0
 Setting prohibited
 0
 Setting prohibited
 1
 8
 7
 16
 15
 16
 15
 2
 16
 15
 32
 31
 32
 31
 :
 :
 :
 :
 :
 :
 :
 31
 248
 247
 496
 495
 496
 495
 32
 256
 255
 512
 511
 Setting prohibited
 511
 33
 264
 263
 528
 527
 Setting prohibited
 Setting prohibited
 :
 :
 :
 :
 :
 :
 :
 40
 320
 319
 640
 639
 :
 :
 :
 :
 :
 :
 :
 :
 :
 43
 344
 343
 688
 687
 :
 :
 44
 352
 351
 704
 703
 :
 :
 :
 :
 :
 :
 :
 :
 :
 62
 496
 495
 992
 991
 :
 :
 63
 504
 503
 1008
 1007
 :
 :
 64
 Setting prohibited
 511
 Setting prohibited
 1023
 :
 :
 65~
 Setting prohibited
 Setting prohibited
 Setting prohibited
 Setting prohibited
 Setting prohibited
 Setting prohibited

Figure 4.2 Erase write area

Table 4.4 Number of rasters and number of pixels
 screen mode
 Number of horizontal pixels
 in 1 raster
number of pixels in
 in 1 field
Number of rasters in
 NTSC
 320
 1708
 263
 PAL
 352
 1820
 313
 31KC
 852
 525
 HDTV
 848
 562

Table 4.5 Number of pixels that can be used for V blank erase (non-interlaced)
 screen mode
 Resolution (horizontal x vertical)
 Number of pixels available
 NTSC
 320×224
 58812
 320×240
 34684
 352×224
 63180
 352×240
 37260
 PAL
 320×224
 134212
 320×240
 110084
 320×256
 85956
 352×224
 144180
 352×240
 118260
 352×256
 92340
 31KC
 320×480
 29340
 HDTV
 352×480
 53136


BackForward
HARDWARE ManualVDP1 User's Manual
Copyright SEGA ENTERPRISES, LTD., 1997