Part Number:OMAP-L138Other Parts Discussed in Thread:SYSBIOS
hello,TI大神们:
Hwi_create(Int intNum, Hwi_FuncPtr hwiFxn, const Hwi_Params *params, Error_Block *eb);
例如:我想要用ompl138 ARM核上的UART0中断,且也查到UART0的中断号为25
现在用Hwi_create函数创建中断应该如何使用?
DSP端的我知道怎使用,ARM不知该如何设置
DSP端如下:(将UART0中断号挂载到DSP CPU7号中断上)
Hwi_Params hwiParams;
Error_Block hwieb;
Hwi_Handle Hwi;
Hwi_Params_init(&hwiParams);
Error_init(&hwieb);
// set the argument you want passed to your ISR function
hwiParams.arg = 25; // ISR传递参数
// Enable this interrupt when object is created? Default is true
hwiParams.enableInt = true;
// set the event id of the peripheral assigned to this interrupt
hwiParams.eventId = 25; // UART0中断号
// don't allow this interrupt to nest itself
hwiParams.maskSetting = Hwi_MaskingOption_SELF;
// Interrupt priority
hwiParams.priority = -1;
// OMAP_DEBUG_OUTPUT("Hwi_create–>HWI_isr_entry vector:%d \r\n",hwiParams.arg); Hwi = Hwi_create(7, (Hwi_FuncPtr)HWI_isr_entry, &hwiParams, &hwieb);
Hwi = Hwi;
if (Error_check(&hwieb)) {
// handle the error
OMAP_DEBUG_OUTPUT("Hwi_create–>HWI_isr_entry fail!!! \r\n");
return(-1);
}
现在想问一下ARM端的Hwi_create该如何设置?
Hwi_create(Int intNum, Hwi_FuncPtr hwiFxn, const Hwi_Params *params, Error_Block *eb);
主要是第一个参数不知如何设置
因为ARM端主要是IRQ 和 FIQ 两个总入口,不知是如何映射到IRQ或FIQ上的
所以能不能给个实际的例子进行设置一下
谢谢了!
Nancy Wang:
请参考以下路径的示例:
ti-processor-sdk-rtos-omapl138-lcdk-06.03.00.106-Windows\pdk_omapl138_1_0_11\packages\ti\csl\arch\arm9\src
software-dl.ti.com/…/index_FDS.html
,
EricPengYong:
您好,我并不是需要IRQ,FIQ的汇编代码,我就想知道 omapl138 sysbios 在ARM端 用Hwi_create函数创建UART0 25号中断在调用此函数这些参数应该怎么设置。因为好像和DSP端设置还不一样,上面我已经举例一个DSP端的用法。
,
Nancy Wang:
试一下填写System Interrupt number,截图是裸机下的中断注册配置。