예제 #1
0
def ScriptMain(**kw):
    try:
        helpers.staticInitialization(quiet=True)
        #helpers.setTraceLevel( 550 )

        cell, editor = plugins.kwParseMain(**kw)

        views = CRL.Catalog.State.Physical
        if 'views' in kw: views = kw['views']

        if not cell:
            print(
                WarningMessage(
                    'No Cell loaded in the editor (yet), nothing done.'))
            return 0

        rsave(cell, views)
        CRL.destroyAllVHDL()

    except ErrorMessage as e:
        print(e)
        errorCode = e.code
    except Exception as e:
        print('\n\n', e)
        errorCode = 1
        traceback.print_tb(sys.exc_info()[2])

    sys.stdout.flush()
    sys.stderr.flush()

    return 0
예제 #2
0
파일: ChipPlugin.py 프로젝트: xobs/coriolis
def ScriptMain(**kw):
    rvalue = True
    try:
        helpers.staticInitialization(quiet=True)
        #helpers.setTraceLevel( 550 )

        cell, editor = plugins.kwParseMain(**kw)

        conf = chip.Configuration.loadConfiguration(cell, editor)
        if not conf.isValid(): return

        padsCorona = chip.PadsCorona.Corona(conf)
        if not padsCorona.validate(): return

        padsCorona.doLayout()
        placeCore = PlaceCore(conf)
        placeCore.validate()
        placeCore.doFloorplan()
        if editor: editor.fit()

        placeCore.doPlacement()
        if editor: editor.fit()

        corePower = chip.BlockPower.Block(conf)
        corePower.connectPower()
        corePower.connectClock()
        corePower.doLayout()
        if editor: editor.fit()

        coreCorona = chip.BlockCorona.Corona(corePower)
        coreCorona.connectPads(padsCorona)
        coreCorona.connectBlock()
        coreCorona.doLayout()
        if editor: editor.fit()

    except ErrorMessage as e:
        print(e)
        errorCode = e.code
        if     'editor' in locals() and editor \
           and 'cell' in locals() and cell:
            editor.fit()
        rvalue = False
    except Exception as e:
        print('\n\n', e)
        errorCode = 1
        traceback.print_tb(sys.exc_info()[2])
        rvalue = False

    sys.stdout.flush()
    sys.stderr.flush()

    return rvalue
예제 #3
0
def ScriptMain(**kw):
    try:
        helpers.staticInitialization(quiet=True)
        #helpers.setTraceLevel( 550 )

        cell, editor = plugins.kwParseMain(**kw)

        if not cell:
            print WarningMessage(
                'No Cell loaded in the editor (yet), nothing done.')
            return 0

        rsave(cell)
        CRL.destroyAllVHDL()

    except ErrorMessage, e:
        print e
        errorCode = e.code
예제 #4
0
def ScriptMain ( **kw ):
  rvalue = True
  try:
    helpers.staticInitialization( quiet=True )
   #helpers.setTraceLevel( 550 )

    cell, editor = plugins.kwParseMain( **kw )

    conf = chip.Configuration.loadConfiguration( cell, editor )
    if not conf.isValid(): return

    padsCorona = chip.PadsCorona.Corona( conf )
    if not padsCorona.validate(): return

    padsCorona.doLayout()
    placeCore = PlaceCore( conf )
    placeCore.validate()
    placeCore.doFloorplan()
    if editor: editor.fit()

    placeCore.doPlacement()
    if editor: editor.fit()

    corePower = chip.BlockPower.Block( conf )
    corePower.connectPower()
    corePower.connectClock()
    corePower.doLayout()
    if editor: editor.fit()

    coreCorona = chip.BlockCorona.Corona( corePower )
    coreCorona.connectPads( padsCorona )
    coreCorona.connectBlock()
    coreCorona.doLayout()
    if editor: editor.fit()

  except ErrorMessage, e:
    print e; errorCode = e.code
    if editor: editor.fit()
    rvalue = False