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

Optional flags #10

Open
lokiledev opened this issue Oct 18, 2022 · 2 comments
Open

Optional flags #10

lokiledev opened this issue Oct 18, 2022 · 2 comments

Comments

@lokiledev
Copy link

Thanks for this great tool!

On the current main branch 493b866

By reading the doc I don't understand what the |g value corresponds to for the optional E field.

E is containing flags that carry information on how to read and display the data.

Is it still necessary ?

  • Also i tried using the no plot option |np  but when I refresh the page the plots are still automatically added, does it work?
  • When i plotted some values in c++ using stringstream I had some values that were formatted with scientific unit 3.2323e-8 and it was detected as a text so no chart was availble. Is it mandatory to format with fixed floating point?

It can be solved on the client side with some flags, maybe we can add this to the doc ?

std::stringstream ss;
ss << std::fixed;
ss.precision(4);
@nesnes
Copy link
Owner

nesnes commented Oct 19, 2022

Hi,

The G flag

The g flag is historical and should not be required (it was an attempt to comply with statsd but this is something that's being progressively dropped. Actually echo "myData:4" | nc -u -w0 127.0.0.1 47269 is a valid packet.

The np flag

The np flag should be working, make sure to group all the flags after a single |.
All the exemples bellow are valid:

  • echo "myData:4|g" | nc -u -w0 127.0.0.1 47269
  • echo "myData:4|g,np" | nc -u -w0 127.0.0.1 47269
  • echo "myData:4|gnp" | nc -u -w0 127.0.0.1 47269
  • echo "myData:4|npg" | nc -u -w0 127.0.0.1 47269

The scientific notation

The scientific notation should be considered as a number, not a string. This seems to be a side effect of the recently added string support. Teleplot is currently being actively improved so we can expect a few bugs like this to occur. this will be fixed very soon along with a stabilization of the 3D shapes protocol thanks to the great work of @Maximilien22 !

@lokiledev
Copy link
Author

Thanks for feedback, I did some more tests and np actually works my bad.
Do you want me to keep sending feedback :)
I was wondering if we could add support for a binary serialization to have a more efficient transport ?

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

No branches or pull requests

2 participants