This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

NHET中断

Other Parts Discussed in Thread: HALCOGEN

你好,

我现在用nhet的边沿中断,nhet有多个中断源,代码用edge0和edge1;可是代码生成器里面初始化函数

void het1HighLevelInterrupt(void)
{
uint32 vec = hetREG1->OFF1;

if (vec < 18U)
{
if ((vec & 1U) != 0U)
{
pwmNotification(hetREG1,(vec >> 1U) - 1U, pwmEND_OF_PERIOD);
}
else
{
pwmNotification(hetREG1,(vec >> 1U) - 1U, pwmEND_OF_DUTY);
}
}
else
{
edgeNotification(hetREG1,vec - 18U);
}
}都是这个,我想问如果我用了两个nhet中断,那怎么区分是哪个中断源呢,现在这个初始化函数都是edgeNotification(hetREG1,vec - 18U);求指教