About VDP command operation code = 0

Страница 1/6
| 2 | 3 | 4 | 5 | 6

By PingPong

Prophet (4093)

Аватар пользователя PingPong

05-06-2011, 17:39

Hi, all.

Just to make everyone ( almost MRC users ) of what i've discovered about write 0 to the command register.

The offiicial docs, say "STOP", meaning that the current command is stopped.
What really happens inside vdp is that the current command is freezed, waiting to BE RESUMED!

so for example if a command was in progress (say 144 decimal code, logical copy ) and you write 0 to the cmd register, the command halt.
But, later if you, write to cmd register the same opcode, 144, the command resumes EXACTLY where it stopped!

I see two uses of this:
1) temporary stopping a command when one need to change R18 (it's know that vram is corrupted)
2) fine check of timings of vdp engine. (Start a command, delay loop, write 0, check vram changes)

For example, in basic i've just started a copy command of entire screen stopped it, and resumed as a byte copy command, by resuming the execution with the high speed copy opcode.

I've also resumed (for fun) a copy command like it was a line.... ( Wink )

Maybe this could interest someone.....

Для того, чтобы оставить комментарий, необходимо регистрация или !login

By ARTRAG

Enlighted (6923)

Аватар пользователя ARTRAG

05-06-2011, 18:22

This could solve the problem in the horizontal scrolling programs.....
Are you interested to test the result on real HW?

By Edwin

Paragon (1182)

Аватар пользователя Edwin

05-06-2011, 18:26

This is really not so strange. It updates all registers internally as the command progresses. There's really no point in trying to reset anything after a command stops. It does the same thing after a command finishes. In fact, I used that fact in Jailbreak to split the player sprite copies when they passed the line 255 barrier. After the command stops for the first half, I only update the page number and NY and restart the command to copy the rest. No need to update all the other registers to something that they are already set to.

I believe Bluemsx doesn't do this entirely correct, judging from the screenshots I received about Jailbreak problems.

By PingPong

Prophet (4093)

Аватар пользователя PingPong

05-06-2011, 18:52

@Edwin. i know. it's not so strange. I've suspected this from a long time, but i needed a confirmation.

I also suppose that, if one write accidentally the same command operation code after a command is finished, nothing happens. Otherwise there will be always a small cache that one see a command in execution, try to stop it when its already finished, then to restart it.

By PingPong

Prophet (4093)

Аватар пользователя PingPong

05-06-2011, 18:57

@ARTRAG: i need a very small test- program to test, maybe i will be forced to load from a wav file or rom file (loadrom) or bloadable from cassette. while my msx disk drive is working, i'm unable to format a new floppy disk drive media without damaging it. In the past i've used a old-single 720KB disk, used many times (writing an image), but now, is dead...

If i cannot find a way to get another 720KB media, i will not be able to use msx disk. Formatting existing 1.44MB with a black stripe on in does not work for me....

By ARTRAG

Enlighted (6923)

Аватар пользователя ARTRAG

05-06-2011, 19:41

A can do a ROM if you like

By PingPong

Prophet (4093)

Аватар пользователя PingPong

05-06-2011, 20:02

A can do a ROM if you like

MAX 48KB? i will use loadrom

By ARTRAG

Enlighted (6923)

Аватар пользователя ARTRAG

06-06-2011, 08:17

Sad with disk to rom I get 128K

By hit9918

Prophet (2927)

Аватар пользователя hit9918

06-06-2011, 19:08


If i cannot find a way to get another 720KB media, i will not be able to use msx disk. Formatting existing 1.44MB with a black stripe on in does not work for me....

The problem is format 720kb on PC? On the net I found "format a: /f:720" ,
which is said to work under vista, but not XP. I slighly remember that under XP the file explorer format hat a selection box where one could go 720k.

If the MSX drive head does wipe too much with format, then I would suspect that it also does this with every "save" operation. It may work for some time but I would prepare for disk wreck.

By jltursan

Prophet (2619)

Аватар пользователя jltursan

06-06-2011, 20:51

To format a 720KB in XP from CMD: FORMAT A: /T:80 /N:9

By PingPong

Prophet (4093)

Аватар пользователя PingPong

06-06-2011, 21:10


If i cannot find a way to get another 720KB media, i will not be able to use msx disk. Formatting existing 1.44MB with a black stripe on in does not work for me....

The problem is format 720kb on PC? On the net I found "format a: /f:720" ,
which is said to work under vista, but not XP. I slighly remember that under XP the file explorer format hat a selection box where one could go 720k.

If the MSX drive head does wipe too much with format, then I would suspect that it also does this with every "save" operation. It may work for some time but I would prepare for disk wreck.

I know, for the early MS-DOS days the format ( i'm a programmer since 1989, being born in 1970 ) command.
the problem is that i get (on pc invalid format or track 0 damaged) for a 1.44MB disk formatted as 720KB cannot format
if, by contrast i try to format on msx, it's unreadable on pc at all.

the same DOES not apply if i use a true 720 disk, instead of a 1.44 with a black stripe to 'fool' the pc disk drive.

actually i can successully work only with those 720 thingy.....

I suspect the windows OS try to do some sort of format verification even with the /U switch of the format command.

Страница 1/6
| 2 | 3 | 4 | 5 | 6