-
Notifications
You must be signed in to change notification settings - Fork 18
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
Strip newlines from StreamHandler #85
Conversation
I think that this is supposed to work via |
I'm not sure this is the right thing to do. Telnet seems to specify CRLF as EOL-character, but the device is not talking telnet. Telnet is just very similar by chance. I made this small client: https://gist.github.com/MichaelWedel/fd288ac19ef1d08d994e639be78aadd0 Connect to the device like this:
|
The original gist had some very unfortunately named variables, I made an update. |
I agree with @MichaelWedel, this doesn't feel like the right way to deal with this. Sending the wrong line-endings is technically an error... If we sanitize the input, we're potentially hiding an issue. Allegedly this is supposed to force telnet to use
But I couldn't get it (or any variation of this strategy using |
@MichaelWedel @MikeHart85. Having read your responses, I am forced to agree that this (the changes I provided) is not the right fix. The stream editor approach above didn't work for me. I haven't tried @MichaelWedel's tool yet, but I do like the idea of interacting with the device + adapter using the native interface via some kind client. I'm sure that this is beneficial for development and deployment. Should we think about distributing these kinds of tools alongside plankton? |
I like the idea of shipping a tool like this with plankton. It could be in the same image, and even part of plankton itself. That way, you could just specify the device you're connecting to and it could figure out the correct line-endings to use by itself. |
What's a good way to handle a protocol like the Linkam with all this status byte stuff? In the example above this just gets printed as |
@MichaelWedel @MikeHart85 I think this issue goes away with the work that @MichaelWedel will be doing in the |
@MikeHart85 stripping the newlines from the input stream makes life a lot easier when connecting via a telnet client.