
  { This type declaration defines the structure used by the SCD mode of SCI and the CPU to communicate.
  { This structure must be allocated in a cache bypass memory segment.  All of the RMA fields in this
  { structure are real memory word addresses.

  CONST
    dpc$scd_no_command = 0,
    dpc$scd_abort_output = 1,
    dpc$scd_begin_new_output_list = 2,
    dpc$scd_echo_input = 3,
    dpc$scd_resume_output = 4;

  TYPE
    dpt$scd_communications_block = RECORD
      scd: dpt$scd_data_for_ve,
      ve: dpt$ve_data_for_scd,
      rfu: 0 .. 0ffffffff(16),
      top_line_message_rma: 0 .. 0ffffffff(16),
    RECEND,

    { The first word of the communications block is read by the CPU and written by SCD.  It contains an ID
    { field which SCD increments every time it writes to this word.  The CPU knows SCD has written to this
    { word when the ID changes.  It also contains a three character input buffer.  SCD sends up to three
    { characters of input data from the console to the CPU for processing.  Generally, SCD is much faster
    { then the operator entering input and only one character at a time is actually sent.  The word also
    { contains an RMA to the line that SCD is currently processing.

    dpt$scd_data_for_ve = RECORD
      id: 0 .. 255,
      input_buffer: ARRAY [1 .. 3] OF 0 .. 255,
      current_data_rma: ost$real_memory_address,
    RECEND,

    { This word is read and written by both the CPU and SCD.  This is where the CPU posts the queue of lines
    { to display to SCD.  SCD clears out the command field to indicate that the command is being processed.
    { It contains a command field where the CPU tells SCD what to do with the given data.  SCD clears this
    { field when it has processed the existing command.  The next part of the word contains a boolean that
    { tells SCD to wait until all of the input has been gathered.  The CPU will set this boolean to true when
    { it begins receiving input and then set it to false when all input has been received.  SCD will not do
    { anything with the data until the boolean is set to false.  The last part of the word contains an RMA to
    { the data SCD will display to the console.

    dpt$ve_data_for_scd = RECORD
      command: 0 .. 255,
      hold_display_for_input: boolean,
      unused_1: 0 .. 255,
      unused_2: 0 .. 255,
      console_data_rma: ost$real_memory_address,
    RECEND;

*copyc ost$hardware_subranges
