Compare commits
No commits in common. "19b9f9e2e7656ad1d39f254cce2daa295999438c" and "7961aab0e12c021da7c63d313a9427b11923d378" have entirely different histories.
19b9f9e2e7
...
7961aab0e1
|
@ -67,9 +67,6 @@ class IoPadSpec ( object ):
|
|||
self._id = IoPadSpec.id
|
||||
IoPadSpec.id += 1
|
||||
|
||||
def setAnalog ( self ):
|
||||
self.side |= IoPin.ANALOG
|
||||
|
||||
def addNets ( self, nets ):
|
||||
self.nets += nets
|
||||
|
||||
|
@ -119,13 +116,11 @@ class IoSpecs ( object ):
|
|||
actual_side |= IoPin.A_END
|
||||
self.addIoPadSpec( padName, actual_side)
|
||||
|
||||
def loadFromPinmux ( self, fileName , cheat_dont_do_analog=False):
|
||||
def loadFromPinmux ( self, fileName ):
|
||||
"""
|
||||
Load ioPadsSpec from a LibreSOC generated pinmux file in JSON format.
|
||||
The cheat_dont_do_analog is there, sigh, because nsxlib doesn't
|
||||
have analog pads. it's a terrible hack.
|
||||
"""
|
||||
print( ' o Loading I/O pad specifications from "%s".' % fileName )
|
||||
print( ' o Loading I/O pad specifications from "{}".'.format(fileName) )
|
||||
if not os.path.isfile(fileName):
|
||||
raise ErrorMessage( 2, [ 'IoSpecs.loadFromPinmux(): '
|
||||
'JSON pinmux file not found.'
|
||||
|
@ -146,12 +141,7 @@ class IoSpecs ( object ):
|
|||
.format(padName) ))
|
||||
continue
|
||||
end = None
|
||||
# remove the direction info: + output - input * bi-directional
|
||||
if padDatas[-1][-1] in '+-*': end = -1
|
||||
# check if pad is analog or not: last spec item starts with "A"
|
||||
if padDatas[-1][0] == 'A' and not cheat_dont_do_analog:
|
||||
self._ioPadsLUT[padName].setAnalog()
|
||||
# add the nets to the pad
|
||||
if padDatas[-1] in '+-*': end = -1
|
||||
self._ioPadsLUT[padName].addNets( padDatas[1:end] )
|
||||
trace( 560, '-' )
|
||||
|
||||
|
|
Loading…
Reference in New Issue