Добавлено after 1 minute 31 second:
Щас времени нет. Попробую cosmic, но пока время мое кончилось на проект. Может на следующей неделе.
Код: Выделить всё
_EXTI_PORTA_IRQHandler:
; EXTI_PORTA_IRQHandler.c: 53: }
iret
Что интересно, SDCC в этом случае поступает оригинальней, вставляя командуUnexpected DIV/DIVW instruction result in ISR
Description
In very specific conditions, a DIV/DIVW instruction may return a false result when executed inside an interrupt service routine (ISR). This error occurs when the DIV/DIVW instruction is interrupted and a second interrupt is generated during the execution of the IRET instruction of the first ISR. Under these conditions, the DIV/DIVW instruction executed inside the second ISR, including function calls, may return an unexpected result.The applications that do not use the DIV/DIVW instruction within ISRs are not impacted.
Workaround
If an ISR or a function called by this routine contains a division operation, the following assembly code should be added inside the ISR before the DIV/DIVW instruction:
push cc
pop a
and a,#$BF
push a
pop cc
This sequence should be placed by C compilers at the beginning of the ISR using DIV/DIVW. The user can refer to the compiler documentation for details on the implementation and control of automatic or manual code insertion.
типа виндовс не может запустить exe файл компилятора (cxstm8.exe).WIN execution failed