This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

STM32F107 - NVIC - Priority

Using a STM32F107VC (on the MCBSTM32C) I am able to setup and run an interupt driven peripheral.

However, I am unable to set the priority of that interrupt using the 'Standard Peripheral' functions provided for by ST.

        /* Enable the Interrupt */
        NVIC_InitTypeDef NVIC_InitStructure;

        NVIC_InitStructure.NVIC_IRQChannel = USART2_IRQn;
        NVIC_InitStructure.NVIC_IRQChannelPreemptionPriority = 1;
        NVIC_InitStructure.NVIC_IRQChannelSubPriority = 1;
        NVIC_InitStructure.NVIC_IRQChannelCmd = ENABLE;
        NVIC_Init(&NVIC_InitStructure);

I stop the execution and see that the Keil IDE/Debugger interrupt (Peripherals->Core Peripherals->NVIC) is always set to 0.

Does anybody have any ideas what I'm doing wrong?
Thank you,

0