AnsweredAssumed Answered

USB Interrupt Skipped on Debug

Question asked by souza.daniel.002 on Apr 14, 2016
Latest reply on Apr 15, 2016 by souza.daniel.002
I'm currently developing a usb device using a stm32f103 and the standard STM USB Library (not HAL). My code works fine in release mode, but on debug mode the USB related interrupts are not called (High and low priority USB and CAN interrupts, named USB_HP_CAN1_TX_IRQHandler and USB_LP_CAN1_RX0_IRQHandler respectively in my case. You can find their NVIC initialisation
below: 

  NVIC_InitStructure.NVIC_IRQChannel = USB_LP_CAN1_RX0_IRQn;

  NVIC_InitStructure.NVIC_IRQChannelPreemptionPriority = 1;

  NVIC_InitStructure.NVIC_IRQChannelSubPriority = 1;

  NVIC_InitStructure.NVIC_IRQChannelCmd = ENABLE;

  NVIC_Init(&NVIC_InitStructure);


  NVIC_InitStructure.NVIC_IRQChannel = USB_HP_CAN1_TX_IRQn;

  NVIC_InitStructure.NVIC_IRQChannelPreemptionPriority = 1;

  NVIC_InitStructure.NVIC_IRQChannelSubPriority = 0;

  NVIC_InitStructure.NVIC_IRQChannelCmd = ENABLE;

  NVIC_Init(&NVIC_InitStructure);


Any insights would be appreciated. 

Daniel 

Outcomes