DIRECTORY Core, CoreFlat, CoreOps, Ports, PW, Rope, Rosemary, RosemaryUser, Sisyph; PriorityEncoderTest: CEDAR PROGRAM IMPORTS CoreOps, Ports, PW, RosemaryUser, Sisyph = BEGIN EncoderTestProc: RosemaryUser.TestProc = { CycleEncoder: PROC = { Pulse: TYPE = [0..10); lD0: ARRAY Pulse OF Ports.Level _ [X, L, X, X, X, X, X, X, X, H]; lD1: ARRAY Pulse OF Ports.Level _ [X, L, X, X, X, X, X, X, H, L]; lD2: ARRAY Pulse OF Ports.Level _ [X, L, X, X, X, X, X, H, L, L]; lD3: ARRAY Pulse OF Ports.Level _ [X, L, X, X, X, X, H, L, L, L]; lD4: ARRAY Pulse OF Ports.Level _ [X, L, X, X, X, H, L, L, L, L]; lD5: ARRAY Pulse OF Ports.Level _ [X, L, X, X, H, L, L, L, L, L]; lD6: ARRAY Pulse OF Ports.Level _ [X, L, X, H, L, L, L, L, L, L]; lD7: ARRAY Pulse OF Ports.Level _ [X, H, L, L, L, L, L, L, L, L]; lEin: ARRAY Pulse OF Ports.Level _ [L, H, H, H, H, H, H, H, H, H]; lO0: ARRAY Pulse OF Ports.Level _ [L, L, H, L, H, L, H, L, H, L]; lO1: ARRAY Pulse OF Ports.Level _ [L, L, H, H, L, L, H, H, L, L]; lO2: ARRAY Pulse OF Ports.Level _ [L, L, H, H, H, H, L, L, L, L]; lGS: ARRAY Pulse OF Ports.Level _ [L, L, H, H, H, H, H, H, H, H]; lEout: ARRAY Pulse OF Ports.Level _ [L, H, L, L, L, L, L, L, L, L]; FOR pulse: Pulse IN Pulse DO p[D0].l _ lD0[pulse]; p[D1].l _ lD1[pulse]; p[D2].l _ lD2[pulse]; p[D3].l _ lD3[pulse]; p[D4].l _ lD4[pulse]; p[D5].l _ lD5[pulse]; p[D6].l _ lD6[pulse]; p[D7].l _ lD7[pulse]; p[Ein].l _ lEin[pulse]; p[O0].l _ lO0[pulse]; p[O1].l _ lO1[pulse]; p[O2].l _ lO2[pulse]; p[GS].l _ lGS[pulse]; p[Eout].l _ lEout[pulse]; Eval[]; ENDLOOP; }; --CycleEncoder p[D0].l _ p[D1].l _ p[D2].l _ p[D3].l _ p[D4].l _ p[D5].l _ p[D6].l _ p[D7].l _ p[Ein].l _ L; p[O0].l _ p[O1].l _ p[O2].l _ p[GS].l _ p[Eout].l _ L; CycleEncoder[]; }; --EncoderTestProc designName: Rope.ROPE = "///Users/gunther.pa/chips/IOPInterruptController"; testee: Rope.ROPE = "8-3PriorityEncoder.sch"; viewerName: Rope.ROPE = "Priority Encoder"; ct: Core.CellType _ Sisyph.ExtractSchematicByName[testee, Sisyph.Create[PW.OpenDesign[designName]]]; D0: NAT = CoreOps.GetWireIndex[ct.public, "Data0"]; D1: NAT = CoreOps.GetWireIndex[ct.public, "Data1"]; D2: NAT = CoreOps.GetWireIndex[ct.public, "Data2"]; D3: NAT = CoreOps.GetWireIndex[ct.public, "Data3"]; D4: NAT = CoreOps.GetWireIndex[ct.public, "Data4"]; D5: NAT = CoreOps.GetWireIndex[ct.public, "Data5"]; D6: NAT = CoreOps.GetWireIndex[ct.public, "Data6"]; D7: NAT = CoreOps.GetWireIndex[ct.public, "Data7"]; Ein: NAT = CoreOps.GetWireIndex[ct.public, "InEnable"]; O0: NAT = CoreOps.GetWireIndex[ct.public, "Out0"]; O1: NAT = CoreOps.GetWireIndex[ct.public, "Out1"]; O2: NAT = CoreOps.GetWireIndex[ct.public, "Out2"]; GS: NAT = CoreOps.GetWireIndex[ct.public, "GroupSelect"]; Eout: NAT = CoreOps.GetWireIndex[ct.public, "OutEnable"]; FOR i: NAT IN [0..ct.public.size) DO [] _ Ports.InitPort[wire: ct.public[i]]; ENDLOOP; [] _ Ports.InitTesterDrive[wire: ct.public[D0], initDrive: force]; [] _ Ports.InitTesterDrive[wire: ct.public[D1], initDrive: force]; [] _ Ports.InitTesterDrive[wire: ct.public[D2], initDrive: force]; [] _ Ports.InitTesterDrive[wire: ct.public[D3], initDrive: force]; [] _ Ports.InitTesterDrive[wire: ct.public[D4], initDrive: force]; [] _ Ports.InitTesterDrive[wire: ct.public[D5], initDrive: force]; [] _ Ports.InitTesterDrive[wire: ct.public[D6], initDrive: force]; [] _ Ports.InitTesterDrive[wire: ct.public[D7], initDrive: force]; [] _ Ports.InitTesterDrive[wire: ct.public[Ein], initDrive: force]; [] _ Ports.InitTesterDrive[wire: ct.public[O0], initDrive: expect]; [] _ Ports.InitTesterDrive[wire: ct.public[O1], initDrive: expect]; [] _ Ports.InitTesterDrive[wire: ct.public[O2], initDrive: expect]; [] _ Ports.InitTesterDrive[wire: ct.public[GS], initDrive: expect]; [] _ Ports.InitTesterDrive[wire: ct.public[Eout], initDrive: expect]; [] _ RosemaryUser.TestProcedureViewer[ cellType: ct, testButtons: LIST["Encoder Test"], name: viewerName, displayWires: LIST[NEW[CoreFlat.FlatWireRec _ [path: CoreFlat.NullPath, wire: ct.public]]], flatten: TRUE ]; END. $PriorityEncoderTest.mesa Copyright c 1986 by Xerox Corporation. All rights reserved. Created by Neil Gunther, August 8, 1986 11:02:28 am PDT Last Edited by: Neil Gunther August 8, 1986 3:59:10 pm PDT Truth Table -- Inputs -- -- Outputs -- -- Inputs -- -- Outputs -- -- Simulation -- Κ ˜™Icodešœ Οmœ1™