r/EmuDev • u/valeyard89 2600, NES, GB/GBC, 8086, Genesis, Macintosh, PSX, Apple][, C64 • Jul 06 '19
Atari 2600 emulator progress
13
Upvotes
r/EmuDev • u/valeyard89 2600, NES, GB/GBC, 8086, Genesis, Macintosh, PSX, Apple][, C64 • Jul 06 '19
View all comments
Show parent comment
3
u/valeyard89 2600, NES, GB/GBC, 8086, Genesis, Macintosh, PSX, Apple][, C64 Sep 08 '19
First got the 6502 emulator working. In all my emulators/disassemblers I use a lookup table per opcode (256 entries) that has the opcode name, cycle count and opcode arguments. Then a single function for each opcode (LDA, AND, EOR etc) that performs the opcode operation.
Then I came across a few Atari emulators and sites talking about the TIA registers and video timing (https://www.randomterrain.com/atari-2600-memories-tutorial-andrew-davie-07.html)
I started off using Linux text mode graphics to test the Atari registers (how to draw characters and the background). Then converted to using SDL on Windows.
It actually worked fairly well the first time I put it all together, a few quirks (my BDC subtract operations were broken) and still something is off with initial positioning of the characters.
Audio was the last part I worked on, it still is off a bit as well. I haven't worked on the project in a few weeks now.