C# Class NesHd.Core.Memory.Memory

The main class for memory including RAM, IO, SRAM and PRG
显示文件 Open project: afonsof/nes-hd Class Usage Examples

Public Properties

Property Type Description
JoyData1 int
JoyData2 int
JoyStrobe byte
WriteOnRam bool
Zapper NesHd.Core.Input.Zapper

Public Methods

Method Description
LoadCart ( string romPath ) : bool
Memory ( NesEngine engine ) : NesHd.Core.Debugger
Read ( ushort address ) : byte

Read a value from the memory at a specific address

Read16 ( ushort address ) : ushort

Read an address from the memory

Write ( ushort address, byte value ) : byte

Write a value into the memory at the specific address

Private Methods

Method Description
InitializeMemory ( ) : void

Initialize and clear the memory

Method Details

LoadCart() public method

public LoadCart ( string romPath ) : bool
romPath string
return bool

Memory() public method

public Memory ( NesEngine engine ) : NesHd.Core.Debugger
engine NesEngine
return NesHd.Core.Debugger

Read() public method

Read a value from the memory at a specific address
public Read ( ushort address ) : byte
address ushort The address to read from
return byte

Read16() public method

Read an address from the memory
public Read16 ( ushort address ) : ushort
address ushort
return ushort

Write() public method

Write a value into the memory at the specific address
public Write ( ushort address, byte value ) : byte
address ushort
value byte
return byte

Property Details

JoyData1 public_oe property

public int JoyData1
return int

JoyData2 public_oe property

public int JoyData2
return int

JoyStrobe public_oe property

public byte JoyStrobe
return byte

WriteOnRam public_oe property

public bool WriteOnRam
return bool

Zapper public_oe property

public Zapper,NesHd.Core.Input Zapper
return NesHd.Core.Input.Zapper