C# Class Ypsilon.Emulation.Processor.YBUS

A representation of a address/data bus that has 16 generic slots. Device in slot zero is YCPU. Other slots can hold devices that inherit from ADevice.
Show file Open project: ZaneDubya/YCPU Class Usage Examples

Public Properties

Property Type Description
CPU YCPU

Public Methods

Method Description
AcknowledgeIRQ ( ushort deviceIndex ) : void
AddDevice ( ADevice device, ushort index ) : void

Adds a device to specified slot index. INDEX MUST BE 1 - 16.

Display ( List textures ) : void
FillROM ( byte rom ) : void
QueryDevice ( ushort deviceIndex ) : ushort[]
RemoveDevice ( ushort index ) : void

Adds a device in the specified slot index. INDEX MUST BE 1 - 16.

Reset ( ) : void

Removes all RAM, ROM, Devices, and any segment references to the same.

SendDeviceMessage ( ushort deviceIndex, ushort param_0, ushort param_1 ) : ushort
SetProviders ( IDisplayProvider display, IInputProvider input ) : void
SetRAM ( uint ramSize ) : void
SetROM ( uint romSize ) : void
Update ( ) : void
YBUS ( YCPU cpu ) : System.Collections.Generic

Private Methods

Method Description
AddSegmentToReferences ( Segment segment ) : void
Device_RaiseIRQ ( ADevice device ) : void
GetDeviceMemoryReference ( Segment segment, ushort deviceIndex ) : void

Returns the byte array of memory attached to the device. Accepts values from 0 - 16. Device 0 is ROM.

GetRAMReference ( Segment segment ) : void
GetROMReference ( Segment segment ) : void

Method Details

AcknowledgeIRQ() public method

public AcknowledgeIRQ ( ushort deviceIndex ) : void
deviceIndex ushort
return void

AddDevice() public method

Adds a device to specified slot index. INDEX MUST BE 1 - 16.
public AddDevice ( ADevice device, ushort index ) : void
device ADevice
index ushort
return void

Display() public method

public Display ( List textures ) : void
textures List
return void

FillROM() public method

public FillROM ( byte rom ) : void
rom byte
return void

QueryDevice() public method

public QueryDevice ( ushort deviceIndex ) : ushort[]
deviceIndex ushort
return ushort[]

RemoveDevice() public method

Adds a device in the specified slot index. INDEX MUST BE 1 - 16.
public RemoveDevice ( ushort index ) : void
index ushort
return void

Reset() public method

Removes all RAM, ROM, Devices, and any segment references to the same.
public Reset ( ) : void
return void

SendDeviceMessage() public method

public SendDeviceMessage ( ushort deviceIndex, ushort param_0, ushort param_1 ) : ushort
deviceIndex ushort
param_0 ushort
param_1 ushort
return ushort

SetProviders() public method

public SetProviders ( IDisplayProvider display, IInputProvider input ) : void
display IDisplayProvider
input IInputProvider
return void

SetRAM() public method

public SetRAM ( uint ramSize ) : void
ramSize uint
return void

SetROM() public method

public SetROM ( uint romSize ) : void
romSize uint
return void

Update() public method

public Update ( ) : void
return void

YBUS() public method

public YBUS ( YCPU cpu ) : System.Collections.Generic
cpu YCPU
return System.Collections.Generic

Property Details

CPU public property

public YCPU,Ypsilon.Emulation.Processor CPU
return YCPU