Jump to content

StinkerB06

Members
  • Content Count

    56
  • Joined

  • Last visited

Community Reputation

24 Excellent

Recent Profile Visitors

235 profile views
  1. The VERA has PSG registers located from $1F9C0 to $1F9FF. I think the best solution is to have the PETSCII character set moved to $1F000, so that bank 0 now holds enough capacity for 64 KB worth of tiles. $1F9C0 onwards has no longer been general-purpose video memory ever since the VERA 0.9 changes got put in place. Palette and sprite registers used to be in separate bins, but now they hog the very end of VRAM.
  2. 2 out of 256 bytes? Doesn't sound like very much to me! Those are the same addresses as the 6510's I/O direction and data registers, itself is used in the C64. Oh, if I remember, ZP locations $02 to $7F are allowed to be used by the user, locations $80 to $FF are used by the kernel. $02 to $21 supposedly are designed to be sixteen virtual 16-bit registers (or 32 8-bit registers, since changing values in memory must be done on a byte-by-byte basis). You can see these defined within @SlithyMatt's assembly code.
  3. Also, I see you use a BRA instruction in your code, which is on the 65C02 but not the original.
  4. I mean, some assemblers use/support INA and DEA for consistency with the X and Y equivalents, but those aren't official.
  5. The RPi400 is to 2020 as the Sinclair ZX81 is to the late 70's.
  6. It's possible to use the carry flag as a 1-bit argument.
  7. Have you ever seen the FAQ page? It says "WDC 65C02S @ 8 MHz".
  8. AMAZING JOB!!!!!! This likely wouldn't be reliable for use in an actual game though, considering how CPU-intensive synthesizing PCM audio on the fly is. If you want to reduce the CPU usage though, have you thought about using some of the additional 65C02 instructions? All of them are said to be compatible with R38.
  9. I have another version that does a dummy read: rewindChannelNumber: LDY $9F22 ; Save ADDRx_H and auto-indexing factor LDA $9F25 ; Retrieve CTRL register AND #$01 ; Mask all but the ADDRSEL bit TAX ; Put in X index register LDA #$38 STA $9F22 ; Decrement=4 LDA $9F23,X ; Do the dummy read and decrement (Can you give a clue why I used an index register?) STY $9F22 ; Restore ADDRx_H and auto-indexing factor RTS This one probably is less efficient, but it only takes 1 label instead of 2.
  10. Yep! After the code is executed, ADDR0 points to $1F9C4, which is the start of the 2nd channel. So you'll need to manually rewind it by 4: rewindChannelNumber: LDA $9F20 ; Retrieve ADDRx_L BEQ rewindChannel16 ; Skip this if zero SEC SBC #4 ; Subtract 4 STA $9F20 ; We're done RTS rewindChannel16: DEC $9F21 ; If past 16th channel, decrement ADDRx_M LDA #$FC STA $9F20 ; ADDRx=$1F9FC RTS
  11. Why are you re-setting $9F20 every byte written? You could just use the VERA's auto-increment feature. Here, this code should work better: STZ $9F25 ; ADDRSEL=0, DCSEL=0 LDA #$C0 STA $9F20 ; ADDR0=$xxxC0 LDA #$F9 STA $9F21 ; ADDR0=$xF9C0 LDA #$11 STA $9F22 ; ADDR0=$1F9C0, Increment=1 LDA #$4A STA $9F23 ; Frequency=$xx4A LDA #$04 STA $9F23 ; Frequency=$044A LDA #$FF STA $9F23 ; Volume=63, Left=1, Right=1 LDA #$3F STA $9F23 ; Duty=50%, Waveform=Square
  12. Also, don't forget the "LDA #0 / STA addr" combo can be replaced with "STZ addr" on the 65C02.
×
×
  • Create New...

Important Information

Please review our Terms of Use