ROL (ROtate Left) Affects Flags: S Z C MODE SYNTAX HEX LEN TIM Accumulator ROL A $2A 1 2 Zero Page ROL $44 $26 2 5 Zero Page,X ROL $44,X $36 2 6 Absolute ROL $4400 $2E 3 6 Absolute,X ROL $4400,X $3E 3 7
Posted Sat Jun 7, 2003 10:24 AM
ROL (ROtate Left) Affects Flags: S Z C MODE SYNTAX HEX LEN TIM Accumulator ROL A $2A 1 2 Zero Page ROL $44 $26 2 5 Zero Page,X ROL $44,X $36 2 6 Absolute ROL $4400 $2E 3 6 Absolute,X ROL $4400,X $3E 3 7
Posted Sat Jun 7, 2003 10:37 AM
Posted Sat Jun 7, 2003 10:54 AM
Posted Sat Jun 7, 2003 11:26 AM
CLC ROL PATTERN_RIGHT ROL PATTERN_LEFT BCC SCROLLCOMPLETE INC PATTERN_RIGHT SCROLLCOMPLETENearly perfect!
Quote
Posted Sat Jun 7, 2003 12:44 PM
Happy_Dude said:
Thomas Jentzsch said:
Posted Sat Jun 7, 2003 1:16 PM
dew2050 said:
Posted Tue Jun 10, 2003 8:24 PM
Thomas Jentzsch said:
Nature Boy said:
Posted Tue Jun 10, 2003 9:04 PM
Big Player said:
Thomas Jentzsch said:
Nature Boy said:
Posted Wed Jun 11, 2003 1:23 AM
Big Player said:
Posted Wed Jun 11, 2003 6:34 AM
Thomas Jentzsch said:
Posted Sat Jun 14, 2003 10:32 PM
Posted Mon Sep 15, 2003 1:45 AM
Andrew Davie said:
StartOfFrame ; Start of new frame - VBLANK is still ON lda #2 sta VSYNC sta WSYNC sta WSYNC sta WSYNC ; 3 scanlines of VSYNC signal ;------------------------------------------------ ; 37 scanlines of vertical blank... ldx #0 ; Tuning off VSYNC stx VSYNC VerticalBlank sta WSYNC inx ; 2 cpx #37 ; 2 bne VerticalBlank ; 2 ;------------------------------------------------ ; Do 192 scanlines - Begin of the 1st line ldx #0 ; 2 this counts our scanline number stx VBLANK ; 3 and this turns VBLANK off Picture sta WSYNC SLEEP 16 ; H blank - any change here would not be seen lda #$0F ; 2 sta COLUPF ; 3 = 21 adc #$10 ; 2 sta COLUPF ; 3 = 26 adc #$10 ; 2 sta COLUPF ; 3 = 31 adc #$10 ; 2 sta COLUPF ; 3 = 36 adc #$10 ; 2 sta COLUPF ; 3 = 41 adc #$10 ; 2 sta COLUPF ; 3 = 46 adc #$10 ; 2 sta COLUPF ; 3 = 51 adc #$10 ; 2 sta COLUPF ; 3 = 56 adc #$10 ; 2 sta COLUPF ; 3 = 61 adc #$10 ; 2 sta COLUPF ; 3 = 66 inx ; 2 cpx #192 ; 2 bne Picture; 3 ;sta WSYNC ; 3 = 76 ;------------------------------------------------ ; 30 scanlines of overscan... sta WSYNC ; 3 = 75 lda #%01000010 sta VBLANK ; end of screen - enter blanking ldx #0 stx COLUPF Overscan sta WSYNC inx cpx #29 bne Overscan jmp StartOfFrame
Posted Thu Apr 8, 2004 3:27 AM
Posted Thu Apr 8, 2004 3:32 AM
Posted Thu Apr 8, 2004 3:34 AM
Posted Wed Mar 26, 2008 5:28 AM
processor 6502
include "vcs.h"
include "macro.h"
;---------------------------------------------------------------
PATTERN = $80
TIMETOCHANGE = 20
;----------------------------------------------------------------
SEG
ORG $F000
Reset
;Clear RAM and all TIA registers
ldx #0
lda #0
Clear sta 0,x
inx
bne Clear
;----------------------------------------------------------------
; Once-only initialization
lda #0
sta PATTERN
lda #$45
sta COLUPF
ldy #0
;----------------------------------------------------------------
StartOfFrame
; Start of vertical blank processing
lda #0
sta VBLANK
lda #2
sta VSYNC
sta WSYNC
sta WSYNC
sta WSYNC ; 3 scanlines of VSYNC signal
lda #0
sta VSYNC
; 37 scanlines of vertical blank...
ldx #0
VerticalBlank sta WSYNC
inx
cpx #37
bne VerticalBlank
;--------------------------------------------------------------------
;Handle a change in the pattern once every 20 frames
;and write the pattern to the PF1 register
iny
cpy #TIMETOCHANGE
bne notyet
ldy #0
inc PATTERN
notyet
lda PATTERN
sta PF0
sta PF1
;--------------------------------------------------------------------
;--------------------------------------------------------------------
; 192 scanlines of picture...
ldx #$45
stx COLUBK
ldx #0
Picture stx COLUPF
SLEEP 40
lda #$45
sta COLUPF
sta WSYNC
inx
cpx #242
bne Picture
;-------------------------------------------------------------------
lda #%01000010
sta VBLANK ; end of screen - enter blanking
; 30 scanlines of overscan...
ldx #0
Overscan sta WSYNC
inx
cpx #30
bne Overscan
jmp StartOfFrame
ORG $FFFA
.word Reset ; NMI
.word Reset ; RESET
.word Reset ; IRQ
END
0 members, 1 guests, 0 anonymous users