Documentation ¶
Overview ¶
Decimal Mode Not Implemented -- doesn't exist in NES
Index ¶
- Constants
- Variables
- type AddressGetter
- type CPU
- type Executer
- func ADC(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func AND(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func ASL(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func BCC(address, instructionLength, operand uint16, cycles int) Executer
- func BCS(address, instructionLength, operand uint16, cycles int) Executer
- func BEQ(address, instructionLength, operand uint16, cycles int) Executer
- func BIT(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func BMI(address, instructionLength, operand uint16, cycles int) Executer
- func BNE(address, instructionLength, operand uint16, cycles int) Executer
- func BPL(address, instructionLength, operand uint16, cycles int) Executer
- func BRK(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func BVC(address, instructionLength, operand uint16, cycles int) Executer
- func BVS(address, instructionLength, operand uint16, cycles int) Executer
- func CLC(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func CLD(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func CLI(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func CLV(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func CMP(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func CPX(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func CPY(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func DCP(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func DEC(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func DEX(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func DEY(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func EOR(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func Execution(opcodes []*Opcode) []Executer
- func INC(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func INX(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func INY(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func ISB(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func JMP(get AddressGetter, address, instructionLength, operand uint16, cycles int) Executer
- func JSR(get AddressGetter, address, instructionLength, operand uint16, cycles int) Executer
- func LAX(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func LDA(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func LDX(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func LDY(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func LSR(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func NOP(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func NOPGET(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func ORA(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func PHA(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func PHP(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func PLA(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func PLP(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func RLA(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func ROL(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func ROR(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func RRA(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func RTI(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func RTS(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func SAX(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func SBC(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func SEC(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func SED(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func SEI(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func SLO(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func SRE(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func STA(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func STX(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func STY(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func TAX(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func TAY(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func TSX(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func TXA(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func TXS(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- func TYA(get Getter, set Setter, address, instructionLength, operand uint16, cycles int) Executer
- type Flags
- type Getter
- type Opcode
- func (o *Opcode) Address() uint16
- func (o *Opcode) AddressGet(c *CPU) (uint16, bool)
- func (o *Opcode) AddressMode() int
- func (o *Opcode) Bytes() string
- func (o *Opcode) Cycles() int
- func (o *Opcode) Disassemble() string
- func (o *Opcode) Executer() Executer
- func (o *Opcode) Get(c *CPU) byte
- func (o *Opcode) GetValueAt(c *CPU) string
- func (o *Opcode) Instruction() string
- func (o *Opcode) Opcode() []*byte
- func (o *Opcode) Operand() uint16
- func (o *Opcode) Operands() string
- type Registers
- type Setter
Constants ¶
View Source
const ( AddressImmediate int = iota AddressZeroPage AddressZeroPageX AddressZeroPageY AddressAbsolute AddressAbsoluteX AddressAbsoluteY AddressImplied AddressAccumulator AddressIndirect AddressIndirectWrong AddressIndirectX AddressIndirectY AddressRelative AddressAddress )
Variables ¶
View Source
var ErrorUnknownAddressMode = errors.New("Unknown Addressing Mode")
View Source
var ErrorUnknownInstruction = errors.New("Unknown Instruction")
Functions ¶
This section is empty.
Types ¶
type AddressGetter ¶
type CPU ¶
type Executer ¶
func JMP ¶
func JMP(get AddressGetter, address, instructionLength, operand uint16, cycles int) Executer
func JSR ¶
func JSR(get AddressGetter, address, instructionLength, operand uint16, cycles int) Executer
type Flags ¶
type Opcode ¶
type Opcode struct {
// contains filtered or unexported fields
}
func Decompile ¶
Decompile will Read each address in memory as though it could be executed. This will produce many indvalid opcodes, but doesn't require us to differentiate between instructions and data ahead of time. Any invalid opcodes will result in a "nop". Hopefully the code never jumps to them :) Perhaps we should put a panicking instruction to suss these out.
func (*Opcode) AddressMode ¶
func (*Opcode) Disassemble ¶
func (*Opcode) GetValueAt ¶
func (*Opcode) Instruction ¶
Click to show internal directories.
Click to hide internal directories.