Class representing a mock implementation of the IFrontPanel interface used for testing.

Implements

Constructors

  • Parameters

    • wireWidth: number

      The width of the mock WireIn and WireOut endpoints, measured in bits.

    • triggerVectorWidth: number

      The width of the mock TriggerOut vectors, measured in bits.

    Returns MockFrontPanel

Properties

_RegisterBlock: MockDataBlock
_TriggerOutVectors: MockDataBlock
_WireInBlock: MockDataBlock
_WireOutBlock: MockDataBlock
PIPEIN_ADDRESS_RANGE: AddressRange = ...

Address range for PipeIn endpoints.

PIPEOUT_ADDRESS_RANGE: AddressRange = ...

Address range for PipeOut endpoints

REGISTER_ADDRESS_RANGE: AddressRange = ...

Address range for Register endpoints

TRIGGERIN_ADDRESS_RANGE: AddressRange = ...

Address range for TriggerIn endpoints.

TRIGGEROUT_ADDRESS_RANGE: AddressRange = ...

Address range for TriggerOut endpoints.

WIREIN_ADDRESS_RANGE: AddressRange = ...

Address range for WireIn endpoints.

WIREOUT_ADDRESS_RANGE: AddressRange = ...

Address range for WireOut endpoints.

Accessors

  • get RegisterBlock(): MockDataBlock
  • The Register data block

    Returns MockDataBlock

  • get TriggerOutBlock(): MockDataBlock
  • The TriggerOut data block

    Returns MockDataBlock

  • get WireInBlock(): MockDataBlock
  • The WireIn data block

    Returns MockDataBlock

  • get WireOutBlock(): MockDataBlock
  • The WireOut data block

    Returns MockDataBlock

Methods

  • Activates the mock TriggerIn endpoint at the specified address and bit.

    Parameters

    • address: number

      The address of the mock TriggerIn vector.

    • bit: number

      The bit to activate.

    Returns Promise<void>

    • A promise that resolves when the mock TriggerIn endpoint has been activated.
  • Gets the mock TriggerOut vector at the specified address.

    Parameters

    • address: number

      The address of the mock TriggerOut vector.

    Returns Promise<number>

    • A promise that resolves to the mock TriggerOut vector.
  • Gets the value of the mock WireIn endpoint at the specified address.

    Parameters

    • address: number

      The address of the WireIn endpoint.

    Returns Promise<number>

    • A promise that resolves to the value of the mock WireIn endpoint.
  • Gets the value of the mock WireOut endpoint at the specified address.

    Parameters

    • address: number

      The address of the wire out.

    Returns Promise<number>

    • A promise that resolves to the value of the wire out.
  • Checks if the mock TriggerOut endpoint at the specified address is active by applying the mask.

    Parameters

    • address: number

      The address of the mock TriggerOut vector.

    • mask: number

      The mask to apply to the mock TriggerOut vector.

    Returns Promise<boolean>

    • A promise that resolves to true if the TriggerOut endpoint is active, or false otherwise.
  • Reads data from the mock PipeOut endpoint at the specified address.

    Parameters

    • _address: number
    • _length: number

    Returns Promise<ArrayBuffer>

    • A promise that resolves to the data that was read.
  • Reads the value of the mock Register at the specified address.

    Parameters

    • address: number

      The address of the mock Register.

    Returns Promise<number>

    • A promise that resolves to the value of the mock Register.
  • Sets the value of the mock WireIn endpoint at the specified address.

    Parameters

    • address: number

      The address of the mock WireIn endpoint.

    • value: number

      The value to set.

    • mask: number

      The mask to apply to the value.

    Returns Promise<void>

    • A promise that resolves when the value has been set.
  • Updates all mock TriggerOut vectors.

    Returns Promise<void>

    • A promise that resolves when all mock TriggerOut vectors have been updated.
  • Updates all mock WireIn endpoints.

    Returns Promise<void>

    • A promise that resolves when all mock WireIn endpoints have been updated.
  • Updates all mock WireOut endpoints.

    Returns Promise<void>

    • A promise that resolves when all mock WireOut endpoints have been updated.
  • Writes a value to the mock Register at the specified address.

    Parameters

    • address: number

      The address of the mock Register.

    • value: number

      The value to write.

    Returns Promise<void>

    • A promise that resolves when the value has been written.
  • Writes data to the mock PipeIn endpoint at the specified address.

    Parameters

    Returns Promise<void>

    • A promise that resolves when the data has been written.

Generated using TypeDoc