statistics bug fix: divide by number of motes + show time ruler at zoom in/out
This commit is contained in:
parent
c1520a7134
commit
be1c818938
1 changed files with 21 additions and 2 deletions
|
@ -26,7 +26,7 @@
|
||||||
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
||||||
* SUCH DAMAGE.
|
* SUCH DAMAGE.
|
||||||
*
|
*
|
||||||
* $Id: TimeLine.java,v 1.18 2009/12/07 11:04:15 fros4943 Exp $
|
* $Id: TimeLine.java,v 1.19 2009/12/07 11:14:02 fros4943 Exp $
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package se.sics.cooja.plugins;
|
package se.sics.cooja.plugins;
|
||||||
|
@ -340,6 +340,11 @@ public class TimeLine extends VisPlugin {
|
||||||
w, 1
|
w, 1
|
||||||
);
|
);
|
||||||
timeline.scrollRectToVisible(r);
|
timeline.scrollRectToVisible(r);
|
||||||
|
|
||||||
|
/* Time ruler */
|
||||||
|
mousePixelPositionX = centerPixel;
|
||||||
|
mouseDownPixelPositionX = centerPixel;
|
||||||
|
mousePixelPositionY = timeline.getHeight();
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
@ -371,6 +376,12 @@ public class TimeLine extends VisPlugin {
|
||||||
centerPixel - w/2, 0,
|
centerPixel - w/2, 0,
|
||||||
w, 1
|
w, 1
|
||||||
);
|
);
|
||||||
|
|
||||||
|
/* Time ruler */
|
||||||
|
mousePixelPositionX = centerPixel;
|
||||||
|
mouseDownPixelPositionX = centerPixel;
|
||||||
|
mousePixelPositionY = timeline.getHeight();
|
||||||
|
|
||||||
timeline.scrollRectToVisible(r);
|
timeline.scrollRectToVisible(r);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
@ -577,7 +588,15 @@ public class TimeLine extends VisPlugin {
|
||||||
all.onTimeTX += stats.onTimeTX;
|
all.onTimeTX += stats.onTimeTX;
|
||||||
all.onTimeInterfered += stats.onTimeInterfered;
|
all.onTimeInterfered += stats.onTimeInterfered;
|
||||||
}
|
}
|
||||||
logger.info("SUMMARY");
|
all.onTimeBlueLED /= allStats.size();
|
||||||
|
all.onTimeGreenLED /= allStats.size();
|
||||||
|
all.onTimeBlueLED /= allStats.size();
|
||||||
|
all.radioOn /= allStats.size();
|
||||||
|
all.onTimeRX /= allStats.size();
|
||||||
|
all.onTimeTX /= allStats.size();
|
||||||
|
all.onTimeInterfered /= allStats.size();
|
||||||
|
|
||||||
|
logger.info("SIMULATION AVERAGE:");
|
||||||
logger.info(all.toString());
|
logger.info(all.toString());
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in a new issue