Router wird als Client auf der Map angezeigt

Mein Fehler!

Die Zeile

  if delta > 8:

muss raus, war leider noch drin, hatte zum debug eingebaut und unvollständig wieder raus genommen.

  if delta > 8:
    print ("is_similar",c,delta,a,b)

So sollte es sein:

root@yildun:/opt/ffmap-backend# diff -u nodedb.py-ffmuc-original nodedb.py-so-geht-es
--- nodedb.py-ffmuc-original    2015-02-25 21:25:07.698098999 +0100
+++ nodedb.py-so-geht-es        2015-02-27 08:38:21.396502999 +0100
@@ -85,7 +85,7 @@
         try:
           if 'neighbor' in x:
             try:
-              node = self.maybe_node_by_mac((x['neighbor']))
+              node = self.maybe_node_by_mac((x['neighbor'], ))
             except:
               continue

@@ -373,8 +373,12 @@
     delta = 0

   if len(c) > 0:
-    delta = sum(abs(i[0] -i[1]) for i in c)
-
+    delta = 0
+    for i in c:
+      ddd = abs(i[0] -i[1])
+      if ddd > 128:
+        ddd = abs(ddd - 256)
+      delta = delta + ddd
   # These addresses look pretty similar!
   return delta < 8

@@ -393,7 +397,7 @@

   x = list(mac_a)
   x[5] += 1
-  x[5] %= 255
+  x[5] %= 256
   if mac_b == x:
     return True

@@ -402,21 +406,21 @@
     return True

   x[3] += 1
-  x[3] %= 255
+  x[3] %= 256
   if mac_b == x:
     return True

   x = list(mac_a)
   x[0] |= 2
   x[5] += 2
-  x[5] %= 255
+  x[5] %= 256
   if mac_b == x:
     return True

   x = list(mac_a)
   x[0] |= 2
   x[3] += 1
-  x[3] %= 255
+  x[3] %= 256
   if mac_b == x:
     return True

Servus
Christian

1 „Gefällt mir“

Ist das Problem eigentlich gelöst?

Mein 841ND wird auch als Client gelistet (Domäne Ruhrgebiet / Community Mönchengladbach)

Hast Du mal die Mac-Adresse von ihm zur Verfügung?
Wenn’s auf 10:… oder 12:… beginnt, dann gibt es einen Fix, aber niemanden, der ihn derzeit bereit ist einzuspielen, weil die Prioräten derzeit wohl anders sind für die Admins, die auch etwas tun derzeit.

Ja ist ne 12er MAC Adresse

Danke @toffline für die Info zum Fix.
Ich habe den Fix bei uns angewendet und nun gibt es keine Router als Clients mehr auf der Map.
Auch http://map.freifunk-ruhrgebiet.de/list.html sieht gut aus.

Frohe Ostern und viele bunte Router!

Gruß,
Philip

2 „Gefällt mir“

Funktioniert! Perfekt vielen Dank :wink: