CommonPGA176Impl.mesa
Copyright Ó 1985, 1986, 1987 by Xerox Corporation. All rights reserved.
Louis Monier March 11, 1987 12:59:02 pm PST
Last Edited by: Louis Monier March 30, 1987 1:45:31 pm PST
Last Edited by: Don Curry May 6, 1987 8:02:18 pm PDT
DIRECTORY CoreCreate, CommonPadFrame, CommonPGA176;
CommonPGA176Impl: CEDAR PROGRAM
IMPORTS CommonPadFrame
EXPORTS CommonPGA176 =
BEGIN OPEN CoreCreate, CommonPGA176;
SetPos: PUBLIC PROC [pga: PGADescr, pos: NAT] = {pga.globalPos ← pos};
NextS: PROC [pga: PGADescr] = {
pos: NAT ← pga.globalPos+1;
WHILE pos<pga.nbPads AND pga.isPowerPad[pos] DO
pos ← pos+1
ENDLOOP;
IF pos=pga.nbPads THEN ERROR; -- ran off the edge of the world
pga.globalPos ← pos;
};
NextP: PROC [pga: PGADescr] = {
pos: NAT ← pga.globalPos+1;
WHILE pos<pga.nbPads+1 AND ~pga.isPowerPad[pos] DO pos ← pos+1 ENDLOOP;
IF pos=pga.nbPads+1 THEN ERROR; -- ran off the edge of the world
pga.globalPos ← pos;
};
-- put the pad on globalPos
AddPad: PROC [pga: PGADescr, public: WR, type: ATOM, pa1, pa2, pa3, pa4, pa5, pa6, pa7, pa8, pa9: PA ← []] ~ {
pas: LIST OF PANIL;
IF pa9#[] THEN pas ← CONS [pa9, pas];
IF pa8#[] THEN pas ← CONS [pa8, pas];
IF pa7#[] THEN pas ← CONS [pa7, pas];
IF pa6#[] THEN pas ← CONS [pa6, pas];
IF pa5#[] THEN pas ← CONS [pa5, pas];
IF pa4#[] THEN pas ← CONS [pa4, pas];
IF pa3#[] THEN pas ← CONS [pa3, pas];
IF pa2#[] THEN pas ← CONS [pa2, pas];
IF pa1#[] THEN pas ← CONS [pa1, pas];
pga.pads ← CommonPadFrame.AddPadList[pga.pads, public, type, pga.globalPos, pas];
};
-- set globalPos to the next signal pad position; put the pad on globalPos
SPad: PUBLIC PROC [pga: PGADescr, public: WR, type: ATOM, pa1, pa2, pa3, pa4, pa5, pa6, pa7, pa8, pa9: PA ← []] ~ {
NextS[pga];
AddPad[pga, public, type, pa1, pa2, pa3, pa4, pa5, pa6, pa7, pa8, pa9];
};
-- set globalPos to the next power pad position; put the pad on globalPos
AddPadOnNextP: PROC [pga: PGADescr, public: WR, type: ATOM, pa1, pa2, pa3, pa4, pa5, pa6, pa7, pa8, pa9: PA ← []] ~ {
NextP[pga];
AddPad[pga, public, type, pa1, pa2, pa3, pa4, pa5, pa6, pa7, pa8, pa9];
};
-- The following is a description of a padframe suited for a particular PGA
pga176: PUBLIC PGADescr ← NEW[PGADescrRec ← [
left: 0,
bottom: 49,
right: 98,
top: 147,
size: 49,
nbPads: 196,
isPowerPad: IsPowerOnCommonPGA176,
name: "CommonPGA176",
doc: "Ibiden small PGA for EU and IFU; 36 signal and 12 power pads per side, plus corners"
]];
-- Corners are power pads too
IsPowerOnCommonPGA176: PROC [pos: NAT] RETURNS [is: BOOL] ~ {
IF pos NOT IN [0..pga176.nbPads) THEN ERROR; -- not a valid pad position
pos ← pos MOD pga176.size; -- reduce to one side in [0..48)
RETURN[pos=0 OR pos=1 OR pos=5 OR pos=8 OR pos=14 OR pos=17 OR pos=23
OR pos=26 OR pos=32 OR pos=35 OR pos=41 OR pos=44 OR pos=48];
};
-- Prepares the PGA with the power pads
MakeCommonPGA176: PUBLIC PROC RETURNS [pga: PGADescr] ~ {
PutPowerPads: PROC [pga: PGADescr, corner: NAT] ~ {
SetPos[pga, corner]; -- the corner pad
AddPadOnNextP[pga, "GndEnd",  $GndEnd];
AddPadOnNextP[pga, "PadVdd",  $PadVdd];
AddPadOnNextP[pga, "Vdd",  $Vdd];
AddPadOnNextP[pga, "PadGnd", $PadGnd];
AddPadOnNextP[pga, "Gnd",  $Gnd];
AddPadOnNextP[pga, "PadVdd",  $PadVdd];
AddPadOnNextP[pga, "Vdd",  $Vdd];
AddPadOnNextP[pga, "PadGnd",  $PadGnd];
AddPadOnNextP[pga, "Gnd",  $Gnd];
AddPadOnNextP[pga, "PadVdd",  $PadVdd];
AddPadOnNextP[pga, "Vdd",  $Vdd];
AddPadOnNextP[pga, "Gnd",  $Gnd]; 
};
pga ← pga176;
pga.pads ← NIL;
PutPowerPads[pga, pga176.left];
PutPowerPads[pga, pga176.bottom];
PutPowerPads[pga, pga176.right];
PutPowerPads[pga, pga176.top];
};
END.