# Problem with USB port communication when flashing Klipper

**URL:** <https://klipper.discourse.group/t/problem-with-usb-port-communication-when-flashing-klipper/26103>\
**Category:** General Discussion\
**Created:** [June 21, 2026, 5:45pm UTC](https://klipper.discourse.group/t/problem-with-usb-port-communication-when-flashing-klipper/26103 "2026-06-21T17:45:39Z")\
**Posts on this page:** 11\
**Page:** 1

<div class="post-metadata">

**Author:** ![hubwoz](https://avatars.discourse-cdn.com/v4/letter/h/6bbea6/32.png) [@hubwoz](https://klipper.discourse.group/u/hubwoz)\
**Post date:** [June 21, 2026, 5:45pm UTC](https://klipper.discourse.group/t/problem-with-usb-port-communication-when-flashing-klipper/26103/1 "2026-06-21T17:45:39Z")

</div>

### Basic Information:

Printer Model:  
 MCU / Printerboard:  
 Host / SBC  
 klippy.log

In the Klipper firmware configuration, the port only shows signs of life with the ‘CAN bus on PA11/PA12’ setup, but unfortunately, it still doesn’t work. The other ports are completely dead.

The printer is a Cambrian Max with an STM32F103RCT6 chip. The board is similar to the MKS Robin E3, except that it lacks a dedicated CH340C USB module. I had the exact same issue with the USB port when flashing Marlin. Recently, I managed to get a working configuration for Marlin, as shown below.

I would guess that there probably needs to be an option to select USART1 PA11/PA12, but that option isn’t available. Does anyone have any ideas on how to get this working? Thanks in advance.

```auto
# 

# "AtomStack FB5 V2.0 (STM32F103RCT6 ARM Cortex-M3)

# 

$$
env:STM32F103RC_atomstack_USB
$$

extends = common_STM32F103RC_variant
; board = genericSTM32F103RC
; board_build.variant = MARLIN_F103Rx
board_build.encrypt_mks = Robin_e3.bin
board_build.offset = 0x5000
board_upload.offset_address = 0x08005000
build_flags = ${common_STM32F103RC_variant.build_flags}
; -DMCU_STM32F103RC -DHAL_SD_MODULE_ENABLED
; -DSS_TIMER=4
-DTIMER_SERVO=TIM5
-DUSE_USB_FS
-DUSBD_IRQ_PRIO=5
-DUSBD_IRQ_SUBPRIO=6
-DUSBD_USE_CDC_MSC
monitor_speed = 250000
; upload_protocol = stlink"

```

 ![klipper2](https://global.discourse-cdn.com/free1/uploads/klipper/original/3X/b/9/b97944fa7e75942b5d3dc65a055f6917b4bd0ba8.jpeg)

---

<div class="post-metadata">

**Author:** ![hcet14](https://avatars.discourse-cdn.com/v4/letter/h/ecd19e/32.png) [@hcet14](https://klipper.discourse.group/u/hcet14)\
**Post date:** [June 21, 2026, 7:31pm UTC](https://klipper.discourse.group/t/problem-with-usb-port-communication-when-flashing-klipper/26103/2 "2026-06-21T19:31:32Z")

</div>

Welcome hubwoz,

> [@hubwoz](#):
>
> I would guess that there probably needs to be an option to select USART1 PA11/PA12, but that option isn’t available.

> [@hubwoz](#):
>
> ![klipper2](https://global.discourse-cdn.com/free1/uploads/klipper/original/3X/b/9/b97944fa7e75942b5d3dc65a055f6917b4bd0ba8.jpeg)

It is available.

Like you did in your picture, mark “Communication interface…” and hit enter. A new submenu should appear and you should be able to choose PA11/PA12.

“—\>” in kiauh indicates a submenu.

---

<div class="post-metadata">

**Author:** ![hubwoz](https://avatars.discourse-cdn.com/v4/letter/h/6bbea6/32.png) [@hubwoz](https://klipper.discourse.group/u/hubwoz)\
**Post date:** [June 21, 2026, 8:12pm UTC](https://klipper.discourse.group/t/problem-with-usb-port-communication-when-flashing-klipper/26103/3 "2026-06-21T20:12:35Z")

</div>

Unfortunately, that option isn’t available (**Serial (on USART1 PA11/PA12**). Unless it can be changed somewhere else.

I can’t add a photo.

The available options are:

1. `( ) USB (on PA11/PA12)`
2. **(X) Serial (on USART1 PA10/PA9)** -
3. `( ) Serial (on USART1 PB7/PB6)`
4. `( ) Serial (on USART2 PA3/PA2)`
5. `( ) Serial (on USART2 PD6/PD5)`
6. `( ) Serial (on USART3 PB11/PB10)`
7. `( ) Serial (on USART3 PD9/PD8)`
8. `( ) CAN bus (on PA11/PA12)`
9. `( ) CAN bus (on PA11/PB9)`
10. `( ) CAN bus (on PB8/PB9)`
11. `( ) CAN bus (on PD0/PD1)`

---

<div class="post-metadata">

**Author:** ![hcet14](https://avatars.discourse-cdn.com/v4/letter/h/ecd19e/32.png) [@hcet14](https://klipper.discourse.group/u/hcet14)\
**Post date:** [June 21, 2026, 8:20pm UTC](https://klipper.discourse.group/t/problem-with-usb-port-communication-when-flashing-klipper/26103/4 "2026-06-21T20:20:51Z")

</div>

> [@hubwoz](#):
>
> 1. ( ) USB (on PA11/PA12)

Did you try that one?

---

<div class="post-metadata">

**Author:** ![hubwoz](https://avatars.discourse-cdn.com/v4/letter/h/6bbea6/32.png) [@hubwoz](https://klipper.discourse.group/u/hubwoz)\
**Post date:** [June 21, 2026, 8:24pm UTC](https://klipper.discourse.group/t/problem-with-usb-port-communication-when-flashing-klipper/26103/5 "2026-06-21T20:24:30Z")

</div>

I tried all options. Whatever happens only happens on CAN bus (on PA11/PA12). So I suppose that the ports would be okay, but the communication would have to be serial and not CAN

---

<div class="post-metadata">

**Author:** ![hcet14](https://avatars.discourse-cdn.com/v4/letter/h/ecd19e/32.png) [@hcet14](https://klipper.discourse.group/u/hcet14)\
**Post date:** [June 21, 2026, 8:49pm UTC](https://klipper.discourse.group/t/problem-with-usb-port-communication-when-flashing-klipper/26103/6 "2026-06-21T20:49:25Z")

</div>

mmmhh…

> [@hubwoz](#):
>
> ![klipper2](https://global.discourse-cdn.com/free1/uploads/klipper/original/3X/b/9/b97944fa7e75942b5d3dc65a055f6917b4bd0ba8.jpeg)

You chose 20KiB offset. I think STM32F103RCT6 uses 28KiB. Could that be a problem?

---

<div class="post-metadata">

**Author:** ![hubwoz](https://avatars.discourse-cdn.com/v4/letter/h/6bbea6/32.png) [@hubwoz](https://klipper.discourse.group/u/hubwoz)\
**Post date:** [June 21, 2026, 8:58pm UTC](https://klipper.discourse.group/t/problem-with-usb-port-communication-when-flashing-klipper/26103/7 "2026-06-21T20:58:55Z")

</div>

(!PB11) GPIO pins to set at micro-controller startup

It’s working now

 ![konfiguracja firmware](https://global.discourse-cdn.com/free1/uploads/klipper/original/3X/d/b/db37ee653e165d8b6cbf8d88bdd10b00259e5906.jpeg)

---

<div class="post-metadata">

**Author:** ![hcet14](https://avatars.discourse-cdn.com/v4/letter/h/ecd19e/32.png) [@hcet14](https://klipper.discourse.group/u/hcet14)\
**Post date:** [June 23, 2026, 12:36pm UTC](https://klipper.discourse.group/t/problem-with-usb-port-communication-when-flashing-klipper/26103/8 "2026-06-23T12:36:11Z")

</div>

> [@hcet14](#):
>
> 1. [quote=“hubwoz, post:3, topic:26103”]

So this was the solution and you still used the 20KiB offset?

---

<div class="post-metadata">

**Author:** ![hubwoz](https://avatars.discourse-cdn.com/v4/letter/h/6bbea6/32.png) [@hubwoz](https://klipper.discourse.group/u/hubwoz)\
**Post date:** [June 23, 2026, 1:49pm UTC](https://klipper.discourse.group/t/problem-with-usb-port-communication-when-flashing-klipper/26103/9 "2026-06-23T13:49:45Z")

</div>

Settings are as per the attached image. The !PB11 GPIO pins were the key.

 ![db37ee653e165d8b6cbf8d88bdd10b00259e5906_2_690x362](https://global.discourse-cdn.com/free1/uploads/klipper/original/3X/e/4/e49af173201830d975dd22795eca7452473098f6.jpeg)

---

<div class="post-metadata">

**Author:** ![hcet14](https://avatars.discourse-cdn.com/v4/letter/h/ecd19e/32.png) [@hcet14](https://klipper.discourse.group/u/hcet14)\
**Post date:** [June 23, 2026, 2:16pm UTC](https://klipper.discourse.group/t/problem-with-usb-port-communication-when-flashing-klipper/26103/10 "2026-06-23T14:16:31Z")

</div>

Could you post a klippy.log? That will make the solution clear.

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/free1/uploads/klipper/original/1X/64419bf2aac6639e6ef5cef200dcd456b0a01ac3.png) [@system](https://klipper.discourse.group/u/system)\
**Post date:** [July 24, 2026, 12:16am UTC](https://klipper.discourse.group/t/problem-with-usb-port-communication-when-flashing-klipper/26103/11 "2026-07-24T00:16:47Z")

</div>

Closed on July 24, 2026, 12:16am UTC

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.
