// EtherRoms.bcpl -- Model 1 // Last modified 27-Aug-81 15:44:35 by Taft get "DoradoProms.defs" external EtherProms //---------------------------------------------------------------------------- let EtherProms(mem) be //---------------------------------------------------------------------------- [ let buff = vec 300 if StEq(mem, "DskEth") then mem!0 = DoAll if StEq(mem, "EtherFifo") & ICtype eq MC10149 then // define the Fifo Prom [ for adr = 0 to 255 do buff!adr = EtherFifo(adr) Header("EtherFifo", 4, buff, 256, 0) PromCommand("Eth-l10") Header("EtherFifo", 4, buff, 256, 0) // the second one is identical PromCommand("Eth-l15") ] if StEq(mem, "EtherPD") & ICtype eq MC10149 then // define the PD Prom [ for adr = 0 to 255 do buff!adr = EtherPD(adr) Header("EtherPD", 4, buff, 256, 0) PromCommand("Eth-h22") ] if StEq(mem, "EtherRcvr") & ICtype eq MC10149 then // define the Rcvr Prom [ for adr = 0 to 255 do buff!adr = EtherRcvr(adr) Header("EtherRcvr", 12, buff, 256, 0) PromCommand("Eth-h09") // command to blow the left nibble PromCommand("Eth-h10", "4") // command to blow the middle nibble PromCommand("Eth-h11", "8") // command to blow the right nibble ] if StEq(mem, "EtherXmtr") & ICtype eq MC10149 then // define the Xmtr Prom [ for adr = 0 to 255 do buff!adr = EtherXmtr(adr) Header("EtherXmtr", 12, buff, 256, 0) PromCommand("Eth-h14") // command to blow the left nibble PromCommand("Eth-h15", "4") // command to blow the middle nibble PromCommand("Eth-h16", "8") // command to blow the right nibble ] ] //---------------------------------------------------------------------------- and EtherFifo(input) = valof //---------------------------------------------------------------------------- // An MCM10150 or MCM10149 (either type will work) // The transmitter fifo and the receiver fifo each use one of these proms. [ manifest [ // The correspondence between voltage levels and bits in the .MB file: high = 1; low = 0 ] structure Input: [ blank bit 8 write bit 4 // msb is A0 pin 4 read bit 4 // msb is A4 pin 10 ] structure Output: [ full bit // Q0 pin 15 notFull bit empty bit notEmpty bit blank bit 12 ] let write = input<