STM32F103VCT6 developed a boards, need PC7 and PE7 use external interrupt, including PC7 for ultrasonic module () function returns the time waveform acquisition, PE7 used to judge the motor fault state collection, writing program will PC7 and PE7 external interrupt initialization function to write together, always can't collected PE7 state (PC7 normal collection and calculation of ultrasonic measurement distance), baidu search many articles are saying STM32 different port the same pin can not share a break in the mouth, namely PC7 and use EXTI9_5_IRQHandler PE7 cannot at the same time, I will be back PC7 and PE7 external interrupt initialization function separate configuration different priorities, test PC7 measuring ultrasonic distance (OLED display), normal PE7 conditions for normal collection motor (electricity for high level PE7 1 lights light up, when will PE7 manual external to light after light 2), we have encountered this kind of situation?
PC7 PE7 ultrasonic distance the most on the left side of the high level indicator
PE7 manual grounding after another indicator, PC7 can still range
CodePudding user response:
They interrupt signal in a line, only one will be connected,
CodePudding user response:
These interrupts used AFIO_EXTICR2 to choose which port pin connected to the interrupt line, you can't connect PC7 and PE7 at the same time, can not choose both, but both choose is can't do,