D0InputOutput.mesa
Copyright © 1985 by Xerox Corporation. All rights reserved.
McJones on: May 15, 1980 10:54 AM)
Birrell, November 2, 1983 4:05 pm
Russ Atkinson (RRA) February 19, 1985 2:59:34 pm PST
Doug Wyatt, February 22, 1985 4:30:00 pm PST
DIRECTORY
PrincOps USING [zMISC];
D0InputOutput: DEFINITIONS
= BEGIN
Support for D0 heads (device face implementations)
ControllerNumber: TYPE = [0..16); -- controller number = task number = CSB number
nullControllerNumber: ControllerNumber = 0; -- not a valid I/O controller number
ControllerType: TYPE = [0..377B]; -- Hardware-defined controller type code
iutfp: ControllerType = 001B; -- Interim User Terminal, Full Page
utvfc: ControllerType = 002B; -- User Terminal Variable Format Controller
rdc: ControllerType = 003B; -- Rigid Disk Controller
irdc: ControllerType = 004B; -- Interim Rigid Disk Controller
rdcWithServiceLate: ControllerType = 005B; -- RDC has status bits in ID register!
ethernet1Out: ControllerType = 006B; -- Ethernet-1 output
ethernet1In: ControllerType = 007B; -- Ethernet-1 input
eim: ControllerType = 010B; -- Electronic Input Module (RIS)
idc: ControllerType = 011B; -- Imaginal Disk Controller (CDC disk)
uibScb: ControllerType = 012B; -- User Interface Board / System Control Board
fdc: ControllerType = 013B; -- Floppy Disk Controller
ethernetOut: ControllerType = 014B; -- Ethernet-2 output
ethernetIn: ControllerType = 015B; -- Ethernet-2 input
eomHigh: ControllerType = 016B; -- Electronic Output Module (ROS) - higher priority section
eomLow: ControllerType = 017B; -- Electronic Output Module (ROS) - lower priority section
mioc: ControllerType = 020B; -- Miscellaneous I/O Controller
cmtc: ControllerType = 021B; -- Computer Magnetic Tape Controller
colorDisplay: ControllerType = 257B; -- Color display controller
null: ControllerType = 377B; -- no controller present
GetNextController:
PROC [type: ControllerType, prev: ControllerNumber ← nullControllerNumber]
RETURNS [next: ControllerNumber];
Stateless enumeration of controllers of given type; enumeration begins and ends with nullControllerNumber.
NOTE: When multiple controllers of a given type are present, they are enumerated in order of DECREASING priority (highest controller number first).
CSB: TYPE = ARRAY [0..16) OF WORD;
CSBArray: TYPE = ARRAY[0..16) OF CSB;
IOPage: READONLY LONG POINTER TO CSBArray;
IOAddress:
TYPE =
MACHINE
DEPENDENT
RECORD [
zero: [0..377B] ← 0,
controller: ControllerNumber,
register: [0..17B]
];
Input:
PROC [IOAddress]
RETURNS [
WORD] =
MACHINE
CODE { PrincOps.zMISC, 5 };
Read one word from specified controller register.
Output:
PROC [datum:
WORD, register: IOAddress] =
MACHINE
CODE { PrincOps.zMISC, 6 };
Write one word to specified controller register.
millisecondsPerTick:
CARDINAL;
Exported from ProcessorHeadD0 to UserTerminalHeadD0 to set the process tick rate.
END.
LOG
Time: August 7, 1979 12:05 PM By: Redell Action: Create file
Time: February 4, 1980 7:10 PM By: McJones Action: Remove RegisterDevice, DeviceHandle, DeviceNumber; change ControllerNumber from 8 to 4 bits; add nullControllerNumber
Time: May 15, 1980 10:54 AM By: McJones Action: Add Input, Output, IOAddress; rename Ethernet controller types
Time: November 2, 1983 4:05 pm By: Birrell Action: conversion to 5.0