mirror of https://github.com/VLSIDA/OpenRAM.git
Merge branch 'dev' into tech_migration
This commit is contained in:
commit
76f7019432
|
|
@ -253,6 +253,11 @@ class Gds2reader:
|
||||||
thisPath.pathType=pathType
|
thisPath.pathType=pathType
|
||||||
if(self.debugToTerminal==1):
|
if(self.debugToTerminal==1):
|
||||||
print("\t\t\tPath Type: "+str(pathType))
|
print("\t\t\tPath Type: "+str(pathType))
|
||||||
|
elif(idBits==b'\x0E\x02'): #Data type
|
||||||
|
dataType = struct.unpack(">h",record[2:4])[0]
|
||||||
|
thisPath.dataType=dataType
|
||||||
|
if(self.debugToTerminal==1):
|
||||||
|
print("\t\t\tData Type: "+str(dataType))
|
||||||
elif(idBits==b'\x0F\x03'): #Path width
|
elif(idBits==b'\x0F\x03'): #Path width
|
||||||
pathWidth = struct.unpack(">i",record[2:6])[0]
|
pathWidth = struct.unpack(">i",record[2:6])[0]
|
||||||
thisPath.pathWidth=pathWidth
|
thisPath.pathWidth=pathWidth
|
||||||
|
|
|
||||||
|
|
@ -236,6 +236,10 @@ class Gds2writer:
|
||||||
idBits=b'\x16\x02' #purpose layer
|
idBits=b'\x16\x02' #purpose layer
|
||||||
purposeLayer = struct.pack(">h",thisPath.purposeLayer)
|
purposeLayer = struct.pack(">h",thisPath.purposeLayer)
|
||||||
self.writeRecord(idBits+purposeLayer)
|
self.writeRecord(idBits+purposeLayer)
|
||||||
|
if(thisPath.dataType is not None):
|
||||||
|
idBits=b'\x0E\x02' #Data type
|
||||||
|
dataType = struct.pack(">h",thisPath.dataType)
|
||||||
|
self.writeRecord(idBits+dataType)
|
||||||
if(thisPath.pathType):
|
if(thisPath.pathType):
|
||||||
idBits=b'\x21\x02' #Path type
|
idBits=b'\x21\x02' #Path type
|
||||||
pathType = struct.pack(">h",thisPath.pathType)
|
pathType = struct.pack(">h",thisPath.pathType)
|
||||||
|
|
|
||||||
|
|
@ -32,6 +32,7 @@ class GdsPath:
|
||||||
self.drawingLayer=""
|
self.drawingLayer=""
|
||||||
self.purposeLayer=0
|
self.purposeLayer=0
|
||||||
self.pathType=""
|
self.pathType=""
|
||||||
|
self.dataType=None
|
||||||
self.pathWidth=""
|
self.pathWidth=""
|
||||||
self.coordinates=""
|
self.coordinates=""
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue