+
+ // searching for control interface
+ QString ctlRefName = refName+"_enb";
+ ReferenceInterface* ctlRefIface = AI_TO_REF(reference->getIfaceFromName(ctlRefName));
+
+ if (ctlRefIface != NULL) {
+ cout << "found a control iface:" << qPrintable(ctlRefName) << endl;
+ FunctionalInterface *ctlIface = new FunctionalInterface(functionalBlock,ctlRefIface);
+ if (! ctlIface->setAssociatedIface(functionalInterface)) {
+ throw(Exception(PROJECTFILE_CORRUPTED));
+ }
+ ctlIface->setName(name+"_enb");
+ functionalBlock->addInterface(ctlIface);
+ }