move nvic prio in hal/dcd to bsp for portability
This commit is contained in:
		@@ -44,8 +44,6 @@
 | 
			
		||||
#include "dcd_lpc175x_6x.h"
 | 
			
		||||
#include "LPC17xx.h"
 | 
			
		||||
 | 
			
		||||
#include "osal/osal.h"
 | 
			
		||||
 | 
			
		||||
//--------------------------------------------------------------------+
 | 
			
		||||
// MACRO CONSTANT TYPEDEF
 | 
			
		||||
//--------------------------------------------------------------------+
 | 
			
		||||
@@ -199,14 +197,6 @@ bool dcd_init(uint8_t rhport)
 | 
			
		||||
  sie_write(SIE_CMDCODE_DEVICE_STATUS, 1, 1);    // connect
 | 
			
		||||
 | 
			
		||||
  // USB IRQ priority should be set by application previously
 | 
			
		||||
  // If freeRTOS is used, IRQ priority is limit by max syscall ( smaller is higher )
 | 
			
		||||
#if CFG_TUSB_OS == OPT_OS_FREERTOS
 | 
			
		||||
  if ( NVIC_GetPriority(USB_IRQn) < configLIBRARY_MAX_SYSCALL_INTERRUPT_PRIORITY )
 | 
			
		||||
  {
 | 
			
		||||
    NVIC_SetPriority(USB_IRQn, configLIBRARY_MAX_SYSCALL_INTERRUPT_PRIORITY );
 | 
			
		||||
  }
 | 
			
		||||
#endif
 | 
			
		||||
 | 
			
		||||
  NVIC_ClearPendingIRQ(USB_IRQn);
 | 
			
		||||
  NVIC_EnableIRQ(USB_IRQn);
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user