| |
Senbei
Registered: Dec 2014 Posts: 1 |
VSP bug with DEN manipulation
Ciriciao,
the whole VSP bug detection/fixing/avoiding is extremely catching, but there's one thing I'm not sure of and can't find it in the discussions so far: the VIC-II article mentions that VSP (or DMA delay) can also be achieved by manipulating DEN in line #30 (display enable, bit 4 of D011) instead of YSCROLL.
With this technique YSCROLL stays at 000 the whole time and the bad line is triggered at the right cycle by another means.
Does the VSP bug happens also in this case?
SNB |
|
... 7 posts hidden. Click here to view all posts.... |
| |
Oswald
Registered: Apr 2002 Posts: 5094 |
iirc you can do vsp anywhere outside of the display area so no need to jump trough hoops to hide fli dma shit ? but even when I did it mid screen by "tearing" an idle line with FLD to do it there (hence otherwise wont work) I dont remember having to linecrunch. |
| |
Krill
Registered: Apr 2002 Posts: 2980 |
Quoting Oswaldno need to jump trough hoops [...] I dont remember having to linecrunch. That's because you probably used a black background! :D |
| |
Oswald
Registered: Apr 2002 Posts: 5094 |
Quote: Quoting Oswaldno need to jump trough hoops [...] I dont remember having to linecrunch. That's because you probably used a black background! :D
probably, but if one doesnt vsp mid screen this problem shouldnt arise.
btw I always just did dec d011 inc d011, is that den bit or yscroll? I saw it somewhere and just went with it :) |
| |
lft
Registered: Jul 2007 Posts: 369 |
Oswald, that's the yscroll method.
JackAsser, I think perhaps Monte Carlos is talking about how to test for VSP crashiness, like VSP Lab is doing. Depending on what bits you change in yscroll, the timing is slightly different. But I don't agree with his conclusion. I'd say that the DEN method is one extra case to check for (not eight; yscroll must be 0 when using the DEN method), so now there are 57 test cases. |
| |
JackAsser
Registered: Jun 2002 Posts: 2014 |
Quote: Oswald, that's the yscroll method.
JackAsser, I think perhaps Monte Carlos is talking about how to test for VSP crashiness, like VSP Lab is doing. Depending on what bits you change in yscroll, the timing is slightly different. But I don't agree with his conclusion. I'd say that the DEN method is one extra case to check for (not eight; yscroll must be 0 when using the DEN method), so now there are 57 test cases.
Ahh ok, yeah he probably meant that! |
| |
JackAsser
Registered: Jun 2002 Posts: 2014 |
Quote: probably, but if one doesnt vsp mid screen this problem shouldnt arise.
btw I always just did dec d011 inc d011, is that den bit or yscroll? I saw it somewhere and just went with it :)
:)
dec $d011 = vsp
inc $d011 = line crunch
So yeah, you also did it but didnt know about it. Try leave out the inc and watch the FLI bug. |
| |
JackAsser
Registered: Jun 2002 Posts: 2014 |
Quote: :)
dec $d011 = vsp
inc $d011 = line crunch
So yeah, you also did it but didnt know about it. Try leave out the inc and watch the FLI bug.
(Sorry for being OT, this is the y-scroll method. Just want to illustrate it a bit)
Here's a little snippet to illustrate it Oswaldo. Just wrote it into the monitor. It performs VSP without the line crunch activated. I opened the borders so that you see what's going on properly:
.C:c000 78 SEI
.C:c001 2C 11 D0 BIT $D011
.C:c004 10 FB BPL $C001
.C:c006 2C 11 D0 BIT $D011
.C:c009 30 FB BMI $C006
.C:c00b A9 1B LDA #$1B
.C:c00d 8D 11 D0 STA $D011
.C:c010 A9 32 LDA #$32
.C:c012 CD 12 D0 CMP $D012
.C:c015 D0 FB BNE $C012
.C:c017 48 PHA
.C:c018 68 PLA
.C:c019 48 PHA
.C:c01a 68 PLA
.C:c01b 48 PHA
.C:c01c 68 PLA
.C:c01d CE 11 D0 DEC $D011
.C:c020 EA NOP
.C:c021 EA NOP
.C:c022 EA NOP
.C:c023 A9 FA LDA #$FA
.C:c025 CD 12 D0 CMP $D012
.C:c028 D0 FB BNE $C025
.C:c02a A9 13 LDA #$13
.C:c02c 8D 11 D0 STA $D011
.C:c02f A9 00 LDA #$00
.C:c031 8D FF 3F STA $3FFF
.C:c034 4C 01 C0 JMP $C001
Replace c020 with INC $d011 to activate the line crunch and squish the FLI-bug into one raster line, well hidden under the border. If done mid-screen one might want to use illegal gfx-mode on that line to have it all black. I did that in the scroller for the hidden line vector part in the 1990-demo, where you see one line of black between the vector and the scroller. |
| |
Oswald
Registered: Apr 2002 Posts: 5094 |
nice, that explains why vsp always seemed to eat away one char row for me, thank you :) I always thought only dec has effect and inc just restores the value.
more questions:
- why is the fli bug teared up horizontally
- why it ends up on the left side on screen
- where do chars come from on top row, left from the fli bug? |
| |
Oswald
Registered: Apr 2002 Posts: 5094 |
screen produced:
|
| |
JackAsser
Registered: Jun 2002 Posts: 2014 |
Quote: nice, that explains why vsp always seemed to eat away one char row for me, thank you :) I always thought only dec has effect and inc just restores the value.
more questions:
- why is the fli bug teared up horizontally
- why it ends up on the left side on screen
- where do chars come from on top row, left from the fli bug?
- why is the fli bug teared up horizontally
Dunno
- why it ends up on the left side on screen
Dunno
- where do chars come from on top row, left from the fli bug?
It's the last bad line fetch from the previous frame. Try the following to illustrate:
> 7c0 00 01 02 03 04 05 06 07 08 09 0a 0b 0c 0d 0e 0f 10 11 12 13 14 15 16 17 18 19 1a 1b 1c 1d 1e 1f 20 21 22 23 24 25 26 27
|
Previous - 1 | 2 - Next |