diff --git a/sim/TinyNets/public_html/manager.js b/sim/TinyNets/public_html/manager.js index f8ac0a0147df851eb2efddb8a088a6acc40e99d3..3174988e643b2efcaf21abfa220c2a82d5cbdbe9 100644 --- a/sim/TinyNets/public_html/manager.js +++ b/sim/TinyNets/public_html/manager.js @@ -1,10 +1,22 @@ function Manager(self) { self.manager = this; + + const syrup = 1000; + + const D_PKT = .030*syrup; //[ms] Packet Process Time + const D_BYTE = .00125*syrup; //[ms] Read/Write Delay per Packet + const BITRATE = 20e3/syrup; //[kHz] bitrate + const D_HB_RX = 10/BITRATE*syrup; //[ms] Delay required to process a received heartbeat + const D_HB_TX = .001*syrup; //[ms] Delay required to transmit a heartbeat + const D_TAKEPULSE = .001*syrup; //[ms] Delay required to take pulse per port + const PKT_HEADER = 5; //[bytes] Number of bytes in a packet header const STD = 252; // Standard Message label const ACK = 253; // Acknowledgement label const STF = 254; // Standard Flood label const ACF = 255; // Flood ACK label + + const verbose = false; this.ports = []; this.numports = 0; @@ -12,6 +24,7 @@ function Manager(self) { this.buffer = []; this.maxBufferSize = 252; this.seenFloods = []; + this.waitUntil = 0; this.setup = function(numports) { this.numports = numports; @@ -25,12 +38,7 @@ function Manager(self) { } }; - this.printPorts = function() { -// self.log(this.ports); - }; - this.connect = function(port, id) { - if (!(port < this.numports)) return; @@ -40,8 +48,6 @@ function Manager(self) { self.disconnect(prevId); } -// self.log('im '+ self.id + ' connecting to ' + id); - this.ports[port] = id; self.connect(id); } @@ -76,23 +82,30 @@ function Manager(self) { }; this.checkBuffer = function() { -// self.log(`about to check buffer of node ${self.id}`); -// self.log(this.buffer); + if (self.now()<this.waitUntil) + return; + + if (this.buffer.length > 100) { + self.log(`WARNING: BUFFER VERY FULL`); + this.heartbeat(); + } + if (this.buffer.length > 0) { this.handlePacket(this.buffer.shift()); } else { self.setColor("black"); } -// self.log(`checked buffer of node ${self.id}`); }; this.heartbeat = function() { + this.waitUntil = Math.max(self.now(),this.waitUntil)+this.numports*D_HB_TX; for (let p=0; p<this.numports; p++) { this.sendPacket(this.buffer.length, undefined, undefined, undefined, undefined, undefined, p); } }; this.takePulse = function() { + this.waitUntil = Math.max(self.now(),this.waitUntil)+this.numports*D_TAKEPULSE; for (let p=0; p<this.numports; p++) { if (this.addr_table[p].heartbeat) { this.addr_table[p].heartbeat = false; @@ -101,13 +114,17 @@ function Manager(self) { if (this.addr_table[p].dests.hasOwnProperty(prop)) { this.addr_table[p].dests = {}; this.addr_table[p].buff = 0; - self.log(`did not receive heartbeat from port ${p}`); + /*if (verbose)*/ self.log(`did not receive heartbeat from port ${p}`); return; } } } } }; + + this.clearSeenFloods = function() { + seenFloods = []; + }; this.sendPacket = function(start, dest=-1, hopcount=0, src=self.id, size=0, data=null, port=-1) { var packet = { @@ -125,6 +142,10 @@ function Manager(self) { return; } + if (packet.src === self.id && (packet.start===STD || packet.start===STF)) { + packet.data = self.now(); + } + if (port < this.numports && this.ports[port] >= 0) { self.send(this.ports[port], 'packet', {name: 'packet', obj: packet}); } @@ -147,6 +168,9 @@ function Manager(self) { }; this.handlePacket = function(packet) { + this.waitUntil = Math.max(self.now(),this.waitUntil); + if (packet.src!==self.id) + this.waitUntil+=D_PKT; // If LUT does not already have the source address, add the entry if ( (packet.start === STD || packet.start === ACK || packet.start === STF || packet.start === ACF) // If this is not a buffer update && packet.src!==self.id // ...or a packet from me @@ -155,43 +179,51 @@ function Manager(self) { // self.log(`added ${packet.src} to its LUT under port ${packet.port}`); } - if (packet.start === STD) { // Standard Packet + packet.hopcount++; // Increment hopcount + + if (packet.start === STD) { // Standard Packet self.setColor("blue"); if (packet.dest === self.id) { // If I am destination const nextPort = this.getMinCostPort(packet.src); // Pick the port to send ACK based off minimizing cost - self.log(`got message ${packet.data}. ACKing port ${nextPort}`); - this.sendPacket(ACK, packet.src, undefined, self.id, undefined, undefined, nextPort); + if (verbose) self.log(`got message ${packet.data}. ACKing port ${nextPort}`); + this.waitUntil+=(packet.size+PKT_HEADER)*(D_BYTE+10/BITRATE); + this.sendPacket(ACK, packet.src, 1, self.id, undefined, packet.data, nextPort); } else { - packet.hopcount++; // Increment hopcount const nextPort = this.getMinCostPort(packet.dest); // Pick the port to send to based off minimizing cost if (nextPort === -1) { // If LUT does not have dest - self.log(`flooding message ${packet.data}`); + packet.start = STF; + if (verbose) self.log(`flooding message ${packet.data}`); + this.waitUntil+=(packet.size+PKT_HEADER)*(D_BYTE*this.numports+10/BITRATE); for (let p = 0; p < this.numports; p++) { // Flood packet - this.sendPacket(STF, packet.dest, packet.hopcount, packet.src, packet.size, packet.data, p); + this.sendPacket(packet.start, packet.dest, packet.hopcount, packet.src, packet.size, packet.data, p); } } else { // If LUT does have dest, send to that port - self.log(`sending packet ${packet.data} along port ${nextPort}`); - this.sendPacket(STD, packet.dest, packet.hopcount, packet.src, packet.size, packet.data, nextPort); + if (verbose) self.log(`sending packet ${packet.data} along port ${nextPort}`); + this.waitUntil+=(packet.size+PKT_HEADER)*(D_BYTE+10/BITRATE); + this.sendPacket(packet.start, packet.dest, packet.hopcount, packet.src, packet.size, packet.data, nextPort); } } - } else if (packet.start === ACK) { // Acknowledgement + } else if (packet.start === ACK) { // Acknowledgement self.setColor("red"); if (packet.dest === self.id) { // If I am destination - self.log(`got ACK from ${packet.src}`); + self.log(`got ACK from ${packet.src}. RTT = ${(self.now()-packet.data)/2/this.getMinHopCountTo(packet.src)/syrup}`); +// self.log(`got ACK from ${packet.src}. RTT = ${self.now()-packet.data}`); } else { - packet.hopcount++; // Increment hopcount const nextPort = this.getMinCostPort(packet.dest); // Pick the port to send to based off minimizing cost if (nextPort === -1) { // If LUT does not have dest - self.log(`flooding ACK`); + packet.start = ACF; + if (verbose) self.log(`flooding ACK`); + this.waitUntil+=(packet.size+PKT_HEADER)*(D_BYTE*this.numports+10/BITRATE); for (let p = 0; p < this.numports; p++) { // Flood ACK - this.sendPacket(ACF, packet.dest, packet.hopcount, packet.src, 0, null, p); + this.sendPacket(packet.start, packet.dest, packet.hopcount, packet.src, packet.size, packet.data, p); } } else { // If LUT does have dest, send to that port - self.log(`forwarding ACK along port ${nextPort}`); - this.sendPacket(ACK, packet.dest, packet.hopcount, packet.src, 0, null, nextPort); + if (verbose) self.log(`forwarding ACK along port ${nextPort}`); + this.waitUntil+=(packet.size+PKT_HEADER)*(D_BYTE+10/BITRATE); + this.sendPacket(packet.start, packet.dest, packet.hopcount, packet.src, packet.size, packet.data, nextPort); } } - } else if (packet.start === STF) { // Standard Flood + } else if (packet.start === STF) { // Standard Flood self.setColor("cyan"); if (this.addr_table[packet.port].dests.hasOwnProperty(packet.dest)) // If I thought this port could send to destination, remove it delete this.addr_table[packet.port].dests[packet.dest]; // ...if that node had known, it wouldn't have forwarded it as a flood. @@ -200,6 +232,7 @@ function Manager(self) { src: packet.src, data: packet.data }; + if (this.hasSeen(thisFlood)) { // If I have seen it before, don't forward // self.log(`not forwarding ${packet.data} from port ${packet.port}`); return; @@ -207,32 +240,33 @@ function Manager(self) { this.seenFloods.push(thisFlood); // Remember the packet if (packet.dest === self.id) { // If I am destination const nextPort = this.getMinCostPort(packet.src); // Pick the port to send ACK based off minimizing cost - self.log(`got flood ${packet.data} from port ${packet.port}. ACKing ${packet.src} along port ${nextPort}`); - this.sendPacket(ACK, packet.src, undefined, self.id, undefined, undefined, nextPort); + if (verbose) self.log(`got flood ${packet.data} from port ${packet.port}. ACKing ${packet.src} along port ${nextPort}`); + this.waitUntil+=(packet.size+PKT_HEADER)*(D_BYTE+10/BITRATE); + this.sendPacket(ACK, packet.src, 1, self.id, undefined, packet.data, nextPort); } else { - packet.hopcount++; // Increment hopcount - const nextPort = this.getMinCostPort(packet.dest); // Pick the port to send to based off minimizing cost if (nextPort === -1) { // If LUT does not have dest - self.log(`flooding message ${packet.data} to all ports except ${packet.port}`); + if (verbose) self.log(`flooding message ${packet.data} to all ports except ${packet.port}`); + this.waitUntil+=(packet.size+PKT_HEADER)*(D_BYTE*(this.numports-1)+10/BITRATE); for (let p = 0; p < this.numports; p++) { // Flood packet if (p !== packet.port) { - this.sendPacket(STF, packet.dest, packet.hopcount, packet.src, packet.size, packet.data, p); + this.sendPacket(packet.start, packet.dest, packet.hopcount, packet.src, packet.size, packet.data, p); } } } else { // If LUT does have dest, send to that port - self.log(`forwarding message ${packet.data} along ${nextPort}`); - this.sendPacket(STD, packet.dest, packet.hopcount, packet.src, packet.size, packet.data, nextPort); + packet.start = STD; + if (verbose) self.log(`forwarding message ${packet.data} along ${nextPort}`); + this.waitUntil+=(packet.size+PKT_HEADER)*(D_BYTE+10/BITRATE); + this.sendPacket(packet.start, packet.dest, packet.hopcount, packet.src, packet.size, packet.data, nextPort); } } - } else if (packet.start === ACF) { // ACK Flood + } else if (packet.start === ACF) { // ACK Flood self.setColor("magenta"); if (this.addr_table[packet.port].dests.hasOwnProperty(packet.dest)) // If I thought this port could send to destination, remove it delete this.addr_table[packet.port].dests[packet.dest]; // ...if that node had known, it wouldn't have forwarded it as a flood. if (packet.dest === self.id) { // If I am destination - self.log(`got ACK from ${packet.src}`); + if (verbose) self.log(`got ACK from ${packet.src}`); } else { - packet.hopcount++; // Increment hopcount // const thisFlood = { // Static information within packet for comparison // dest: packet.dest, // src: packet.src, @@ -244,17 +278,20 @@ function Manager(self) { const nextPort = this.getMinCostPort(packet.dest); // Pick the port to send to based off minimizing cost if (nextPort === -1) { // If LUT does not have dest - self.log(`flooding ACK`); + if (verbose) self.log(`flooding ACK`); + this.waitUntil+=(packet.size+PKT_HEADER)*(D_BYTE*(this.numports-1)+10/BITRATE); for (let p = 0; p < this.numports; p++) { // Flood ACK if (p !== packet.port) - this.sendPacket(ACF, packet.dest, packet.hopcount, packet.src, 0, null, p); + this.sendPacket(packet.start, packet.dest, packet.hopcount, packet.src, packet.size, packet.data, p); } } else { // If LUT does have dest, send to that port - self.log(`forwarding ACK along port ${nextPort}`); - this.sendPacket(ACK, packet.dest, packet.hopcount, packet.src, 0, null, nextPort); + packet.start = ACK; + if (verbose) self.log(`forwarding ACK along port ${nextPort}`); + this.waitUntil+=(packet.size+PKT_HEADER)*(D_BYTE+10/BITRATE); + this.sendPacket(packet.start, packet.dest, packet.hopcount, packet.src, packet.size, packet.data, nextPort); } } - } else { // Buffer Update. Should have been handled elsewhere + } else { // Buffer Update. Should have been handled elsewhere self.log(`Packet start error`); } }; @@ -274,6 +311,18 @@ function Manager(self) { return minPort; }; + this.getMinHopCountTo = function(dest) { + var minHC = Infinity; + for (let p=0; p<this.numports; p++) { + if (this.addr_table[p].dests.hasOwnProperty(dest)) { + var hc = this.addr_table[p].dests[dest]; + if (hc < minHC) + minHC = hc; + } + } + return minHC; + }; + this.hasSeen = function(packet) { for (let p = 0; p < this.seenFloods.length; p++) { if (this.seenFloods[p].dest === packet.dest diff --git a/sim/TinyNets/public_html/network.js b/sim/TinyNets/public_html/network.js index a8728a0c3642c4400d1cf5c9b34d46022824c01e..6720eddc7bf4d50f7873bd0329ffc2837e09b1f7 100644 --- a/sim/TinyNets/public_html/network.js +++ b/sim/TinyNets/public_html/network.js @@ -11,7 +11,7 @@ function latency(a, b) { var min = 10 + Math.abs(((a*topologySeed)^(b*topologySeed)) % 300); var avgVariance = 15; - return Math.floor((Math.log(1-Math.random())/-1) * (avgVariance)) + min + return 0;//Math.floor((Math.log(1-Math.random())/-1) * (avgVariance)) + min } /* @@ -413,6 +413,7 @@ Network.prototype = { }, log: function(str) { + console.log(str); if (this.visualizer) this.visualizer.log(str) else diff --git a/sim/TinyNets/public_html/sim.js b/sim/TinyNets/public_html/sim.js index c26c3dd8fc373a69af1a34a76d7906fd98698f4a..e862fd9de6210662fa3172e8d5935b94f8233fca 100644 --- a/sim/TinyNets/public_html/sim.js +++ b/sim/TinyNets/public_html/sim.js @@ -1,22 +1,18 @@ var net = require("./network"), manager = require('./manager'); -const startupDelay = 100; -const connectDelay = 100; -// The time it takes for a node to process a byte = DELAY_PKT + -// n*DELAY_TX_HB*DELAY_PKT/PERIOD_TX_HB + -// n*DELAY_RX_HB*DELAY_PKT/PERIOD_RX_HB + -// n*DELAY_TAKE_PULSE*DELAY_PKT/PERIOD_TAKE_PULSE, -// n=# of nearest neighbors -const DELAY_PKT = 500; // Baseline packet delay. Assuming no heartbeats, how long it takes to process a packet -const DELAY_TX_HB = 50; // How long it takes to transmit a single heartbeat to a single neighbor -const PERIOD_TX_HB = 240; // Period with which heartbeats are transmitted to all neighbors -const DELAY_RX_HB = 50; // How long it takes to receive and process a single heartbeat from a single neighbor -const PERIOD_RX_HB = PERIOD_TX_HB; // Period with which heartbeats are received from a single neighbor -const DELAY_TAKE_PULSE = 50; // How long it takes to process received heartbeats -const PERIOD_TAKE_PULSE = 2*PERIOD_RX_HB; // Period with which received heartbeats are processed +const startupDelay = .01; +const connectDelay = .01; + +const syrup = 1000; +const dt = .001; + +const PERIOD_CLEAR_F = 10; //[ms] Period with which to clear seenFloods +const PERIOD_TX_HB = 10; //[ms] Period with which heartbeats are transmitted to all neighbors +const PERIOD_TAKE_PULSE = 2*PERIOD_TX_HB; //[ms] Period with which received heartbeats are processed // INITIALIZE NETWORK TOPOLOGY HERE +/* Read network from file var initTopology = []; var rawFile = new XMLHttpRequest(); rawFile.open("GET", "js_code.txt", false); @@ -37,6 +33,55 @@ rawFile.onreadystatechange = function () { } }; rawFile.send(null); +*/ + +const CTRL = 2; +const MOTOR = 3; +var ctrl = []; +for (let c=1; c<=CTRL; c++) { + ctrl.push(c); +} +var motor = []; +var encoder = []; +for (let m=1; m<=MOTOR; m++) { + motor.push(CTRL+m); + encoder.push(CTRL+MOTOR+m); +} +var initTopology = [ctrl]; +for (let c in ctrl) { + initTopology.push([0].concat(motor)); +} +for (let m=0; m<motor.length; m++) { +// initTopology.push(ctrl.concat(encoder[m])); + if (m===0) { + initTopology.push(ctrl.concat([motor[m+1]]).concat([encoder[m]])); + } else if (m===motor.length-1) { + initTopology.push(ctrl.concat([motor[m-1]]).concat([encoder[m]])); + } else { + initTopology.push(ctrl.concat([motor[m-1]]).concat([motor[m+1]]).concat([encoder[m]])); + } +} +for (let m=0; m<motor.length; m++) { + initTopology.push([motor[m]]); +} + +//var initTopology = [ +// [1,2], // 0 +// [0,3,4,5,6,7,8], // 1 +// [0,3,4,5,6,7,8], // 2 +// [1,2,4,9], // 3 +// [1,2,3,5,10], // 4 +// [1,2,4,6,11], // 5 +// [1,2,5,7,12], // 6 +// [1,2,6,8,13], // 7 +// [1,2,7,14], // 8 +// [3], // 9 +// [4], // 10 +// [5], // 11 +// [6], // 12 +// [7], // 13 +// [8] // 14 +//]; // Don't touch this code @@ -52,17 +97,18 @@ for (let i = 0; i < initTopology.length; i++) { this.delay(startupDelay, function() { this.manager.setup(initTopology[i].length); }); - this.tick(DELAY_PKT + initTopology[i].length*DELAY_TX_HB*DELAY_PKT/PERIOD_TX_HB - + initTopology[i].length*DELAY_RX_HB*DELAY_PKT/PERIOD_RX_HB - + initTopology[i].length*DELAY_TAKE_PULSE*DELAY_PKT/PERIOD_TAKE_PULSE, function() { + this.tick(syrup*dt, function() { this.manager.checkBuffer(); }); - this.tick(PERIOD_TX_HB, function() { + this.tick(syrup*PERIOD_TX_HB, function() { this.manager.heartbeat(); }); - this.tick(PERIOD_RX_HB, function() { + this.tick(syrup*PERIOD_TAKE_PULSE, function() { this.manager.takePulse(); }); + this.tick(syrup*PERIOD_CLEAR_F, function() { + this.manager.clearSeenFloods(); + }); }); for (let j = 0; j < initTopology[i].length; j++) { if (initTopology[i][j] === -1) { @@ -79,6 +125,36 @@ for (let i = 0; i < initTopology.length; i++) { //----------------------------------------------------------------------------// // PUT CUSTOM CODE HERE: + +for (let m=0; m<MOTOR; m++) { + sendPacket(motor[m],encoder[m],1 ,"Init",.1); +} +motor.forEach(function(m) { + ctrl.forEach(function (c) { + sendPacket(c,m,1,"Init",.1); + }); +}); +for (let i=1; i<=MOTOR; i++) { + sendPacket(0,motor[motor.length-1]+i,1,"Init",.1); +} + +for (let m=0; m<MOTOR; m++) { + sendPacket(motor[m],encoder[m],1 ,"10k",.1,true); +} + +motor.forEach(function(m) { + ctrl.forEach(function (c) { + sendPacket(c,m,1,"5k",.2,true); + }); +}); + +for (let i=1; i<=MOTOR; i++) { + sendPacket(0,motor[motor.length-1]+i,1,"1k",1,true); +} + +//sendPacket(0,9,1,"hello",1000); + +/* Proof of Concept sendPacket(0,99,1,"Hello!",1000); // To test link failure, uncomment one. To test node failure, uncomment both. @@ -97,7 +173,7 @@ sendPacket(0,99,1,"Hello!",1000); //sendPacket(5,2,1,"Distraction 8!",6000); //sendPacket(4,0,1,"I love you, One!",8000); - +*/ //Don't add stuff below this: //----------------------------------------------------------------------------// @@ -105,11 +181,9 @@ sendPacket(0,99,1,"Hello!",1000); for (let i = 0; i < initTopology.length; i++) { net.add(1, clients[i]); } -net.run(1000 * 1000); // runs for 100 seconds - +net.run(1000 * 100); // runs for 100 seconds - -function send(from, port, message, delay, periodic=false) { +/*function send(from, port, message, delay, periodic=false) { if (periodic) { clients[from].init(function() { this.tick(delay, function() { @@ -124,18 +198,21 @@ function send(from, port, message, delay, periodic=false) { }); } } +*/ function sendPacket(from, dest, size, data, delay, periodic=false) { if (periodic) { clients[from].init(function() { - this.tick(delay, function() { - this.manager.sendPacket(252, dest, -1, undefined, size, data, -1); + this.delay(2000, function() { + this.tick(syrup*delay, function() { + this.manager.sendPacket(252, dest, 1, undefined, size, data); }); + }); }); } else { clients[from].init(function() { - this.delay(delay, function() { - this.manager.sendPacket(252, dest, -1, undefined, size, data, -1); + this.delay(syrup*delay, function() { + this.manager.sendPacket(252, dest, 1, undefined, size, data); }); }); } diff --git a/sim/log.txt b/sim/log.txt new file mode 100644 index 0000000000000000000000000000000000000000..cb25f7a9ebce6fee4f368e26a3a3db38251e6029 --- /dev/null +++ b/sim/log.txt @@ -0,0 +1,332 @@ + +VM10943:1 GET http://localhost:8383/TinyNets/ko.js net::ERR_EMPTY_RESPONSE +(anonymous) @ VM10943:1 +require @ require.js:12 +NetBeans.getKnockout @ VM10989:610 +NetBeans.getKnockoutVersion @ VM10989:624 +(anonymous) @ VM11002:1 +VM10943:1 GET http://localhost:8383/TinyNets/knockout.js net::ERR_EMPTY_RESPONSE +(anonymous) @ VM10943:1 +require @ require.js:12 +NetBeans.getKnockout @ VM10989:614 +NetBeans.getKnockoutVersion @ VM10989:624 +(anonymous) @ VM11002:1 +http://localhost:8383./network.js:419 [2111]: 5: got ACK from 8. RTT = 0.0055 +http://localhost:8383./network.js:419 [2111]: 3: got ACK from 6. RTT = 0.0055 +http://localhost:8383./network.js:419 [2111]: 4: got ACK from 7. RTT = 0.0055 +http://localhost:8383./network.js:419 [2232]: 1: got ACK from 3. RTT = 0.016 +http://localhost:8383./network.js:419 [2253]: 2: got ACK from 3. RTT = 0.0265 +http://localhost:8383./network.js:419 [2262]: 1: got ACK from 4. RTT = 0.031 +http://localhost:8383./network.js:419 [2283]: 2: got ACK from 5. RTT = 0.0415 +http://localhost:8383./network.js:419 [2292]: 1: got ACK from 5. RTT = 0.046 +http://localhost:8383./network.js:419 [2293]: 3: got ACK from 6. RTT = 0.0465 +http://localhost:8383./network.js:419 [2293]: 5: got ACK from 8. RTT = 0.0465 +http://localhost:8383./network.js:419 [2293]: 4: got ACK from 7. RTT = 0.0465 +http://localhost:8383./network.js:419 [2313]: 2: got ACK from 4. RTT = 0.0565 +http://localhost:8383./network.js:419 [2334]: 5: got ACK from 8. RTT = 0.017 +http://localhost:8383./network.js:419 [2334]: 4: got ACK from 7. RTT = 0.017 +http://localhost:8383./network.js:419 [2334]: 3: got ACK from 6. RTT = 0.017 +http://localhost:8383./network.js:419 [2432]: 1: got ACK from 5. RTT = 0.016 +http://localhost:8383./network.js:419 [2432]: 2: got ACK from 4. RTT = 0.016 +http://localhost:8383./network.js:419 [2462]: 2: got ACK from 5. RTT = 0.031 +http://localhost:8383./network.js:419 [2462]: 1: got ACK from 3. RTT = 0.031 +http://localhost:8383./network.js:419 [2492]: 2: got ACK from 3. RTT = 0.046 +http://localhost:8383./network.js:419 [2492]: 1: got ACK from 4. RTT = 0.046 +http://localhost:8383./network.js:419 [2493]: 4: got ACK from 7. RTT = 0.0465 +http://localhost:8383./network.js:419 [2493]: 3: got ACK from 6. RTT = 0.0465 +http://localhost:8383./network.js:419 [2493]: 5: got ACK from 8. RTT = 0.0465 +http://localhost:8383./network.js:419 [2534]: 5: got ACK from 8. RTT = 0.017 +http://localhost:8383./network.js:419 [2534]: 3: got ACK from 6. RTT = 0.017 +http://localhost:8383./network.js:419 [2534]: 4: got ACK from 7. RTT = 0.017 +http://localhost:8383./network.js:419 [2632]: 1: got ACK from 4. RTT = 0.016 +http://localhost:8383./network.js:419 [2632]: 2: got ACK from 3. RTT = 0.016 +http://localhost:8383./network.js:419 [2662]: 2: got ACK from 4. RTT = 0.031 +http://localhost:8383./network.js:419 [2662]: 1: got ACK from 5. RTT = 0.031 +http://localhost:8383./network.js:419 [2692]: 2: got ACK from 5. RTT = 0.046 +http://localhost:8383./network.js:419 [2692]: 1: got ACK from 3. RTT = 0.046 +http://localhost:8383./network.js:419 [2693]: 4: got ACK from 7. RTT = 0.0465 +http://localhost:8383./network.js:419 [2693]: 5: got ACK from 8. RTT = 0.0465 +http://localhost:8383./network.js:419 [2693]: 3: got ACK from 6. RTT = 0.0465 +http://localhost:8383./network.js:419 [2734]: 4: got ACK from 7. RTT = 0.017 +http://localhost:8383./network.js:419 [2734]: 5: got ACK from 8. RTT = 0.017 +http://localhost:8383./network.js:419 [2734]: 3: got ACK from 6. RTT = 0.017 +http://localhost:8383./network.js:419 [2832]: 2: got ACK from 3. RTT = 0.016 +http://localhost:8383./network.js:419 [2832]: 1: got ACK from 4. RTT = 0.016 +http://localhost:8383./network.js:419 [2852]: 5: got ACK from 8. RTT = 0.026 +http://localhost:8383./network.js:419 [2862]: 2: got ACK from 4. RTT = 0.031 +http://localhost:8383./network.js:419 [2862]: 1: got ACK from 5. RTT = 0.031 +http://localhost:8383./network.js:419 [2892]: 1: got ACK from 3. RTT = 0.046 +http://localhost:8383./network.js:419 [2892]: 2: got ACK from 5. RTT = 0.046 +http://localhost:8383./network.js:419 [2893]: 3: got ACK from 6. RTT = 0.0465 +http://localhost:8383./network.js:419 [2893]: 4: got ACK from 7. RTT = 0.0465 +http://localhost:8383./network.js:419 [2933]: 5: got ACK from 8. RTT = 0.0165 +http://localhost:8383./network.js:419 [2934]: 3: got ACK from 6. RTT = 0.017 +http://localhost:8383./network.js:419 [2934]: 4: got ACK from 7. RTT = 0.017 +http://localhost:8383./network.js:419 [3052]: 2: got ACK from 5. RTT = 0.026 +http://localhost:8383./network.js:419 [3082]: 2: got ACK from 4. RTT = 0.041 +http://localhost:8383./network.js:419 [3093]: 4: got ACK from 7. RTT = 0.0465 +http://localhost:8383./network.js:419 [3093]: 3: got ACK from 6. RTT = 0.0465 +http://localhost:8383./network.js:419 [3093]: 5: got ACK from 8. RTT = 0.0465 +http://localhost:8383./network.js:419 [3112]: 2: got ACK from 3. RTT = 0.056 +http://localhost:8383./network.js:419 [3134]: 3: got ACK from 6. RTT = 0.017 +http://localhost:8383./network.js:419 [3155]: 1: got ACK from 5. RTT = 0.0775 +http://localhost:8383./network.js:419 [3175]: 5: got ACK from 8. RTT = 0.0375 +http://localhost:8383./network.js:419 [3175]: 4: got ACK from 7. RTT = 0.0375 +http://localhost:8383./network.js:419 [3185]: 1: got ACK from 3. RTT = 0.0925 +http://localhost:8383./network.js:419 [3247]: 1: got ACK from 4. RTT = 0.1235 +http://localhost:8383./network.js:419 [3256]: 2: got ACK from 4. RTT = 0.028 +http://localhost:8383./network.js:419 [3278]: 0: got ACK from 6. RTT = 0.04633333333333334 +http://localhost:8383./network.js:419 [3296]: 2: got ACK from 3. RTT = 0.048 +http://localhost:8383./network.js:419 [3317]: 0: got ACK from 7. RTT = 0.052833333333333336 +http://localhost:8383./network.js:419 [3326]: 2: got ACK from 5. RTT = 0.063 +http://localhost:8383./network.js:419 [3346]: 3: got ACK from 6. RTT = 0.073 +http://localhost:8383./network.js:419 [3347]: 5: got ACK from 8. RTT = 0.0735 +http://localhost:8383./network.js:419 [3347]: 4: got ACK from 7. RTT = 0.0735 +http://localhost:8383./network.js:419 [3356]: 0: got ACK from 8. RTT = 0.059333333333333335 +http://localhost:8383./network.js:419 [3376]: 3: got ACK from 6. RTT = 0.038 +http://localhost:8383./network.js:419 [3377]: 5: got ACK from 8. RTT = 0.0385 +http://localhost:8383./network.js:419 [3377]: 4: got ACK from 7. RTT = 0.0385 +http://localhost:8383./network.js:419 [3394]: 1: got ACK from 3. RTT = 0.097 +http://localhost:8383./network.js:419 [3456]: 1: got ACK from 5. RTT = 0.128 +http://localhost:8383./network.js:419 [3459]: 2: got ACK from 3. RTT = 0.0295 +http://localhost:8383./network.js:419 [3486]: 1: got ACK from 4. RTT = 0.143 +http://localhost:8383./network.js:419 [3489]: 2: got ACK from 4. RTT = 0.0445 +http://localhost:8383./network.js:419 [3499]: 3: got ACK from 6. RTT = 0.0495 +http://localhost:8383./network.js:419 [3511]: 4: got ACK from 7. RTT = 0.0555 +http://localhost:8383./network.js:419 [3511]: 5: got ACK from 8. RTT = 0.0555 +http://localhost:8383./network.js:419 [3516]: 1: got ACK from 3. RTT = 0.058 +http://localhost:8383./network.js:419 [3519]: 2: got ACK from 5. RTT = 0.0595 +http://localhost:8383./network.js:419 [3540]: 3: got ACK from 6. RTT = 0.02 +http://localhost:8383./network.js:419 [3541]: 5: got ACK from 8. RTT = 0.0205 +http://localhost:8383./network.js:419 [3541]: 4: got ACK from 7. RTT = 0.0205 +http://localhost:8383./network.js:419 [3546]: 1: got ACK from 4. RTT = 0.073 +http://localhost:8383./network.js:419 [3576]: 1: got ACK from 5. RTT = 0.088 +http://localhost:8383./network.js:419 [3632]: 2: got ACK from 4. RTT = 0.016 +http://localhost:8383./network.js:419 [3638]: 1: got ACK from 3. RTT = 0.019 +http://localhost:8383./network.js:419 [3652]: 4: got ACK from 7. RTT = 0.026 +http://localhost:8383./network.js:419 [3662]: 2: got ACK from 3. RTT = 0.031 +http://localhost:8383./network.js:419 [3668]: 1: got ACK from 5. RTT = 0.034 +http://localhost:8383./network.js:419 [3692]: 2: got ACK from 5. RTT = 0.046 +http://localhost:8383./network.js:419 [3693]: 3: got ACK from 6. RTT = 0.0465 +http://localhost:8383./network.js:419 [3693]: 5: got ACK from 8. RTT = 0.0465 +http://localhost:8383./network.js:419 [3698]: 1: got ACK from 4. RTT = 0.049 +http://localhost:8383./network.js:419 [3733]: 4: got ACK from 7. RTT = 0.0165 +http://localhost:8383./network.js:419 [3734]: 5: got ACK from 8. RTT = 0.017 +http://localhost:8383./network.js:419 [3734]: 3: got ACK from 6. RTT = 0.017 +http://localhost:8383./network.js:419 [3832]: 1: got ACK from 5. RTT = 0.016 +http://localhost:8383./network.js:419 [3832]: 2: got ACK from 4. RTT = 0.016 +http://localhost:8383./network.js:419 [3862]: 1: got ACK from 3. RTT = 0.031 +http://localhost:8383./network.js:419 [3862]: 2: got ACK from 5. RTT = 0.031 +http://localhost:8383./network.js:419 [3892]: 5: got ACK from 8. RTT = 0.046 +http://localhost:8383./network.js:419 [3892]: 1: got ACK from 4. RTT = 0.046 +http://localhost:8383./network.js:419 [3892]: 2: got ACK from 3. RTT = 0.046 +http://localhost:8383./network.js:419 [3893]: 4: got ACK from 7. RTT = 0.0465 +http://localhost:8383./network.js:419 [3893]: 3: got ACK from 6. RTT = 0.0465 +http://localhost:8383./network.js:419 [3933]: 5: got ACK from 8. RTT = 0.0165 +http://localhost:8383./network.js:419 [3934]: 4: got ACK from 7. RTT = 0.017 +http://localhost:8383./network.js:419 [3934]: 3: got ACK from 6. RTT = 0.017 +http://localhost:8383./network.js:419 [4032]: 2: got ACK from 4. RTT = 0.016 +http://localhost:8383./network.js:419 [4062]: 2: got ACK from 3. RTT = 0.031 +http://localhost:8383./network.js:419 [4092]: 2: got ACK from 5. RTT = 0.046 +http://localhost:8383./network.js:419 [4093]: 3: got ACK from 6. RTT = 0.0465 +http://localhost:8383./network.js:419 [4093]: 4: got ACK from 7. RTT = 0.0465 +http://localhost:8383./network.js:419 [4093]: 5: got ACK from 8. RTT = 0.0465 +http://localhost:8383./network.js:419 [4134]: 3: got ACK from 6. RTT = 0.017 +http://localhost:8383./network.js:419 [4155]: 1: got ACK from 3. RTT = 0.0775 +http://localhost:8383./network.js:419 [4175]: 4: got ACK from 7. RTT = 0.0375 +http://localhost:8383./network.js:419 [4175]: 5: got ACK from 8. RTT = 0.0375 +http://localhost:8383./network.js:419 [4185]: 1: got ACK from 5. RTT = 0.0925 +http://localhost:8383./network.js:419 [4247]: 1: got ACK from 4. RTT = 0.1235 +http://localhost:8383./network.js:419 [4255]: 2: got ACK from 3. RTT = 0.0275 +http://localhost:8383./network.js:419 [4278]: 0: got ACK from 6. RTT = 0.04633333333333334 +http://localhost:8383./network.js:419 [4297]: 2: got ACK from 5. RTT = 0.0485 +http://localhost:8383./network.js:419 [4317]: 0: got ACK from 8. RTT = 0.052833333333333336 +http://localhost:8383./network.js:419 [4327]: 2: got ACK from 4. RTT = 0.0635 +http://localhost:8383./network.js:419 [4346]: 3: got ACK from 6. RTT = 0.073 +http://localhost:8383./network.js:419 [4347]: 4: got ACK from 7. RTT = 0.0735 +http://localhost:8383./network.js:419 [4347]: 5: got ACK from 8. RTT = 0.0735 +http://localhost:8383./network.js:419 [4355]: 0: got ACK from 7. RTT = 0.059166666666666666 +http://localhost:8383./network.js:419 [4376]: 3: got ACK from 6. RTT = 0.038 +http://localhost:8383./network.js:419 [4377]: 4: got ACK from 7. RTT = 0.0385 +http://localhost:8383./network.js:419 [4377]: 5: got ACK from 8. RTT = 0.0385 +http://localhost:8383./network.js:419 [4394]: 1: got ACK from 5. RTT = 0.097 +http://localhost:8383./network.js:419 [4456]: 1: got ACK from 4. RTT = 0.128 +http://localhost:8383./network.js:419 [4458]: 3: got ACK from 6. RTT = 0.029 +http://localhost:8383./network.js:419 [4459]: 2: got ACK from 5. RTT = 0.0295 +http://localhost:8383./network.js:419 [4486]: 1: got ACK from 3. RTT = 0.143 +http://localhost:8383./network.js:419 [4489]: 2: got ACK from 4. RTT = 0.0445 +http://localhost:8383./network.js:419 [4500]: 4: got ACK from 7. RTT = 0.05 +http://localhost:8383./network.js:419 [4511]: 5: got ACK from 8. RTT = 0.0555 +http://localhost:8383./network.js:419 [4516]: 1: got ACK from 3. RTT = 0.058 +http://localhost:8383./network.js:419 [4519]: 2: got ACK from 3. RTT = 0.0595 +http://localhost:8383./network.js:419 [4539]: 3: got ACK from 6. RTT = 0.0195 +http://localhost:8383./network.js:419 [4541]: 5: got ACK from 8. RTT = 0.0205 +http://localhost:8383./network.js:419 [4541]: 4: got ACK from 7. RTT = 0.0205 +http://localhost:8383./network.js:419 [4546]: 1: got ACK from 5. RTT = 0.073 +http://localhost:8383./network.js:419 [4576]: 1: got ACK from 4. RTT = 0.088 +http://localhost:8383./network.js:419 [4632]: 2: got ACK from 3. RTT = 0.016 +http://localhost:8383./network.js:419 [4638]: 1: got ACK from 5. RTT = 0.019 +http://localhost:8383./network.js:419 [4662]: 2: got ACK from 4. RTT = 0.031 +http://localhost:8383./network.js:419 [4668]: 1: got ACK from 4. RTT = 0.034 +http://localhost:8383./network.js:419 [4692]: 2: got ACK from 5. RTT = 0.046 +http://localhost:8383./network.js:419 [4693]: 3: got ACK from 6. RTT = 0.0465 +http://localhost:8383./network.js:419 [4693]: 5: got ACK from 8. RTT = 0.0465 +http://localhost:8383./network.js:419 [4693]: 4: got ACK from 7. RTT = 0.0465 +http://localhost:8383./network.js:419 [4698]: 1: got ACK from 3. RTT = 0.049 +http://localhost:8383./network.js:419 [4734]: 3: got ACK from 6. RTT = 0.017 +http://localhost:8383./network.js:419 [4734]: 5: got ACK from 8. RTT = 0.017 +http://localhost:8383./network.js:419 [4734]: 4: got ACK from 7. RTT = 0.017 +http://localhost:8383./network.js:419 [4832]: 1: got ACK from 4. RTT = 0.016 +http://localhost:8383./network.js:419 [4852]: 4: got ACK from 7. RTT = 0.026 +http://localhost:8383./network.js:419 [4853]: 2: got ACK from 5. RTT = 0.0265 +http://localhost:8383./network.js:419 [4862]: 1: got ACK from 3. RTT = 0.031 +http://localhost:8383./network.js:419 [4883]: 2: got ACK from 3. RTT = 0.0415 +http://localhost:8383./network.js:419 [4892]: 1: got ACK from 5. RTT = 0.046 +http://localhost:8383./network.js:419 [4893]: 3: got ACK from 6. RTT = 0.0465 +http://localhost:8383./network.js:419 [4893]: 5: got ACK from 8. RTT = 0.0465 +http://localhost:8383./network.js:419 [4913]: 2: got ACK from 4. RTT = 0.0565 +http://localhost:8383./network.js:419 [4933]: 4: got ACK from 7. RTT = 0.0165 +http://localhost:8383./network.js:419 [4934]: 3: got ACK from 6. RTT = 0.017 +http://localhost:8383./network.js:419 [4934]: 5: got ACK from 8. RTT = 0.017 +http://localhost:8383./network.js:419 [5053]: 2: got ACK from 3. RTT = 0.0265 +http://localhost:8383./network.js:419 [5083]: 2: got ACK from 4. RTT = 0.0415 +http://localhost:8383./network.js:419 [5093]: 3: got ACK from 6. RTT = 0.0465 +http://localhost:8383./network.js:419 [5093]: 5: got ACK from 8. RTT = 0.0465 +http://localhost:8383./network.js:419 [5093]: 4: got ACK from 7. RTT = 0.0465 +http://localhost:8383./network.js:419 [5113]: 2: got ACK from 5. RTT = 0.0565 +http://localhost:8383./network.js:419 [5134]: 3: got ACK from 6. RTT = 0.017 +http://localhost:8383./network.js:419 [5155]: 1: got ACK from 3. RTT = 0.0775 +http://localhost:8383./network.js:419 [5175]: 5: got ACK from 8. RTT = 0.0375 +http://localhost:8383./network.js:419 [5175]: 4: got ACK from 7. RTT = 0.0375 +http://localhost:8383./network.js:419 [5185]: 1: got ACK from 5. RTT = 0.0925 +http://localhost:8383./network.js:419 [5247]: 1: got ACK from 4. RTT = 0.1235 +http://localhost:8383./network.js:419 [5254]: 2: got ACK from 3. RTT = 0.027 +http://localhost:8383./network.js:419 [5278]: 0: got ACK from 6. RTT = 0.04633333333333334 +http://localhost:8383./network.js:419 [5284]: 2: got ACK from 4. RTT = 0.042 +http://localhost:8383./network.js:419 [5314]: 2: got ACK from 5. RTT = 0.057 +http://localhost:8383./network.js:419 [5317]: 0: got ACK from 7. RTT = 0.052833333333333336 +http://localhost:8383./network.js:419 [5346]: 3: got ACK from 6. RTT = 0.073 +http://localhost:8383./network.js:419 [5347]: 4: got ACK from 7. RTT = 0.0735 +http://localhost:8383./network.js:419 [5347]: 5: got ACK from 8. RTT = 0.0735 +http://localhost:8383./network.js:419 [5356]: 0: got ACK from 8. RTT = 0.059333333333333335 +http://localhost:8383./network.js:419 [5376]: 3: got ACK from 6. RTT = 0.038 +http://localhost:8383./network.js:419 [5377]: 4: got ACK from 7. RTT = 0.0385 +http://localhost:8383./network.js:419 [5377]: 5: got ACK from 8. RTT = 0.0385 +http://localhost:8383./network.js:419 [5394]: 1: got ACK from 5. RTT = 0.097 +http://localhost:8383./network.js:419 [5432]: 2: got ACK from 3. RTT = 0.016 +http://localhost:8383./network.js:419 [5456]: 1: got ACK from 3. RTT = 0.128 +http://localhost:8383./network.js:419 [5462]: 2: got ACK from 4. RTT = 0.031 +http://localhost:8383./network.js:419 [5486]: 1: got ACK from 4. RTT = 0.143 +http://localhost:8383./network.js:419 [5492]: 2: got ACK from 5. RTT = 0.046 +http://localhost:8383./network.js:419 [5499]: 3: got ACK from 6. RTT = 0.0495 +http://localhost:8383./network.js:419 [5500]: 5: got ACK from 8. RTT = 0.05 +http://localhost:8383./network.js:419 [5511]: 4: got ACK from 7. RTT = 0.0555 +http://localhost:8383./network.js:419 [5516]: 1: got ACK from 5. RTT = 0.058 +http://localhost:8383./network.js:419 [5540]: 3: got ACK from 6. RTT = 0.02 +http://localhost:8383./network.js:419 [5541]: 4: got ACK from 7. RTT = 0.0205 +http://localhost:8383./network.js:419 [5541]: 5: got ACK from 8. RTT = 0.0205 +http://localhost:8383./network.js:419 [5546]: 1: got ACK from 3. RTT = 0.073 +http://localhost:8383./network.js:419 [5576]: 1: got ACK from 4. RTT = 0.088 +http://localhost:8383./network.js:419 [5632]: 2: got ACK from 4. RTT = 0.016 +http://localhost:8383./network.js:419 [5638]: 1: got ACK from 5. RTT = 0.019 +http://localhost:8383./network.js:419 [5662]: 2: got ACK from 5. RTT = 0.031 +http://localhost:8383./network.js:419 [5668]: 1: got ACK from 3. RTT = 0.034 +http://localhost:8383./network.js:419 [5692]: 5: got ACK from 8. RTT = 0.046 +http://localhost:8383./network.js:419 [5692]: 2: got ACK from 3. RTT = 0.046 +http://localhost:8383./network.js:419 [5693]: 3: got ACK from 6. RTT = 0.0465 +http://localhost:8383./network.js:419 [5693]: 4: got ACK from 7. RTT = 0.0465 +http://localhost:8383./network.js:419 [5698]: 1: got ACK from 4. RTT = 0.049 +http://localhost:8383./network.js:419 [5733]: 5: got ACK from 8. RTT = 0.0165 +http://localhost:8383./network.js:419 [5734]: 3: got ACK from 6. RTT = 0.017 +http://localhost:8383./network.js:419 [5734]: 4: got ACK from 7. RTT = 0.017 +http://localhost:8383./network.js:419 [5832]: 1: got ACK from 3. RTT = 0.016 +http://localhost:8383./network.js:419 [5852]: 2: got ACK from 3. RTT = 0.026 +http://localhost:8383./network.js:419 [5862]: 1: got ACK from 5. RTT = 0.031 +http://localhost:8383./network.js:419 [5882]: 2: got ACK from 5. RTT = 0.041 +http://localhost:8383./network.js:419 [5892]: 3: got ACK from 6. RTT = 0.046 +http://localhost:8383./network.js:419 [5892]: 1: got ACK from 4. RTT = 0.046 +http://localhost:8383./network.js:419 [5893]: 5: got ACK from 8. RTT = 0.0465 +http://localhost:8383./network.js:419 [5893]: 4: got ACK from 7. RTT = 0.0465 +http://localhost:8383./network.js:419 [5912]: 2: got ACK from 4. RTT = 0.056 +http://localhost:8383./network.js:419 [5933]: 3: got ACK from 6. RTT = 0.0165 +http://localhost:8383./network.js:419 [5934]: 5: got ACK from 8. RTT = 0.017 +http://localhost:8383./network.js:419 [5934]: 4: got ACK from 7. RTT = 0.017 +http://localhost:8383./network.js:419 [6032]: 2: got ACK from 4. RTT = 0.016 +http://localhost:8383./network.js:419 [6062]: 2: got ACK from 3. RTT = 0.031 +http://localhost:8383./network.js:419 [6092]: 2: got ACK from 5. RTT = 0.046 +http://localhost:8383./network.js:419 [6093]: 4: got ACK from 7. RTT = 0.0465 +http://localhost:8383./network.js:419 [6093]: 5: got ACK from 8. RTT = 0.0465 +http://localhost:8383./network.js:419 [6093]: 3: got ACK from 6. RTT = 0.0465 +http://localhost:8383./network.js:419 [6134]: 3: got ACK from 6. RTT = 0.017 +http://localhost:8383./network.js:419 [6155]: 1: got ACK from 5. RTT = 0.0775 +http://localhost:8383./network.js:419 [6175]: 5: got ACK from 8. RTT = 0.0375 +http://localhost:8383./network.js:419 [6175]: 4: got ACK from 7. RTT = 0.0375 +http://localhost:8383./network.js:419 [6185]: 1: got ACK from 4. RTT = 0.0925 +http://localhost:8383./network.js:419 [6247]: 1: got ACK from 3. RTT = 0.1235 +http://localhost:8383./network.js:419 [6255]: 2: got ACK from 3. RTT = 0.0275 +http://localhost:8383./network.js:419 [6278]: 0: got ACK from 6. RTT = 0.04633333333333334 +http://localhost:8383./network.js:419 [6297]: 2: got ACK from 4. RTT = 0.0485 +http://localhost:8383./network.js:419 [6316]: 0: got ACK from 7. RTT = 0.05266666666666667 +http://localhost:8383./network.js:419 [6327]: 2: got ACK from 5. RTT = 0.0635 +http://localhost:8383./network.js:419 [6346]: 3: got ACK from 6. RTT = 0.073 +http://localhost:8383./network.js:419 [6347]: 5: got ACK from 8. RTT = 0.0735 +http://localhost:8383./network.js:419 [6347]: 4: got ACK from 7. RTT = 0.0735 +http://localhost:8383./network.js:419 [6356]: 0: got ACK from 8. RTT = 0.059333333333333335 +http://localhost:8383./network.js:419 [6376]: 3: got ACK from 6. RTT = 0.038 +http://localhost:8383./network.js:419 [6377]: 5: got ACK from 8. RTT = 0.0385 +http://localhost:8383./network.js:419 [6377]: 4: got ACK from 7. RTT = 0.0385 +http://localhost:8383./network.js:419 [6394]: 1: got ACK from 5. RTT = 0.097 +http://localhost:8383./network.js:419 [6432]: 2: got ACK from 3. RTT = 0.016 +http://localhost:8383./network.js:419 [6456]: 1: got ACK from 4. RTT = 0.128 +http://localhost:8383./network.js:419 [6459]: 5: got ACK from 8. RTT = 0.0295 +http://localhost:8383./network.js:419 [6462]: 2: got ACK from 4. RTT = 0.031 +http://localhost:8383./network.js:419 [6486]: 1: got ACK from 3. RTT = 0.143 +http://localhost:8383./network.js:419 [6492]: 2: got ACK from 5. RTT = 0.046 +http://localhost:8383./network.js:419 [6499]: 3: got ACK from 6. RTT = 0.0495 +http://localhost:8383./network.js:419 [6511]: 4: got ACK from 7. RTT = 0.0555 +http://localhost:8383./network.js:419 [6516]: 1: got ACK from 5. RTT = 0.058 +http://localhost:8383./network.js:419 [6540]: 5: got ACK from 8. RTT = 0.02 +http://localhost:8383./network.js:419 [6540]: 3: got ACK from 6. RTT = 0.02 +http://localhost:8383./network.js:419 [6541]: 4: got ACK from 7. RTT = 0.0205 +http://localhost:8383./network.js:419 [6546]: 1: got ACK from 3. RTT = 0.073 +http://localhost:8383./network.js:419 [6576]: 1: got ACK from 4. RTT = 0.088 +http://localhost:8383./network.js:419 [6632]: 2: got ACK from 3. RTT = 0.016 +http://localhost:8383./network.js:419 [6638]: 1: got ACK from 5. RTT = 0.019 +http://localhost:8383./network.js:419 [6652]: 3: got ACK from 6. RTT = 0.026 +http://localhost:8383./network.js:419 [6652]: 4: got ACK from 7. RTT = 0.026 +http://localhost:8383./network.js:419 [6662]: 2: got ACK from 4. RTT = 0.031 +http://localhost:8383./network.js:419 [6683]: 1: got ACK from 3. RTT = 0.0415 +http://localhost:8383./network.js:419 [6692]: 2: got ACK from 5. RTT = 0.046 +http://localhost:8383./network.js:419 [6693]: 5: got ACK from 8. RTT = 0.0465 +http://localhost:8383./network.js:419 [6713]: 1: got ACK from 4. RTT = 0.0565 +http://localhost:8383./network.js:419 [6733]: 4: got ACK from 7. RTT = 0.0165 +http://localhost:8383./network.js:419 [6733]: 3: got ACK from 6. RTT = 0.0165 +http://localhost:8383./network.js:419 [6734]: 5: got ACK from 8. RTT = 0.017 +http://localhost:8383./network.js:419 [6832]: 1: got ACK from 4. RTT = 0.016 +http://localhost:8383./network.js:419 [6832]: 2: got ACK from 3. RTT = 0.016 +http://localhost:8383./network.js:419 [6862]: 2: got ACK from 4. RTT = 0.031 +http://localhost:8383./network.js:419 [6862]: 1: got ACK from 5. RTT = 0.031 +VM10943:1 GET http://localhost:8383/TinyNets/ko.js net::ERR_EMPTY_RESPONSE +(anonymous) @ VM10943:1 +require @ require.js:12 +NetBeans.getKnockout @ VM10989:610 +NetBeans.getKnockoutVersion @ VM10989:624 +(anonymous) @ VM11003:1 +VM10943:1 GET http://localhost:8383/TinyNets/knockout.js net::ERR_EMPTY_RESPONSE +(anonymous) @ VM10943:1 +require @ require.js:12 +NetBeans.getKnockout @ VM10989:614 +NetBeans.getKnockoutVersion @ VM10989:624 +(anonymous) @ VM11003:1 +VM10943:1 GET http://localhost:8383/TinyNets/ko.js net::ERR_EMPTY_RESPONSE +(anonymous) @ VM10943:1 +require @ require.js:12 +NetBeans.getKnockout @ VM10989:610 +NetBeans.getKnockoutVersion @ VM10989:624 +(anonymous) @ VM11004:1 +VM10943:1 GET http://localhost:8383/TinyNets/knockout.js net::ERR_EMPTY_RESPONSE +(anonymous) @ VM10943:1 +require @ require.js:12 +NetBeans.getKnockout @ VM10989:614 +NetBeans.getKnockoutVersion @ VM10989:624 +(anonymous) @ VM11004:1 diff --git a/sim/read_log.m b/sim/read_log.m new file mode 100644 index 0000000000000000000000000000000000000000..2dcd28057d5e0bf19b51a2fe6c77817364d5c53d --- /dev/null +++ b/sim/read_log.m @@ -0,0 +1,24 @@ +clear;clc;close all + +arr = zeros(0,3); +fh = fopen('log.txt'); +line = fgetl(fh); +while ischar(line) + line = regexp(line,'(\d+): got ACK from (\d+). RTT = (\d+.?\d*)','tokens'); + if ~isempty(line) + arr(end+1,:) = cellfun(@str2double,line{:}); + end + + line = fgetl(fh); +end +fclose(fh); + +hist(arr(:,end)) +xlabel('RTT/hopcount [ms]') +ylabel('PDF') +% subplot(1,3,1) +% hist(arr(arr(:,1)==0,end)) +% subplot(1,3,2) +% hist(arr(arr(:,1)==1 | arr(:,1)==2,end)) +% subplot(1,3,3) +% hist(arr(arr(:,1)>2,end)) \ No newline at end of file