Re: Aw: Re: Aw: Re: [stella] Hm...

Subject: Re: Aw: Re: Aw: Re: [stella] Hm...
From: Christopher Tumber <christophertumber@xxxxxxxxxx>
Date: Thu, 08 Apr 2004 12:07:27 -0400
>Maybe the problem can be simplified by redesigning the board a little. Currently the third color is required here:

Maybe I'm missing something here - Why is this a big deal?

Do you need more free cycles per scanline to draw the pieces? The attached board is using 4 cycle/12 pixel squares, I started with 3 cycle/9 pixel squares but this fills out the screen better. However, if you need the time back you can switch back to regular sta COLUBK from sta.w COLUBK.

Wait, are you using some variant of the 6-digit display to draw the pieces? Okay, that would be a problem...

Anyway...

Chris...

Attachment: Archon.bin
Description: Binary data

	processor 6502
	include vcs.h




 SEG.U   variables
 org $80






    SEG     Bank0

    org $F000


Start:

      SEI  ; Disable interrupts, if there are any.
      CLD  ; Clear BCD math bit.

      LDX  #$FF
      TXS  ; Set stack to beginning.

      LDA #0
B1    STA 0,X
      DEX
      BPL B1




MainLoop
VerticalBlank  ;*********************** VERTICAL BLANK HANDLER



	LDA  #2
	STA  VSYNC ;Begin vertical sync.
	STA  WSYNC ; First line of VSYNC
	STA  WSYNC ; Second line of VSYNC.

	LDA  #43
	STA  TIM64T
	LDA  #0
;	STA  CXCLR
	STA  WSYNC ; Third line of VSYNC.
	STA  VSYNC ; (0)







     lda #0
     sta COLUBK
     lda #$1e
     sta COLUPF
     lda #0
     sta PF1
     sta PF0
     sta PF2
     lda #1
     sta CTRLPF

DrawScreen ;**************************** SCREEN DRAWING ROUTINES
      LDA INTIM
      BNE DrawScreen 
      STA WSYNC
      STA VBLANK  

      ldy #29
nextA:
      sta WSYNC
      dey
      bpl nextA


      
      sta WSYNC
      lda #63
      sta PF1
      lda #255
      sta PF2
      sta WSYNC
      sta WSYNC
      sta WSYNC
      sta WSYNC
      sta WSYNC
      sta WSYNC
      nop
      nop
      nop
      nop
      nop
      nop
      nop
      nop
      nop
      nop
      nop
      nop
      nop
      nop
      nop
      nop
      nop
      nop
      nop
      nop
      nop
      nop
      nop
      nop
      nop
      nop
      nop
      nop
      lda #0
      sta PF2
      lda #32
      sta PF1
     

      sta WSYNC
      jsr Row1
      sta WSYNC
      jsr Row1
      sta WSYNC
      jsr Row1
      sta WSYNC
      jsr Row1
      sta WSYNC
      jsr Row1
      sta WSYNC
      jsr Row1
      sta WSYNC
      jsr Row1
      sta WSYNC
      jsr Row1
      sta WSYNC
      jsr Row1
      sta WSYNC
      jsr Row1
      sta WSYNC
      jsr Row1
      sta WSYNC
      jsr Row1
      sta WSYNC
      jsr Row1
      sta WSYNC
      jsr Row1



      sta WSYNC
      jsr Row2
      sta WSYNC
      jsr Row2
      sta WSYNC
      jsr Row2
      sta WSYNC
      jsr Row2
      sta WSYNC
      jsr Row2
      sta WSYNC
      jsr Row2
      sta WSYNC
      jsr Row2
      sta WSYNC
      jsr Row2
      sta WSYNC
      jsr Row2
      sta WSYNC
      jsr Row2
      sta WSYNC
      jsr Row2
      sta WSYNC
      jsr Row2
      sta WSYNC
      jsr Row2
      sta WSYNC
      jsr Row2



      sta WSYNC
      jsr Row3
      sta WSYNC
      jsr Row3
      sta WSYNC
      jsr Row3
      sta WSYNC
      jsr Row3
      sta WSYNC
      jsr Row3
      sta WSYNC
      jsr Row3
      sta WSYNC
      jsr Row3
      sta WSYNC
      jsr Row3
      sta WSYNC
      jsr Row3
      sta WSYNC
      jsr Row3
      sta WSYNC
      jsr Row3
      sta WSYNC
      jsr Row3
      sta WSYNC
      jsr Row3
      sta WSYNC
      jsr Row3


      sta WSYNC
      jsr Row4
      sta WSYNC
      jsr Row4
      sta WSYNC
      jsr Row4
      sta WSYNC
      jsr Row4
      sta WSYNC
      jsr Row4
      sta WSYNC
      jsr Row4
      sta WSYNC
      jsr Row4
      sta WSYNC
      jsr Row4
      sta WSYNC
      jsr Row4
      sta WSYNC
      jsr Row4
      sta WSYNC
      jsr Row4
      sta WSYNC
      jsr Row4
      sta WSYNC
      jsr Row4
      sta WSYNC
      jsr Row4



      sta WSYNC
      jsr Row5
      sta WSYNC
      jsr Row5
      sta WSYNC
      jsr Row5
      sta WSYNC
      jsr Row5
      sta WSYNC
      jsr Row5
      sta WSYNC
      jsr Row5
      sta WSYNC
      jsr Row5
      sta WSYNC
      jsr Row5
      sta WSYNC
      jsr Row5
      sta WSYNC
      jsr Row5
      sta WSYNC
      jsr Row5
      sta WSYNC
      jsr Row5
      sta WSYNC
      jsr Row5
      sta WSYNC
      jsr Row5


      sta WSYNC
      jsr Row4
      sta WSYNC
      jsr Row4
      sta WSYNC
      jsr Row4
      sta WSYNC
      jsr Row4
      sta WSYNC
      jsr Row4
      sta WSYNC
      jsr Row4
      sta WSYNC
      jsr Row4
      sta WSYNC
      jsr Row4
      sta WSYNC
      jsr Row4
      sta WSYNC
      jsr Row4
      sta WSYNC
      jsr Row4
      sta WSYNC
      jsr Row4
      sta WSYNC
      jsr Row4
      sta WSYNC
      jsr Row4



      sta WSYNC
      jsr Row3
      sta WSYNC
      jsr Row3
      sta WSYNC
      jsr Row3
      sta WSYNC
      jsr Row3
      sta WSYNC
      jsr Row3
      sta WSYNC
      jsr Row3
      sta WSYNC
      jsr Row3
      sta WSYNC
      jsr Row3
      sta WSYNC
      jsr Row3
      sta WSYNC
      jsr Row3
      sta WSYNC
      jsr Row3
      sta WSYNC
      jsr Row3
      sta WSYNC
      jsr Row3
      sta WSYNC
      jsr Row3


      sta WSYNC
      jsr Row2
      sta WSYNC
      jsr Row2
      sta WSYNC
      jsr Row2
      sta WSYNC
      jsr Row2
      sta WSYNC
      jsr Row2
      sta WSYNC
      jsr Row2
      sta WSYNC
      jsr Row2
      sta WSYNC
      jsr Row2
      sta WSYNC
      jsr Row2
      sta WSYNC
      jsr Row2
      sta WSYNC
      jsr Row2
      sta WSYNC
      jsr Row2
      sta WSYNC
      jsr Row2
      sta WSYNC
      jsr Row2



      sta WSYNC
      jsr Row1
      sta WSYNC
      jsr Row1
      sta WSYNC
      jsr Row1
      sta WSYNC
      jsr Row1
      sta WSYNC
      jsr Row1
      sta WSYNC
      jsr Row1
      sta WSYNC
      jsr Row1
      sta WSYNC
      jsr Row1
      sta WSYNC
      jsr Row1
      sta WSYNC
      jsr Row1
      sta WSYNC
      jsr Row1
      sta WSYNC
      jsr Row1
      sta WSYNC
      jsr Row1
      sta WSYNC
      jsr Row1

      sta WSYNC
      lda #63
      sta PF1
      lda #255
      sta PF2
      sta WSYNC
      sta WSYNC
      sta WSYNC
      sta WSYNC
      sta WSYNC
      sta WSYNC
      nop
      nop
      nop
      nop
      nop
      nop
      nop
      nop
      nop
      nop
      nop
      nop
      nop
      nop
      nop
      nop
      nop
      nop
      nop
      nop
      nop
      nop
      nop
      nop
      nop
      nop
      nop
      nop

      sta WSYNC
      lda #0
      sta PF2
      sta PF1

      ldy #28
nextB:
      sta WSYNC
      dey
      bpl nextB


      STA VBLANK ; Make TIA output invisible,
      lda #30
      sta TIM64T
OverscanWait:
      lda     INTIM
      bne     OverscanWait

      JMP  MainLoop      ;Continue forever.


Row1:
      lda #0
      ldx #$0e
      ldy #$48      
      sta $2d
      nop
      nop
      nop
      nop
      nop
      nop
      sta.w COLUBK
      stx.w COLUBK
      sta.w COLUBK
      sty.w COLUBK
      sty.w COLUBK
      sty.w COLUBK
      stx.w COLUBK
      sta.w COLUBK
      stx.w COLUBK
      sta.w COLUBK
      rts
Row2:
      lda #0
      ldx #$0e
      ldy #$48      
      sta $2d
      nop
      nop
      nop
      nop
      nop
      nop
      stx.w COLUBK
      sta.w COLUBK
      sty.w COLUBK
      stx.w COLUBK
      sty.w COLUBK
      sta.w COLUBK
      sty.w COLUBK
      stx.w COLUBK
      sta.w COLUBK
      sta.w COLUBK
      rts
Row3:
      lda #0
      ldx #$0e
      ldy #$48      
      sta $2d
      nop
      nop
      nop
      nop
      nop
      nop
      sta.w COLUBK
      sty.w COLUBK
      stx.w COLUBK
      sta.w COLUBK
      sty.w COLUBK
      stx.w COLUBK
      sta.w COLUBK
      sty.w COLUBK
      stx.w COLUBK
      sta.w COLUBK
      rts
Row4:
      lda #0
      ldx #$0e
      ldy #$48      
      sta $2d
      nop
      nop
      nop
      nop
      nop
      nop
      sty.w COLUBK
      stx.w COLUBK
      sta.w COLUBK
      stx.w COLUBK
      sty.w COLUBK
      sta.w COLUBK
      stx.w COLUBK
      sta.w COLUBK
      sty.w COLUBK
      sta.w COLUBK
      rts
Row5:
      lda #0
      ldx #$0e
      ldy #$48      
      sta $2d
      nop
      nop
      nop
      nop
      nop
      nop
      stx.w COLUBK
      sty.w COLUBK
      sty.w COLUBK
      sty.w COLUBK
      sty.w COLUBK
      sty.w COLUBK
      sty.w COLUBK
      sty.w COLUBK
      sta.w COLUBK
      sta.w COLUBK
      rts

	org $FFFC
	.word Start
	.word Start



Current Thread