diff --git a/stmhal/boards/STM32F429DISC/stm32f4xx_hal_conf.h b/stmhal/boards/STM32F429DISC/stm32f4xx_hal_conf.h
index 3bd9001c66c0ac63cbface595fbf807d2cfd5e1e..7090db1112cff18a1aa05031cd112cbd8f98c733 100644
--- a/stmhal/boards/STM32F429DISC/stm32f4xx_hal_conf.h
+++ b/stmhal/boards/STM32F429DISC/stm32f4xx_hal_conf.h
@@ -46,6 +46,7 @@
 /* Exported types ------------------------------------------------------------*/
 /* Exported constants --------------------------------------------------------*/
 
+#define USE_USB_HS
 #define USE_USB_HS_IN_FS
 
  /* ########################## Module Selection ############################## */
diff --git a/stmhal/stm32_it.c b/stmhal/stm32_it.c
index f86eb041e9b9630dadec81720c97e322af3bf5e2..5f96c6083b928bc1a4bc82c7f59b29b1e5427634 100644
--- a/stmhal/stm32_it.c
+++ b/stmhal/stm32_it.c
@@ -301,7 +301,7 @@ void SysTick_Handler(void) {
 #if defined(USE_USB_FS)
 #define OTG_XX_IRQHandler      OTG_FS_IRQHandler
 #define OTG_XX_WKUP_IRQHandler OTG_FS_WKUP_IRQHandler
-#elif defined(USE_USB_HS) || defined(USE_USB_HS_IN_FS)
+#elif defined(USE_USB_HS)
 #define OTG_XX_IRQHandler      OTG_HS_IRQHandler
 #define OTG_XX_WKUP_IRQHandler OTG_HS_WKUP_IRQHandler
 #endif
@@ -352,7 +352,7 @@ void OTG_XX_WKUP_IRQHandler(void) {
 #ifdef USE_USB_FS
   /* Clear EXTI pending Bit*/
   __HAL_USB_FS_EXTI_CLEAR_FLAG();
-#elif defined(USE_USB_HS) || defined(USE_USB_HS_IN_FS)
+#elif defined(USE_USB_HS)
     /* Clear EXTI pending Bit*/
   __HAL_USB_HS_EXTI_CLEAR_FLAG();
 #endif
diff --git a/stmhal/stm32_it.h b/stmhal/stm32_it.h
index 5b17428b33184e80ea3738cb9fb247625026b202..b84a7f9e092ee34332ef3ce6de1e69e44d2245ad 100644
--- a/stmhal/stm32_it.h
+++ b/stmhal/stm32_it.h
@@ -74,6 +74,6 @@ void PendSV_Handler(void);
 void SysTick_Handler(void);
 #ifdef USE_USB_FS
 void OTG_FS_IRQHandler(void);
-#elif defined(USE_USB_HS) || defined(USE_USB_HS_IN_FS)
+#elif defined(USE_USB_HS)
 void OTG_HS_IRQHandler(void);
 #endif
diff --git a/stmhal/usbd_conf.c b/stmhal/usbd_conf.c
index 8cf1fbf7352a9c79f4b4310982937333a5e4cd85..e0bfbc568407c6873991618fc0a9a24add74c715 100644
--- a/stmhal/usbd_conf.c
+++ b/stmhal/usbd_conf.c
@@ -95,7 +95,7 @@ void HAL_PCD_MspInit(PCD_HandleTypeDef *hpcd)
     /* Enable USBFS Interrupt */
     HAL_NVIC_EnableIRQ(OTG_FS_IRQn);
   } 
-  
+#if defined(USE_USB_HS)
   else if(hpcd->Instance == USB_OTG_HS)
   {
 #if defined(USE_USB_HS_IN_FS)
@@ -139,7 +139,7 @@ void HAL_PCD_MspInit(PCD_HandleTypeDef *hpcd)
     /* Enable USB HS Clocks */
     __USB_OTG_HS_CLK_ENABLE();
 
-#elif defined(USE_USB_HS)
+#else // !USE_USB_HS_IN_FS
 
     /* Configure USB HS GPIOs */
     __GPIOA_CLK_ENABLE();
@@ -196,7 +196,7 @@ void HAL_PCD_MspInit(PCD_HandleTypeDef *hpcd)
     /* Enable USB HS Clocks */
     __USB_OTG_HS_CLK_ENABLE();
     __USB_OTG_HS_ULPI_CLK_ENABLE();
- #endif
+#endif // !USE_USB_HS_IN_FS
     
     /* Set USBHS Interrupt to the lowest priority */
     HAL_NVIC_SetPriority(OTG_HS_IRQn, IRQ_PRI_OTG_HS, IRQ_SUBPRI_OTG_HS);
@@ -204,6 +204,7 @@ void HAL_PCD_MspInit(PCD_HandleTypeDef *hpcd)
     /* Enable USBHS Interrupt */
     HAL_NVIC_EnableIRQ(OTG_HS_IRQn);
   }   
+#endif  // USE_USB_HS
 }
 /**
   * @brief  DeInitializes the PCD MSP.
@@ -218,7 +219,7 @@ void HAL_PCD_MspDeInit(PCD_HandleTypeDef *hpcd)
     __USB_OTG_FS_CLK_DISABLE();
     __SYSCFG_CLK_DISABLE(); 
   }
-  #if defined(USE_USB_HS) || defined(USE_USB_HS_IN_FS)
+  #if defined(USE_USB_HS)
   else if(hpcd->Instance == USB_OTG_HS)
   {  
     /* Disable USB FS Clocks */ 
@@ -404,7 +405,8 @@ USBD_StatusTypeDef  USBD_LL_Init (USBD_HandleTypeDef *pdev)
   HAL_PCD_SetTxFiFo(&pcd_handle, 1, 0x40);
   HAL_PCD_SetTxFiFo(&pcd_handle, 2, 0x20);
   HAL_PCD_SetTxFiFo(&pcd_handle, 3, 0x40);
-#elif defined(USE_USB_HS_IN_FS)
+#elif defined(USE_USB_HS)
+#if defined(USE_USB_HS_IN_FS)
   /*Set LL Driver parameters */
   pcd_handle.Instance = USB_OTG_HS;
   pcd_handle.Init.dev_endpoints = 4; 
@@ -431,7 +433,7 @@ USBD_StatusTypeDef  USBD_LL_Init (USBD_HandleTypeDef *pdev)
   HAL_PCD_SetTxFiFo(&pcd_handle, 1, 0x40);
   HAL_PCD_SetTxFiFo(&pcd_handle, 2, 0x20);
   HAL_PCD_SetTxFiFo(&pcd_handle, 3, 0x40);
-#elif defined(USE_USB_HS)
+#else // !defined(USE_USB_HS_IN_FS)
   /*Set LL Driver parameters */
   pcd_handle.Instance = USB_OTG_HS;
   pcd_handle.Init.dev_endpoints = 6; 
@@ -460,8 +462,8 @@ USBD_StatusTypeDef  USBD_LL_Init (USBD_HandleTypeDef *pdev)
   HAL_PCD_SetTxFiFo(&pcd_handle, 0, 0x80);
   HAL_PCD_SetTxFiFo(&pcd_handle, 1, 0x174); 
 
-  
-#endif 
+#endif  // !USE_USB_HS_IN_FS
+#endif  // USE_USB_HS
   return USBD_OK;
 }