Need some help with the Windows Version of OctoPrint - Connection Error

What is the problem?

Running Windows 10
I'm having trouble to connect the serial port. I try all 3 USB ports on my laptop still no go.
COM3,4 & 5.
I also try 3 different USB cables. When I plug it in to the laptop it will detect as the COM Port.
The driver shown as "RAMPS" COM3

Trying to connect to the Creality CR-10 Smart 3D Printer
Running as administrator.

Having problem to connect from the Windows 10 Laptop
This is the log when I run the Octoprint serve

2021-08-15 23:20:24,287 - octoprint.startup - INFO - ******************************************************************************
2021-08-15 23:20:24,365 - octoprint.startup - INFO - Starting OctoPrint 1.6.1
2021-08-15 23:20:24,365 - octoprint.startup - INFO - ******************************************************************************
2021-08-15 23:20:25,118 - octoprint.util.connectivity.connectivity_checker - INFO - Connectivity changed from offline to online
2021-08-15 23:20:25,290 - octoprint.util.connectivity.connectivity_checker - INFO - Connectivity state is currently: online
2021-08-15 23:20:25,290 - octoprint.util.connectivity.connectivity_checker - INFO - Connecting to 1.1.1.1:53 is working
2021-08-15 23:20:25,290 - octoprint.util.connectivity.connectivity_checker - INFO - Resolving octoprint.org is working
2021-08-15 23:20:25,917 - octoprint.startup - INFO - Blacklist processing done, adding 12 blacklisted plugin versions: roomtemp (any), GcodeEditor (0.1.1), GcodeEditor (0.2.0), GcodeEditor (0.2.1), GcodeEditor (0.2.2), GcodeEditor (0.2.3), GcodeEditor (0.2.4), GcodeEditor (0.2.5), GcodeEditor (0.2.6), GcodeEditor (0.2.8), gcodeleveling (0.1.0), gcodeleveling (0.1.1)
2021-08-15 23:20:25,952 - octoprint.plugin.core - INFO - Loading plugins from C:\Octoprint\venv\Lib\site-packages\octoprint\plugins, C:\Users\xMondas-King\AppData\Roaming\OctoPrint\plugins and installed plugin packages...
2021-08-15 23:20:26,805 - octoprint.plugin.core - INFO - Plugin Pi Support Plugin (2021.8.2) did not pass check, not loading.
2021-08-15 23:20:26,903 - octoprint.plugin.core - INFO - Found 16 plugin(s) providing 16 mixin implementations, 32 hook handlers
2021-08-15 23:20:26,955 - octoprint.server.heartbeat - INFO - Starting server heartbeat, 900.0s interval
2021-08-15 23:20:27,330 - octoprint.server - INFO - Intermediary server started
2021-08-15 23:20:27,345 - octoprint.filemanager.storage - INFO - Initializing the file metadata for C:\Users\xMondas-King\AppData\Roaming\OctoPrint\uploads...
2021-08-15 23:20:27,345 - octoprint.filemanager.storage - INFO - ... file metadata for C:\Users\xMondas-King\AppData\Roaming\OctoPrint\uploads initialized successfully.
2021-08-15 23:20:27,345 - octoprint.server - INFO - Added new permission from plugin action_command_notification: PLUGIN_ACTION_COMMAND_NOTIFICATION_SHOW (needs: "Need(method='role', value='plugin_action_command_notification_show')")
2021-08-15 23:20:27,345 - octoprint.server - INFO - Added new permission from plugin action_command_notification: PLUGIN_ACTION_COMMAND_NOTIFICATION_CLEAR (needs: "Need(method='role', value='plugin_action_command_notification_clear')")
2021-08-15 23:20:27,345 - octoprint.server - INFO - Added new permission from plugin action_command_prompt: PLUGIN_ACTION_COMMAND_PROMPT_INTERACT (needs: "Need(method='role', value='plugin_action_command_prompt_interact')")
2021-08-15 23:20:27,345 - octoprint.server - INFO - Added new permission from plugin announcements: PLUGIN_ANNOUNCEMENTS_READ (needs: "Need(method='role', value='plugin_announcements_read')")
2021-08-15 23:20:27,345 - octoprint.server - INFO - Added new permission from plugin announcements: PLUGIN_ANNOUNCEMENTS_MANAGE (needs: "Need(method='role', value='plugin_announcements_manage'), Need(method='role', value='plugin_announcements_read')")
2021-08-15 23:20:27,345 - octoprint.server - INFO - Added new permission from plugin appkeys: PLUGIN_APPKEYS_ADMIN (needs: "Need(method='role', value='plugin_appkeys_admin')")
2021-08-15 23:20:27,345 - octoprint.server - INFO - Added new permission from plugin backup: PLUGIN_BACKUP_ACCESS (needs: "Need(method='role', value='plugin_backup_access')")
2021-08-15 23:20:27,345 - octoprint.server - INFO - Added new permission from plugin firmware_check: PLUGIN_FIRMWARE_CHECK_DISPLAY (needs: "Need(method='role', value='plugin_firmware_check_display')")
2021-08-15 23:20:27,345 - octoprint.server - INFO - Added new permission from plugin logging: PLUGIN_LOGGING_MANAGE (needs: "Need(method='role', value='plugin_logging_manage')")
2021-08-15 23:20:27,345 - octoprint.server - INFO - Added new permission from plugin pluginmanager: PLUGIN_PLUGINMANAGER_MANAGE (needs: "Need(method='role', value='plugin_pluginmanager_manage')")
2021-08-15 23:20:27,345 - octoprint.server - INFO - Added new permission from plugin pluginmanager: PLUGIN_PLUGINMANAGER_INSTALL (needs: "Need(method='role', value='plugin_pluginmanager_manage'), Need(method='role', value='plugin_pluginmanager_install')")
2021-08-15 23:20:27,345 - octoprint.server - INFO - Added new permission from plugin softwareupdate: PLUGIN_SOFTWAREUPDATE_CHECK (needs: "Need(method='role', value='plugin_softwareupdate_check')")
2021-08-15 23:20:27,345 - octoprint.server - INFO - Added new permission from plugin softwareupdate: PLUGIN_SOFTWAREUPDATE_UPDATE (needs: "Need(method='role', value='plugin_softwareupdate_update')")
2021-08-15 23:20:27,345 - octoprint.server - INFO - Added new permission from plugin softwareupdate: PLUGIN_SOFTWAREUPDATE_CONFIGURE (needs: "Need(method='role', value='plugin_softwareupdate_configure')")
2021-08-15 23:20:28,522 - octoprint.util.pip - INFO - Using "c:\octoprint\venv\scripts\python.exe -m pip" as command to invoke pip
2021-08-15 23:20:29,738 - octoprint.util.pip - INFO - Version of pip is 21.2.4
2021-08-15 23:20:29,740 - octoprint.util.pip - INFO - pip installs to c:\octoprint\venv\Lib\site-packages (writable -> yes), --user flag needed -> no, virtual env -> yes
2021-08-15 23:20:29,740 - octoprint.util.pip - INFO - ==> pip ok -> yes
2021-08-15 23:20:29,761 - octoprint.plugins.softwareupdate - INFO - Loaded version cache from disk
2021-08-15 23:20:29,777 - octoprint.plugin.core - INFO - Initialized 16 plugin implementation(s)
2021-08-15 23:20:29,783 - octoprint.plugin.core - INFO - 16 plugin(s) registered with the system:
|  Action Command Notification Support (bundled) = C:\Octoprint\venv\Lib\site-packages\octoprint\plugins\action_command_notification
|  Action Command Prompt Support (bundled) = C:\Octoprint\venv\Lib\site-packages\octoprint\plugins\action_command_prompt
|  Announcement Plugin (bundled) = C:\Octoprint\venv\Lib\site-packages\octoprint\plugins\announcements
|  Anonymous Usage Tracking (bundled) = C:\Octoprint\venv\Lib\site-packages\octoprint\plugins\tracking
|  Application Keys Plugin (bundled) = C:\Octoprint\venv\Lib\site-packages\octoprint\plugins\appkeys
|  Backup & Restore (bundled) = C:\Octoprint\venv\Lib\site-packages\octoprint\plugins\backup
|  Core Wizard (bundled) = C:\Octoprint\venv\Lib\site-packages\octoprint\plugins\corewizard
|  Discovery (bundled) = C:\Octoprint\venv\Lib\site-packages\octoprint\plugins\discovery
|  Error Tracking (bundled) = C:\Octoprint\venv\Lib\site-packages\octoprint\plugins\errortracking
|  File Check (2021.2.23) (bundled) = c:\octoprint\venv\lib\site-packages\octoprint_file_check
|  Firmware Check (2021.8.11) (bundled) = c:\octoprint\venv\lib\site-packages\octoprint_firmware_check
|  GCode Viewer (bundled) = C:\Octoprint\venv\Lib\site-packages\octoprint\plugins\gcodeviewer
|  Logging (bundled) = C:\Octoprint\venv\Lib\site-packages\octoprint\plugins\logging
|  Plugin Manager (bundled) = C:\Octoprint\venv\Lib\site-packages\octoprint\plugins\pluginmanager
|  Software Update (bundled) = C:\Octoprint\venv\Lib\site-packages\octoprint\plugins\softwareupdate
|  Virtual Printer (bundled) = C:\Octoprint\venv\Lib\site-packages\octoprint\plugins\virtual_printer
Prefix legend: ! = disabled, # = blacklisted, * = incompatible
2021-08-15 23:20:29,788 - octoprint.environment - INFO - Detected environment is Python 3.9.6 under Windows (win32). Details:
|  hardware:
|    cores: 4
|    freq: 2500.0
|    ram: 8009408512
|  os:
|    bits: 64
|    id: windows
|    platform: win32
|  python:
|    pip: 21.2.4
|    version: 3.9.6
|    virtualenv: c:\octoprint\venv
2021-08-15 23:20:29,799 - octoprint.server - INFO - Reset webasset folder C:\Users\xMondas-King\AppData\Roaming\OctoPrint\generated\webassets...
2021-08-15 23:20:30,120 - octoprint.server - INFO - Reset webasset folder C:\Users\xMondas-King\AppData\Roaming\OctoPrint\generated\.webassets-cache...
2021-08-15 23:20:30,392 - octoprint.server - INFO - Shutting down intermediary server...
2021-08-15 23:20:30,892 - octoprint.server - INFO - Intermediary server shut down
2021-08-15 23:20:30,895 - octoprint.events - INFO - Processing startup event, this is our first event
2021-08-15 23:20:30,895 - octoprint.events - INFO - Adding 1 events to queue that were held back before startup event
2021-08-15 23:20:30,909 - octoprint.filemanager - INFO - Adding backlog items from all storage types to analysis queue...
2021-08-15 23:20:30,924 - octoprint.server - INFO - Autoconnect on startup is configured, trying to connect to the printer...
2021-08-15 23:20:30,979 - octoprint.plugins.pluginmanager - INFO - Loaded plugin repository data from disk, was still valid
2021-08-15 23:20:31,069 - octoprint.plugins.softwareupdate - INFO - Fetching check overlays from https://plugins.octoprint.org/update_check_overlay.json
2021-08-15 23:20:31,069 - octoprint.filemanager - INFO - Added 0 items from storage type "local" to analysis queue
2021-08-15 23:20:31,282 - octoprint.server - INFO - Trying to connect to configured serial port AUTO
2021-08-15 23:20:31,501 - octoprint.util.comm - INFO - Changing monitoring state from "Offline" to "Detecting serial connection"
2021-08-15 23:20:31,554 - octoprint.util.comm - INFO - Serial detection: Performing autodetection with 1 port/baudrate candidates: COM3@115200
2021-08-15 23:20:31,554 - octoprint.util.comm - INFO - Serial detection: Trying port COM3, baudrate 115200
2021-08-15 23:20:31,554 - octoprint.util.comm - INFO - Connecting to port COM3, baudrate 115200
2021-08-15 23:20:31,640 - octoprint.server.util.watchdog - INFO - Running initial scan on watched folder...
2021-08-15 23:20:31,640 - octoprint.server.util.watchdog - INFO - ... initial scan done.
2021-08-15 23:20:31,640 - octoprint.plugins.pluginmanager - INFO - Loaded notice data from disk, was still valid
2021-08-15 23:20:31,758 - octoprint.util.comm - ERROR - Unexpected error while connecting to serial port COM3, baudrate 115200 from hook default: SerialException: 'Cannot configure port, something went wrong. Original message: PermissionError(13, 'A device attached to the system is not functioning.', None, 31)' @ comm.py:_open_serial:3695
Traceback (most recent call last):
  File "c:\octoprint\venv\lib\site-packages\octoprint\util\comm.py", line 3695, in _open_serial
    serial_obj = factory(
  File "c:\octoprint\venv\lib\site-packages\octoprint\util\comm.py", line 3677, in default
    serial_obj.open()
  File "c:\octoprint\venv\lib\site-packages\serial\serialwin32.py", line 80, in open
    self._reconfigure_port()
  File "c:\octoprint\venv\lib\site-packages\serial\serialwin32.py", line 222, in _reconfigure_port
    raise SerialException(
serial.serialutil.SerialException: Cannot configure port, something went wrong. Original message: PermissionError(13, 'A device attached to the system is not functioning.', None, 31)
2021-08-15 23:20:31,758 - octoprint.util.comm - INFO - Serial detection: Could not open port COM3, baudrate 115200, skipping
2021-08-15 23:20:31,758 - octoprint.util.comm - INFO - Changing monitoring state from "Detecting serial connection" to "Error"
2021-08-15 23:20:31,758 - octoprint.util.comm - INFO - Changing monitoring state from "Error" to "Offline after error"
2021-08-15 23:20:31,758 - octoprint.plugins.action_command_notification - INFO - Notifications cleared
2021-08-15 23:20:32,534 - octoprint.plugins.discovery - INFO - Registered 'OctoPrint instance on DESKTOP-2RM0T9H._http._tcp.local.' for _http._tcp.local.
2021-08-15 23:20:33,415 - octoprint.plugins.discovery - INFO - Registered 'OctoPrint instance on DESKTOP-2RM0T9H._octoprint._tcp.local.' for _octoprint._tcp.local.
2021-08-15 23:20:33,429 - octoprint.plugins.discovery - INFO - Registered OctoPrint instance on DESKTOP-2RM0T9H for SSDP
2021-08-15 23:20:33,453 - octoprint.server - INFO - Listening on http://0.0.0.0:5000 and http://[::]:5000
2021-08-15 23:20:33,533 - octoprint.plugins.pluginmanager - INFO - Loaded plugin repository data from disk, was still valid
2021-08-15 23:20:34,110 - octoprint.plugins.pluginmanager - INFO - Loaded notice data from disk, was still valid
2021-08-15 23:20:34,742 - octoprint.util.pip - INFO - Using "c:\octoprint\venv\scripts\python.exe -m pip" as command to invoke pip
2021-08-15 23:20:34,742 - octoprint.util.pip - INFO - pip installs to c:\octoprint\venv\Lib\site-packages (writable -> yes), --user flag needed -> no, virtual env -> yes
2021-08-15 23:20:34,742 - octoprint.util.pip - INFO - ==> pip ok -> yes
2021-08-15 23:20:34,758 - octoprint.plugins.softwareupdate - INFO - Minimum free storage across all update relevant locations is 241.4GB. That is considered sufficient for updating.
2021-08-15 23:20:35,043 - octoprint.server.preemptive_cache - INFO - Preemptively caching / (ui _default) for {'base_url': 'http://localhost:5000/', 'path': '/', 'query_string': 'l10n=en'}
2021-08-15 23:20:39,158 - octoprint.server.preemptive_cache - INFO - ... done in 4.11

I also disable antivirus software still no luck.
I add the permission to the firewall as the private network.

Thank you in advance.

Have a wonderful day

Raymond

What did you already try to solve it?

WRITE HERE

Have you tried running in safe mode?

WRITE HERE

Did running in safe mode solve the problem?

WRITE HERE

Systeminfo Bundle

You can download this in OctoPrint's System Information dialog ... no bundle, no support!)

WRITE HERE

Additional information about your setup

OctoPrint version, OctoPi version, printer, firmware, browser, operating system, ... as much data as possible

WRITE HERE

Do you have anything else connected to the printer?
Cura for example could connect to it and block the connection for Octoprint.

Nothing else is connected to the printer the sd card is out.

I try to connect with cura it said connected. But I am not too sure how to test it to see is that really works.

Yes. That is like my issue. Seems to be cura can connected to the printer but not the octoprint web interface. The com port failed to connect.

Whenever Cura is open, it is greedy and will take over the serial ports. You don't even have to tell it to, it just has to be open & running. There may be some settings in Cura that mean you can disable this.

1 Like

Open the "Marketplace" in Cura and go to the "Installed" tab. Scroll down to "USB Printing" and uncheck the checkmark in front of it. Then restart Cura and it will no longer touch any serial ports.

2 Likes

When I try to connect the octoprint the cura is not running.

Thank you for the suggestion. I will give it a try to disable the usb printing.

Yes I disable the usb printing and update the windows driver it is working now.

I can connected the octoprint to the CR10-Smart to my laptop now.

Thank you so very much for everyone helping.
Greatly appreciated.

1 Like