Documentation ¶
Index ¶
Constants ¶
View Source
const ( FC byte = 0x01 FN byte = 0x02 FP byte = 0x04 FX byte = 0x08 FH byte = 0x10 FY byte = 0x20 FZ byte = 0x40 FS byte = 0x80 )
The Flag registers, F and F', supply information to the user about the status of the Z80 CPU at any particular time.
7 6 5 4 3 2 1 0 S Z Y H X P N C
S = sign, Z = zero, H = half carry, P = parity/overflow, N = add/substract, C = carry
X and Y flags are undocumented.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CPUState ¶
type CPUState struct {
AF, BC, DE, HL uint16 // standard registers
AF_, BC_, DE_, HL_ uint16 // shadow registers
IX, IY uint16
PC, SP uint16
I, R, IM byte
IFF1, IFF2 bool
}
CPU state that can be loaded or saved
type TCounter ¶
type TCounter struct { Total int64 // total T states since boot or hard reset Current int // T states for the current frame // contains filtered or unexported fields }
Provides T states counters
type Z80 ¶
type Z80 struct { IOBus IOBus Reg *registers // registers TC *TCounter // T states counter Trap func() // traps to execute on PC address // contains filtered or unexported fields }
Represents emulated Z80 Z80
Source Files ¶
Click to show internal directories.
Click to hide internal directories.