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

TelnetStream.stop(); #23

Closed
ryaske opened this issue Nov 3, 2022 · 3 comments
Closed

TelnetStream.stop(); #23

ryaske opened this issue Nov 3, 2022 · 3 comments

Comments

@ryaske
Copy link

ryaske commented Nov 3, 2022

TelnetStream.stop(); doesn't stop. I expect the connection to be dropped/disconnected on the client side, however nothing happens and instead I am still connected and receiving telnet messages. I am using ESP32-CAM

@JAndrassy
Copy link
Owner

multiple clients can connect to TelnetStream server. stop() should close first of them.

@ryaske
Copy link
Author

ryaske commented Nov 4, 2022

Thank you for the reply (and for the code)!

I am only connecting to the server once.

multiple clients can connect to TelnetStream server. stop() should close first of them.

If this was the case, calling .stop() on a loop 100x would eventually close all of the connections. However, that is still not the case for me. stop() seems to have no effect what so ever, since I can continue to call TelnetStream.println() with success even after stop()!

Maybe it is a setting on my system side, because I see that the TCP connection is kept open and my telnet client does not know even when i remove power from the ESP. It still does not disconnect until the TCP stream times out. Which is exactly why I am looking for a way to gracefully end the connection from the TelnetStream server side.

Let me know if there is any additional troubleshooting I can do to help hash this out. I dont immediately suspect it is a problem with your library but I do know it is a problem for me

@JAndrassy
Copy link
Owner

JAndrassy commented Feb 5, 2024

in esp32 WiFi library client.stop() does nothing. so the TelnetStream library can't stop the connection.

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