Commit 21964455 authored by Reto Da Forno's avatar Reto Da Forno
Browse files

minor changes, node positions for webserver updated

parent deda4d50
......@@ -29,7 +29,7 @@ def usage():
def main(argv):
serialid = None
adapterid = 1
adapterid = None
platform = None
ret = flocklab.SUCCESS
......@@ -88,8 +88,10 @@ def main(argv):
rs = cur.fetchone()
if rs:
adapterid = int(rs[0]) + 1
else:
adapterid = 1
cur.execute("INSERT INTO flocklab.tbl_serv_tg_adapt_list (`tg_adapt_types_fk`, `serialid`, `adapterid`) VALUES (%d, '%s', %d)" % (platforms[platform], serialid, adapterid))
print("Serial ID %s registered for %s target adapter %d." % (serialid, platform, adapterid))
print("Serial ID %s registered of %s target adapter %d." % (serialid, platform, adapterid))
else:
print("'%s' is not a valid platform option. Available options: %s" % (platform, ", ".join(platforms.keys())))
......
sensornodes=[
{node_id: 1 , x:22 , y:25},
{node_id: 2 , x:18 , y:105},
{node_id: 3 , x:90 , y:239}, //near elevator
{node_id: 4 , x:69 , y:65},
{node_id: 6 , x:95 , y:344},
{node_id: 7 , x:679 , y:121},
{node_id: 8 , x:80 , y:130},
{node_id: 10 , x:360 , y:200}, // temporary new position
{node_id: 11 , x:561 , y:120},
{node_id: 13 , x:613 , y:293},
{node_id: 14 , x:628 , y:173},
{node_id: 15 , x:128 , y:121},
{node_id: 16 , x:85 , y:404},
{node_id: 17 , x:575 , y:333},
{node_id: 18 , x:233 , y:399},
{node_id: 19 , x:505 , y:345},
{node_id: 20 , x:475 , y:324},
{node_id: 22 , x:159 , y:345},
{node_id: 23 , x:300 , y:304},
{node_id: 24 , x:321 , y:393},
{node_id: 25 , x:571 , y:234},
{node_id: 26 , x:464 , y:217},
{node_id: 27 , x:270 , y:397},
{node_id: 28 , x:159 , y:304},
{node_id: 31 , x:221 , y:218},
{node_id: 32 , x:194 , y:191},
{node_id: 33 , x:71 , y:192},
{node_id: 300 , x:577 , y:563},
{node_id: 301 , x:568 , y:624},
{node_id: 302 , x:71 , y:622},
{node_id: 2 , x:18 , y:25},
{node_id: 4 , x:120 , y:130},
{node_id: 5 , x:18 , y:190},
{node_id: 6 , x:18 , y:70},
{node_id: 7 , x:70 , y:395},
{node_id: 8 , x:18 , y:165},
{node_id: 9 , x:200 , y:130},
{node_id: 10 , x:560 , y:130},
{node_id: 11 , x:120 , y:395},
{node_id: 12 , x:105 , y:395},
];
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment