Lionel Flandrin
859c602d33
Make the instruction cache ignore the region bits.
...
It appears that the tag of the cacheline doesn't keep track of the
region.
2015-09-15 21:27:22 +02:00
Lionel Flandrin
9ab4174942
Gamepad: schedule interrupt even if it's not active.
...
Otherwise we might miss it if the software activates it while the
transaction is pending.
2015-09-14 18:56:40 +02:00
Lionel Flandrin
7d2827b394
Updated readme now that we have gamepad support
2015-09-12 20:46:40 +02:00
Lionel Flandrin
0f2322df8a
Implemented gamepad emulation.
...
The timings are tweaked because it seems our emulator is too fast at
this point: the BIOS attempts to start a new request while the
previous one is still in progress. This will have to be fixed later as
we become more accurate.
Only the original digital controller is supported for now.
The frontend supports keyboard and controllers through SDL2 for input.
2015-09-12 20:34:38 +02:00
Lionel Flandrin
88c132e399
Added README
2015-09-09 22:18:21 +02:00
Lionel Flandrin
3274b4e353
Panic if a game attempts to use the dotclock as timer source
...
It's not implemented yet.
2015-09-02 20:54:59 +02:00
Lionel Flandrin
a26e113a51
Add support for a few GTE registers (CTC2 opcode), reach the BIOS main menu
...
* Added a few GPU commands used to draw the BIOS menu in SCPH-1001.
* Added placeholder code for DMA GPU read (returns 0s)
2015-08-30 17:11:20 +02:00
Lionel Flandrin
79220727b1
Add support for timer "target" interrupt
2015-08-30 17:07:38 +02:00
Lionel Flandrin
dbca7a2025
Ignore writes to the joystick and memory card controller
2015-08-29 21:59:20 +02:00
Lionel Flandrin
227c71f002
Add missing "target_irq" field when reading the timer status register
2015-08-29 00:23:37 +02:00
Lionel Flandrin
7976891a70
Implemented basic CDROM controller support.
...
For now I cheat by pretending that the CD tray is open. This way the
BIOS bails out and doesn't attempt to run the game.
2015-08-24 23:36:32 +02:00
Lionel Flandrin
14db23ccb7
Add temporary check to catch unhandled interrupt configs
2015-08-16 17:13:00 +02:00
Lionel Flandrin
f905862869
Added basic timer support
...
Only free-run mode is implemented, no interrupts.
Using the GPU's dotclock or HSync as a timer source is implemented
although it requires further testing.
2015-08-16 17:09:34 +02:00
Lionel Flandrin
1918e9dc17
Added DMA interrupt
2015-08-04 21:52:50 +02:00
Lionel Flandrin
c44449a08d
Interrupt handling code: only GPU VBlank IRQ supported for now.
...
IRQ_STATUS and IRQ_MASK are supported, all the CPU code should be
there as well: Interrupt Enable, Interrupt Mask, Interrupt Pending
(including software interrupts, only writing to CAUSE is missing).
2015-07-23 23:22:19 +02:00
Lionel Flandrin
6de5dad543
Implement basic GPU timings
2015-07-13 19:50:48 +02:00
Lionel Flandrin
3def356091
Improve error handling in OpenGL code
2015-07-03 12:15:08 +02:00
Lionel Flandrin
f5c6f66c63
Allow BIOS selection on the command line. Recommend SCPH1001.BIN.
...
Fixes #1 and #2
2015-07-01 11:17:05 +02:00
Lionel Flandrin
dd90961982
Implement debugger write watchpoints
2015-06-19 23:10:32 +02:00
Lionel Flandrin
f3702f6311
Implement instruction cache
2015-05-27 21:13:36 +02:00
Lionel Flandrin
77d75c976b
Don't fetch instructions like data, use a separate path.
...
The two paths should be different in order to handle debugging
read/write watchpoints correctly (instruction fetch shouldn't trigger
them). Later on we'll also need different paths to handle the caches
correctly.
2015-05-25 16:27:11 +02:00
Lionel Flandrin
4ebf7ae877
Debugger: Implement read watchpoints
2015-05-25 16:27:11 +02:00
Lionel Flandrin
c8ec4d62d1
Debugger: Implement breakpoints
2015-05-25 16:27:11 +02:00
Lionel Flandrin
8a5b4d2895
Debugger: Implement "step"
2015-05-25 16:27:11 +02:00
Lionel Flandrin
c962afcdb6
Implement "continue" in the debugger
2015-05-25 16:27:11 +02:00
Lionel Flandrin
137a6de830
Implement debugger memory read
2015-05-25 16:27:11 +02:00
Lionel Flandrin
f48fc15fb8
Refactor interconnect to use a generic load/store implementation
...
Instead of having word/halfword/byte implementations for load and
store we have only one generic version. It reduces code duplication
and actually ended up making the code run faster on my computer for
some reason.
2015-05-25 16:27:09 +02:00
Lionel Flandrin
1a4038c156
Added remote GDB support over TCP
...
For now only dumping registers is supported. No memory access or
breakpoints.
2015-05-25 16:26:15 +02:00
Lionel Flandrin
4de6ac4349
Handle SDL events for cleanly exiting the emulator
2015-05-25 16:26:15 +02:00
Lionel Flandrin
415e1eb067
Implement draw offset in OpenGL renderer
2015-05-25 16:26:15 +02:00
Lionel Flandrin
a3092cf793
Implement basic OpenGL renderer using SDL2
2015-05-25 16:26:15 +02:00
Lionel Flandrin
78138b545d
Implement GPU GP1(0x02): Reset Command Buffer
2015-05-25 16:26:15 +02:00
Lionel Flandrin
28d0161119
Implement GPU GP1(0x02): Acknowledge IRQ
2015-05-25 16:26:15 +02:00
Lionel Flandrin
2821bb8069
Implemented placeholder for GP0(0x2C): gp0_quad_texture_blend_opaque
2015-05-25 16:26:15 +02:00
Lionel Flandrin
666d70cce2
Implemented placeholder for GP0(0x30): gp0_triangle_shaded_opaque
2015-05-25 16:26:15 +02:00
Lionel Flandrin
72bb471f89
Implemented placeholder for GP0(0x38): gp0_quad_shaded_opaque
2015-05-25 16:26:15 +02:00
Lionel Flandrin
20c08756c5
Implement placeholder for GP0(0xC0): Image Store
2015-05-25 16:26:15 +02:00
Lionel Flandrin
519f11c40f
Implement GP1(0x03): Display Enable
2015-05-25 16:26:15 +02:00
Lionel Flandrin
de1e0ee3e8
Implement GP0(0xA0): Image Load
2015-05-25 16:26:15 +02:00
Lionel Flandrin
5483ab4853
Ignore GP0(0x01) Clear Cache command
2015-05-25 16:26:15 +02:00
Lionel Flandrin
002b441049
Implement temporary hack to avoid BIOS lockup.
...
At the moment if the vertical resolution is set to 480 lines (bit 19
of GPUSTAT is set) the BIOS deadlocks waiting for bit `31` of the same
GPUSTAT register to flip. To avoid this I lie and pretend the vertical
resolution is always 240 lines.
2015-05-25 16:26:15 +02:00
Lionel Flandrin
caa99b608f
Implemented placeholder for GP0(0x28): gp0_quad_mono_opaque
2015-05-25 16:26:15 +02:00
Lionel Flandrin
08465448ca
GPU GP0: Add support for multi-word commands
2015-05-25 16:26:15 +02:00
Lionel Flandrin
4cfa4efee9
Implement GPU GP1: Display Horizontal and Vertical Range
2015-05-25 16:26:15 +02:00
Lionel Flandrin
72d8fbce12
Implement GPU GP1: Display VRAM Start
2015-05-25 16:26:15 +02:00
Lionel Flandrin
3626b50811
Implement GPU GP0: Mask Bit Setting
2015-05-25 16:26:15 +02:00
Lionel Flandrin
9cc7e49727
Implement GPU GP0: Texture Window
2015-05-25 16:26:15 +02:00
Lionel Flandrin
502fec2f86
Implement GPU GP0: Set Drawing Offset
2015-05-25 16:26:15 +02:00
Lionel Flandrin
61b46bd5da
Fix comments: retreive -> retrieve
2015-05-25 16:26:15 +02:00
Lionel Flandrin
74103f9336
Implement GPU GP0: See Drawing Area
2015-05-25 16:26:15 +02:00