I use cube usb library for usb_otg_fs mode wit STM32L467. I would like to use DM and DP pins also as GPIO INPUT PULL UP when usb is not used.
After usb connection closed, I do the following:
1) I use functions USBD_Stop and USBD_DeInit
2) Disable usb_otg_fs clock
2) Initialize DM and DP pins as GPIO INPUT PULL UP
But after these operations I cannot see high logic level on these pins. Maybe I didn't clear all necessary registers in usb_otg_fs? How should I properly deinitialize usb interface for using DM and DP pins as gpio?