Search found 7 matches
- Mon Feb 04, 2019 7:09 pm
- Forum: Newbie Help Center
- Topic: changing the background colour
- Replies: 15
- Views: 9101
Re: changing the background colour
Hey guys I got it to work, thanks for the help everyone!! My next quest is to display a sprite on the screen :) Here is the code, remember to write in vectors lmao! .segment "HEADER" .byte "NES" .byte $1a .byte $02 .byte $01 .byte %00000000 .byte $00 .byte $00 .byte $00 .byte $00...
- Thu Jan 31, 2019 5:34 pm
- Forum: Newbie Help Center
- Topic: changing the background colour
- Replies: 15
- Views: 9101
Re: changing the background colour
hey guys so this is the PPU code now ; ----------------------------------------------------------- BIT $2002 ; checks for clear vblank flag -> PPU WARM UP Wait1: BIT $2002 ; read vblank flag BPL Wait1 ; keep reading until vblank flag is set Wait2: BIT $2002 ; read the vblank flag BPL Wait2 ; keep re...
- Thu Jan 31, 2019 3:02 pm
- Forum: Newbie Help Center
- Topic: changing the background colour
- Replies: 15
- Views: 9101
Re: changing the background colour
Ok so i took a shot at initializing nametable 0, not sure if im doing it right. No assembler errors though :) LDA #%00000000 ; init nametable 0? STA $2000 LDA #$20 STA $2006 LDA #$00 STA $2006 I stored #%00000000 into 2000 because i guess that sets off the nametable 0 flag and then i wrote #$20 and ...
- Tue Jan 29, 2019 6:31 pm
- Forum: Newbie Help Center
- Topic: changing the background colour
- Replies: 15
- Views: 9101
Re: changing the background colour
.segment "CODE" WaitVblank: : BIT $2002 BPL :- RTS ; ----------------------------------------------------------- Reset: ; reset routine SEI CLD LDX #$00 ; turn of screen STX $2000 STX $2001 DEX TXS LDX #0 TXA JSR WaitVblank ClearMemory: ; clr mem b/c old memory may be left on reset LDA #$...
- Tue Jan 29, 2019 4:42 pm
- Forum: Newbie Help Center
- Topic: changing the background colour
- Replies: 15
- Views: 9101
Re: changing the background colour
; ----------------------------------------------------------- BIT $2002 ; checks for clear vblank flag -> PPU WARM UP Wait1: BIT $2002 ; read vblank flag BPL Wait1 ; keep reading until vblank flag is set Wait2: BIT $2002 ; read the vblank flag -> # typo? @tokumaru BPL Wait2 ; keep reading until it'...
- Tue Jan 29, 2019 4:06 pm
- Forum: Newbie Help Center
- Topic: changing the background colour
- Replies: 15
- Views: 9101
Re: changing the background colour
LDA #$3F STA $2006 LDA #$00 STA $2006 STA $2007 You shouldn't write to the PPU unless you are in vertical blank period, or the screen is off. Probably should go before the write to 2001. Do you understand what 2006 and 2007 do? or why this might change the BG to gray? CLI Don't turn interrupts on, ...
- Tue Jan 29, 2019 2:50 pm
- Forum: Newbie Help Center
- Topic: changing the background colour
- Replies: 15
- Views: 9101
changing the background colour
Hey guys, I'm new to assembly and nes programming, after watching a few tutorials, copying and pasting their code into VIM I have made this mess: .segment "HEADER" .byte "NES" .byte $1a .byte $02 .byte $01 .byte %00000000 .byte $00 .byte $00 .byte $00 .byte $00 .byte $00,$00,$00,...