Question
Can I use CAN and USB pin only if USB plugged in?
Hello,
I am using STM32F103 for my project and it requires CAN most of the time however if a USB connector is plugged in, it should behave like a virtual COM port.
CAN_R and CAN_T pins are connected to PA11 and PA12
together with USB_DP and USB_DM pints.
Below image is the circuit I used to disable CAN transceiver when USB 5V exist.

MCU_USBV comes from the USB 5V and USB_DP is pulled up.

This circuit didn't work for me.
What need to be changed?
