def ConfigPortHlPy(mode='config', port_handle='', phy_mode='copper', speed='ether1000', autonegotiation='1', duplex='full', intf_mode='ethernet'): print '\nConfigPortHlPy:', port_handle, phy_mode status = ixia_hlt.interface_config(mode=mode, port_handle=port_handle, phy_mode=phy_mode, speed=speed, autonegotiation=autonegotiation, duplex=duplex, intf_mode=intf_mode ) if status['status'] != '1': print '\nConfig_Port failed: %s\n' % status['log'] sys.exit()