Other USB_CONNECT pin on STM32F4xx

If you made your own board, post here, unless you built a Maple or Maple mini clone etc
Post Reply
mrguen
Posts: 12
Joined: Tue Mar 03, 2020 1:21 pm
Answers: 1

Other USB_CONNECT pin on STM32F4xx

Post by mrguen »

Could someone tell me if it would be possible to modify the pin used for USB_CONNECT. The pin used on the STM32F401RC board I am using is PD2 but I would be using this pin that is also SDIO_CMD to communicate with an SD CARD. So I would like to change it.

stas2z
Posts: 131
Joined: Mon Feb 24, 2020 8:17 pm
Answers: 8

Re: Other USB_CONNECT pin on STM32F4xx

Post by stas2z »

Usb device mode doesn't require any "usb_connect" pins, only dm/dp (pa11/12) and gnd, so u can use pd2 without any problems

User avatar
fpiSTM
Posts: 742
Joined: Wed Dec 11, 2019 7:11 pm
Answers: 27
Location: Le Mans
Contact:

Re: Other USB_CONNECT pin on STM32F4xx

Post by fpiSTM »

I guess you use the STM32 core...

USB_CONNECT is not part of the code, I guess you want change the USB_DISC_PIN defined here:
https://github.com/stm32duino/Arduino_C ... ant.h#L129

If your board is not the CoreBoard_F401RC then it is not defined per default. So you can use the generic F401RC variant and defined the one you want thanks build_opt.h or hal_confextra.h.

Else this is normal it is defined as the schematics said and so no way to redefine it as it is wired for USB.
CoreBoardF401_USB_CONNECT.png
CoreBoardF401_USB_CONNECT.png (2.41 KiB) Viewed 862 times
Anyway if you don't use USB I guess you can use it for other thing without any issue.

mrguen
Posts: 12
Joined: Tue Mar 03, 2020 1:21 pm
Answers: 1

Re: Other USB_CONNECT pin on STM32F4xx

Post by mrguen »

Thanks. I will try with another pin.

Post Reply

Return to “Custom design boards”