]> Joshua Wise's Git repositories - fpgaboy.git/blame - core/insn_ldx_ahl.v
Move the core to core/
[fpgaboy.git] / core / insn_ldx_ahl.v
CommitLineData
3ad960bd
JW
1`ifdef EXECUTE
2 `INSN_LDx_AHL: begin
3 case (cycle)
5c33c5c0
JW
4 0: if (opcode[3]) // LDx A, (HL)
5 `EXEC_READ(`_HL)
6 else
7 `EXEC_WRITE(`_HL, `_A)
3ad960bd 8 1: begin
5c33c5c0
JW
9 `EXEC_NEWCYCLE
10 `EXEC_INC_PC
3ad960bd
JW
11 end
12 endcase
13 end
14`endif
15
16`ifdef WRITEBACK
17 `INSN_LDx_AHL: begin
18 case (cycle)
19 0: begin /* Type F */ end
20 1: begin
21 if (opcode[3])
5c33c5c0
JW
22 `_A <= rdata;
23 `_HL <= opcode[4] ? // if set, LDD, else LDI
24 (`_HL - 1) :
25 (`_HL + 1);
3ad960bd
JW
26 end
27 endcase
28 end
29`endif
This page took 0.028497 seconds and 4 git commands to generate.