Closed zlgunn closed 9 years ago
In Node.py:
class Node(threading.Thread, MeshProtocol):
interfaces = []
keep_listening = True
mac_addr = "de:ad:be:ef:de:ad"
ip_addr = "eeee:::::::1"
own_addr = "fasdfsdafsa"
def __init__(self, network_links=None, name=None):
self.interfaces = []
self.keep_listening = True
self.mac_addr = "de:ad:be:ef:de:ad"
self.ip_addr = "eeee:::::::1"
self.own_addr = "fasdfsdafsa"
Fixed. They key part was that self.interfaces = []
has to happen after threading.Thread.__init__()
, otherwise all the nodes would share one interface list.
All nodes, when spawned, are connected to the same link, which seems to be chosen at random, though all links appear to spawn correctly.