Klipper: Klipper connects but closes conection when issuing a command

Created on 15 Sep 2018  路  2Comments  路  Source: KevinOConnor/klipper

Hello,

the title tells it all, I'm able to connect to the printer, but as soon I issue a command e.g. "status" the connection is refused with the following console output within octopi:
Send: status
Recv: // Klipper state: Not ready
Recv: // Shutdown due to M112 command
Recv: // Once the underlying issue is corrected, use the
Recv: // "FIRMWARE_RESTART" command to reset the firmware, reload the
Recv: // config, and restart the host software.
Recv: // Printer is shutdown
Recv: !! Shutdown due to M112 command
Changing monitoring state from "Operational" to "Error: Shutdown due to M112 command"
Changing monitoring state from "Error: Shutdown due to M112 command" to "Offline (Error: Shutdown due to M112 command)"
Connection closed, closing down monitor


klippy.log

Most helpful comment

I,

Reading the log, it seems that the USB connection is involved.

Have you followed this part of the tutorial ?


Configuring OctoPrint to use Klipper

The OctoPrint web server needs to be configured to communicate with the Klipper host software. Using a web browser, login to the OctoPrint web page, and navigate to the Settings tab. Then configure the following items:

Under "Serial Connection" in "Additional serial ports" add "/tmp/printer". Then click "Save".

Enter the Settings tab again and under "Serial Connection" change the "Serial Port" setting to "/tmp/printer". Navigate to the "Behavior" sub-tab and select the "Cancel any ongoing prints but stay connected to the printer" option. Click "Save".

From the main page, under the "Connection" section (at the top left of the page) make sure the "Serial Port" is set to "/tmp/printer" and click "Connect". (If "/tmp/printer" is not an available selection then try reloading the page.)

Once connected, navigate to the "Terminal" tab and type "status" (without the quotes) into the command entry box and click "Send". The terminal window will likely report there is an error opening the config file - that means OctoPrint is successfully communicating with Klipper. Proceed to the next section.

All 2 comments

I,

Reading the log, it seems that the USB connection is involved.

Have you followed this part of the tutorial ?


Configuring OctoPrint to use Klipper

The OctoPrint web server needs to be configured to communicate with the Klipper host software. Using a web browser, login to the OctoPrint web page, and navigate to the Settings tab. Then configure the following items:

Under "Serial Connection" in "Additional serial ports" add "/tmp/printer". Then click "Save".

Enter the Settings tab again and under "Serial Connection" change the "Serial Port" setting to "/tmp/printer". Navigate to the "Behavior" sub-tab and select the "Cancel any ongoing prints but stay connected to the printer" option. Click "Save".

From the main page, under the "Connection" section (at the top left of the page) make sure the "Serial Port" is set to "/tmp/printer" and click "Connect". (If "/tmp/printer" is not an available selection then try reloading the page.)

Once connected, navigate to the "Terminal" tab and type "status" (without the quotes) into the command entry box and click "Send". The terminal window will likely report there is an error opening the config file - that means OctoPrint is successfully communicating with Klipper. Proceed to the next section.

I believe this issue was addressed via IRC - OctoPrint should be configured to not disconnect on error as described in the installation document.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

KevinOConnor picture KevinOConnor  路  6Comments

Hywelmartin picture Hywelmartin  路  6Comments

ChiliApple picture ChiliApple  路  4Comments

speendo picture speendo  路  3Comments

sapell picture sapell  路  3Comments