Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Time controls #21

Closed
ryft opened this issue Mar 29, 2013 · 6 comments
Closed

Time controls #21

ryft opened this issue Mar 29, 2013 · 6 comments
Assignees

Comments

@ryft
Copy link
Owner

ryft commented Mar 29, 2013

E.g. pause/play/restart/speed up/slow down

@ghost ghost assigned DominikPeters Apr 4, 2013
@ergovschi
Copy link
Collaborator

I think your solution adds a lot of unneeded complexity.

You should have only modified the DataFeeder. The classes TimeControlDataFeeder, TimeControlDataController are useless outside CSVDataFeeder (you cannot speed up time with a real data feeder) and it's not in data controller's logic to do that.

Adding the controls to the panel: Since the right panel extends JPanel you can pass it to the Data Feeder and the feeder can add stuff to it using panel.add() instead of having a special condition inside the RightPanel.

Please don't change the names of the classes. It becomes confusing.

@ryft
Copy link
Owner Author

ryft commented Apr 11, 2013

Apologies for not being clear when importing these issues to github, but can we concentrate on completeness before adding extra functionality? It would be nice to get some more visualisations done and have the backend complete before working on any enhancements in earnest.

@DominikPeters
Copy link
Collaborator

Thanks for your suggestions, and sorry for misinterpreting everything. I had the time logic in the DataFeeder before, but then some of the visualisation misunderstood a "pause" for "no packets are arriving". I'll try to move things and simplify later today.

@ergovschi
Copy link
Collaborator

You can get around that problem by supplying null instead of packets from the data feeder when the system is paused. And then in the data controller when it gets null it doesn't broadcast that new packets arrived.

@ryft
Copy link
Owner Author

ryft commented Apr 12, 2013

Perhaps this is the incorrect place to discuss this, but the data controller seems to be providing a lot of single-packet iterations.

By examining the traffic volume visualisation under certain time scales, on most time intervals only one packet is being sent from the data controller on each newPacketsArrived() call. The packets in question are unpredictable and often not the same protocol, but are in line with what we'd expect from that capture, so are clearly just out of position. Large numbers of packets also arrive in regular intervals, so from this view it seems as if there is a timing problem where the graph is updating too fast for the data controller, but ultimately the speed of the graph is dictated by the data controller itself.

However, by looking at the data feeder I cannot see how this problem could arise, as getNewPackets() simply retrieves the next packets from the iterator as intuition suggests is correct. Could it be that the capture really exhibits this strange behaviour? I've convinced myself that it doesn't by opening the CSV in a spreadsheet and charting packets over time. (I'm testing with eduroam.csv but skype.csv seems to do the same).

This is what I'm talking about if you're unsure:
timing

By refusing to process iterations with <= 1 packet arriving, the graph looks like this:
timing2
(more like what I'd expect, colours are randomised)

@ryft
Copy link
Owner Author

ryft commented Apr 12, 2013

Panic over, apologies for the brain ache. The data feeder was updating per second but the data controller update interval was set to 100ms.

I am now a happy bunny :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants