Basic Raster

Basic and Machine Language

Moderator: Moderators

Leeeeee
soldering master
Posts: 396
Joined: Fri Apr 23, 2004 8:14 am

Post by Leeeeee »

Line 27 waits for near the end of frame so that the effect doesn't retrigger prematurely.

Line 28 positions the effect in the new frame.

IF PEEK(W)<>V GOTO can take too long to execute to wait for a particular line.

Lee.
User avatar
Mike
Herr VC
Posts: 4841
Joined: Wed Dec 01, 2004 1:57 pm
Location: Munich, Germany
Occupation: electrical engineer

Post by Mike »

carlsson wrote:Unless I'm totally confused, it means $9004 will become 0..4 twice per frame in NTSC, 0..55 in PAL [...]
There's no ambiguity here: $9004 contains bits 1..8 of the current raster line, i.e. there's a granularity of two raster lines. Bit 0 is stored within bit 8 of $9003.

Michael
nippur72
de Lagash
Posts: 574
Joined: Thu Sep 07, 2006 8:35 am

Post by nippur72 »

Leeeeee wrote:Line 27 waits for near the end of frame so that the effect doesn't retrigger prematurely.
I can't see how it could retrigger (other than basic code being executed within the same two rasterlines, but it's not the case). Am I missing something?
carlsson
Class of '6502
Posts: 5516
Joined: Wed Mar 10, 2004 1:41 am

Post by carlsson »

Mike wrote:$9004 contains bits 1..8 of the current raster line, i.e. there's a granularity of two raster lines. Bit 0 is stored within bit 8 of $9003.
Ah, ok. Without looking it up, I thought it was the other way around with MSB in $9003.
Anders Carlsson

Image Image Image Image Image
Post Reply