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

[BUG] PPPP connection drops out after a short delay on webserver startup. #127

Open
austinrdennis opened this issue Jul 3, 2023 · 3 comments
Labels
bug Something isn't working

Comments

@austinrdennis
Copy link
Contributor

austinrdennis commented Jul 3, 2023

Describe the bug
A similar problem to the one described in #49. I'm having connection problems over PPPP, but only after it works flawlessly for anywhere from 5-45 seconds(ish). Then the video stream freezes and the printer stops responding to PPPP commands.

To Reproduce
Steps to reproduce the behavior:

  1. Install prerequisites from requirements.txt.
  2. Run the webserver via python.
  3. Open the webpage and allow it to load.
  4. Wait for the video stream to freeze.

Expected behavior
The PPPP connection continues to function once established.

Screenshots
Screenshots gallery.

Desktop (please complete the following information):

  • OS: Windows 11
  • Browser: Chrome (64-bit)
  • Versions: Chrome: 114.0.5735.199 (Official Build), AnkerCtl: 1.0.0, Windows: 22621.1848, Python: 3.11.4

Additional context

  • There are no signs of trouble in the console, only the periodic MQTT topic messages.
  • The webserver needs to be killed (hard killed) and restarted in order to get PPPP running again, but the problem happens every time the webserver is started and the browser page is loaded. Refreshing services via the webpage does not fix it.
  • Thing's I've tried already: forwarding the ports given by @chrivers on my router and disabling Windows firewall. These steps allowed the PPPP connection to be established in the first place only after both steps were complete.
@austinrdennis austinrdennis added the bug Something isn't working label Jul 3, 2023
@jk-andersen
Copy link

I am having the same issue running on docker. need to hard kill the process or restart the container

@HakonHarnes
Copy link

HakonHarnes commented Jul 24, 2023

I've also been encountering the same issue where the PPPP connection drops out after a short delay. Restarting the ankerctl service resolves the issue temporarily for me. However, after a few service restarts, the PPPP connection stops working completely, and the Ankermake app displays an "Unable to play real-time video (10000)" error. This error is resolved when the printer is turned off and back on.

This behavior suggests that the PPPP connection might not be properly released by ankerctl, effectively resulting in a build-up of active connections. It seems plausible that the printer might have a limit on the number of active PPPP connections it can handle at a time. If these connections are not released correctly, we may exhaust this limit, which would explain why the connection drops and why the issue resolves upon restarting the printer (which would forcibly close these connections).

@chrivers, would you be able to provide some insight into the process of terminating PPPP connections in ankerctl? My current understanding is that restarting ankerctl might leave these connections open, unless there's a mechanism like persistent storage (e.g., a file recording the connections) to track and properly close them before opening new ones. Or perhaps the PPPP connection times out after a while. I'm not familiar with this kind of stuff but I might look into resolving the issue.

@z-master42
Copy link

I also have a problem with PPPP. However, when I upload my login.json, the wrong IP address and MAC address are extracted. What could be the reason for this?
MQTT and CTRL are green.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants