daemon: added option API TLVs so that per-interface parameters are kept for EMANE models when a single node has multiple interfaces of the same EMANE model type but different model parameters

This commit is contained in:
Rod A Santiago 2016-04-20 08:33:58 -07:00
parent 5895ba2d20
commit c66914ec21
3 changed files with 11 additions and 1 deletions

View file

@ -228,9 +228,13 @@ class Configurable(object):
nodenum = msg.gettlv(coreapi.CORE_TLV_CONF_NODE)
objname = msg.gettlv(coreapi.CORE_TLV_CONF_OBJ)
conftype = msg.gettlv(coreapi.CORE_TLV_CONF_TYPE)
ifacenum = msg.gettlv(coreapi.CORE_TLV_CONF_IFNUM)
if ifacenum is not None:
nodenum = nodenum*1000 + ifacenum
if mgr.verbose:
mgr.info("received configure message for %s" % cls._name)
mgr.info("received configure message for %s nodenum:%s" % (cls._name, str(nodenum)))
if conftype == coreapi.CONF_TYPE_FLAGS_REQUEST:
if mgr.verbose:
mgr.info("replying to configure request for %s model" %