def update(self,notif): StateElem.update(self) if len(self.data)==0: self.data.append({}) self.data[0]['used'] = notif.used self.data[0]['parentPreference'] = notif.parentPreference self.data[0]['stableNeighbor'] = notif.stableNeighbor self.data[0]['switchStabilityCounter'] = notif.switchStabilityCounter if 'addr' not in self.data[0]: self.data[0]['addr'] = typeAddr.typeAddr() self.data[0]['addr'].update(notif.addr_type, notif.addr_bodyH, notif.addr_bodyL) self.data[0]['DAGrank'] = notif.DAGrank if 'rssi' not in self.data[0]: self.data[0]['rssi'] = typeRssi.typeRssi() self.data[0]['rssi'].update(notif.rssi) self.data[0]['numRx'] = notif.numRx self.data[0]['numTx'] = notif.numTx self.data[0]['numTxACK'] = notif.numTxACK self.data[0]['numWraps'] = notif.numWraps if 'asn' not in self.data[0]: self.data[0]['asn'] = typeAsn.typeAsn() self.data[0]['asn'].update(notif.asn_0_1, notif.asn_2_3, notif.asn_4)
def update(self, notif): StateElem.update(self) if len(self.data) == 0: self.data.append({}) if 'asn' not in self.data[0]: self.data[0]['asn'] = typeAsn.typeAsn() self.data[0]['asn'].update(notif.asn_0_1, notif.asn_2_3, notif.asn_4)
def update(self,notif): StateElem.update(self) if len(self.data)==0: self.data.append({}) self.data[0]['slotOffset'] = notif.slotOffset if 'type' not in self.data[0]: self.data[0]['type'] = typeCellType.typeCellType() self.data[0]['type'].update(notif.type) self.data[0]['shared'] = notif.shared self.data[0]['channelOffset'] = notif.channelOffset if 'neighbor' not in self.data[0]: self.data[0]['neighbor'] = typeAddr.typeAddr() self.data[0]['neighbor'].update(notif.neighbor_type, notif.neighbor_bodyH, notif.neighbor_bodyL) self.data[0]['backoffExponent'] = notif.backoffExponent self.data[0]['backoff'] = notif.backoff self.data[0]['numRx'] = notif.numRx self.data[0]['numTx'] = notif.numTx self.data[0]['numTxACK'] = notif.numTxACK if 'lastUsedAsn' not in self.data[0]: self.data[0]['lastUsedAsn'] = typeAsn.typeAsn() self.data[0]['lastUsedAsn'].update(notif.lastUsedAsn_0_1, notif.lastUsedAsn_2_3, notif.lastUsedAsn_4)
def update(self, notif): StateElem.update(self) if len(self.data) == 0: self.data.append({}) if "asn" not in self.data[0]: self.data[0]["asn"] = typeAsn.typeAsn() self.data[0]["asn"].update(notif.asn_0_1, notif.asn_2_3, notif.asn_4)
def update(self, notif): StateElem.update(self) if len(self.data) == 0: self.data.append({}) self.data[0]["slotOffset"] = notif.slotOffset if "type" not in self.data[0]: self.data[0]["type"] = typeCellType.typeCellType() self.data[0]["type"].update(notif.type) self.data[0]["shared"] = notif.shared self.data[0]["channelOffset"] = notif.channelOffset if "neighbor" not in self.data[0]: self.data[0]["neighbor"] = typeAddr.typeAddr() self.data[0]["neighbor"].update(notif.neighbor_type, notif.neighbor_bodyH, notif.neighbor_bodyL) self.data[0]["numRx"] = notif.numRx self.data[0]["numTx"] = notif.numTx self.data[0]["numTxACK"] = notif.numTxACK if "lastUsedAsn" not in self.data[0]: self.data[0]["lastUsedAsn"] = typeAsn.typeAsn() self.data[0]["lastUsedAsn"].update(notif.lastUsedAsn_0_1, notif.lastUsedAsn_2_3, notif.lastUsedAsn_4)
def update(self, notif): StateElem.update(self) if len(self.data) == 0: self.data.append({}) self.data[0]["used"] = notif.used self.data[0]["parentPreference"] = notif.parentPreference self.data[0]["stableNeighbor"] = notif.stableNeighbor self.data[0]["switchStabilityCounter"] = notif.switchStabilityCounter if "addr" not in self.data[0]: self.data[0]["addr"] = typeAddr.typeAddr() self.data[0]["addr"].update(notif.addr_type, notif.addr_bodyH, notif.addr_bodyL) self.data[0]["DAGrank"] = notif.DAGrank if "rssi" not in self.data[0]: self.data[0]["rssi"] = typeRssi.typeRssi() self.data[0]["rssi"].update(notif.rssi) self.data[0]["numRx"] = notif.numRx self.data[0]["numTx"] = notif.numTx self.data[0]["numTxACK"] = notif.numTxACK self.data[0]["numWraps"] = notif.numWraps if "asn" not in self.data[0]: self.data[0]["asn"] = typeAsn.typeAsn() self.data[0]["asn"].update(notif.asn_0_1, notif.asn_2_3, notif.asn_4)
def update(self, notif): StateElem.update(self) if len(self.data) == 0: self.data.append({}) self.data[0]['used'] = notif.used self.data[0]['parentPreference'] = notif.parentPreference self.data[0]['stableNeighbor'] = notif.stableNeighbor self.data[0]['switchStabilityCounter'] = notif.switchStabilityCounter if 'addr' not in self.data[0]: self.data[0]['addr'] = typeAddr.typeAddr() self.data[0]['addr'].update(notif.addr_type, notif.addr_bodyH, notif.addr_bodyL) self.data[0]['DAGrank'] = notif.DAGrank if 'rssi' not in self.data[0]: self.data[0]['rssi'] = typeRssi.typeRssi() self.data[0]['rssi'].update(notif.rssi) self.data[0]['numRx'] = notif.numRx self.data[0]['numTx'] = notif.numTx self.data[0]['numTxACK'] = notif.numTxACK self.data[0]['numWraps'] = notif.numWraps if 'asn' not in self.data[0]: self.data[0]['asn'] = typeAsn.typeAsn() self.data[0]['asn'].update(notif.asn_0_1, notif.asn_2_3, notif.asn_4)
def update(self, notif): StateElem.update(self) if len(self.data) == 0: self.data.append({}) self.data[0]['slotOffset'] = notif.slotOffset if 'type' not in self.data[0]: self.data[0]['type'] = typeCellType.typeCellType() self.data[0]['type'].update(notif.type) self.data[0]['shared'] = notif.shared self.data[0]['channelOffset'] = notif.channelOffset if 'neighbor' not in self.data[0]: self.data[0]['neighbor'] = typeAddr.typeAddr() self.data[0]['neighbor'].update(notif.neighbor_type, notif.neighbor_bodyH, notif.neighbor_bodyL) self.data[0]['numRx'] = notif.numRx self.data[0]['numTx'] = notif.numTx self.data[0]['numTxACK'] = notif.numTxACK if 'lastUsedAsn' not in self.data[0]: self.data[0]['lastUsedAsn'] = typeAsn.typeAsn() self.data[0]['lastUsedAsn'].update(notif.lastUsedAsn_0_1, notif.lastUsedAsn_2_3, notif.lastUsedAsn_4)