文件系统里面只配置了SDIO的中断优先级: /* USART1 config */
USART1_Config();
printf("\r\n this is a fatfs test demo \r\n");
/* Sdio Interrupt Config */
NVIC_Configuration();
没有配置UART接收中断的优先级
我想在文件系统里面通过串口中断接收字符,所以我把UART接收中断配置加进去了
void NVIC_Configuration_uart(void)
{
NVIC_InitTypeDef NVIC_InitStructure;
/* Configure the NVIC Preemption Priority Bits */
NVIC_PriorityGroupConfig(NVIC_PriorityGroup_0);
/* Enable the USARTy Interrupt */
NVIC_InitStructure.NVIC_IRQChannel = USART1_IRQn;
NVIC_InitStructure.NVIC_IRQChannelPreemptionPriority = 0;
NVIC_InitStructure.NVIC_IRQChannelSubPriority = 1;
NVIC_InitStructure.NVIC_IRQChannelCmd = ENABLE;
NVIC_Init(&NVIC_InitStructure);
}
但是加进去之后 串口就不工作了 接收发送都没有反应
请问这是为什么啊?是不是配置有冲突? |