Doodle3D/doodle3d-firmware

Error: "could not open IPC socket (No such file or directory)" one time when a printer is connected

peteruithoven opened this issue · 2 comments

When a printer is just connected an info/status request sometimes returns an error once. The second time it returns success with printerstate set to idle.

This seems be caused by a moment where printDriver.getPrinter() returns "3D-printer[ttyACM0]" instead of nil. But then printer:getState() returns "nil" with the message "could not open IPC socket (No such file or directory)".
On the second request the rinter:getState() returns "idle"

Summary:

  1. Not connected:
    printDriver.getPrinter() > nil
  2. Connected:
    printDriver.getPrinter() > "3D-printer[ttyACM0]"
    printer:getState() > nil
    error response: "could not open IPC socket (No such file or directory)"
  3. Still connected:
    printDriver.getPrinter() > "3D-printer[ttyACM0]"
    printer:getState() > "idle"

It's as if print3D is running but the socket needs a bit more time to start.

In the current the client printer.state is "unkown" for a moment, which we ignore.

I'm not sure this was solved.