none
wince 6.0 驱动异常问题 RRS feed

  • 问题

  • 我在wince6.0 下修改按键驱动,其中有一段段吗如下
    BOOL KeyPad::IsrThreadProc(void)
    {
        RETAILMSG (
    1, (TEXT("------------------keypad InterruptInitialize success1\r\n")));
        m_hevInterrupt
    = CreateEvent(NULL, FALSE, FALSE, NULL);

       
    if (m_hevInterrupt != NULL)
        {
            RETAILMSG (
    1, (TEXT("------------------keypad InterruptInitialize success2\r\n")));
           
    if (InterruptInitialize(SYSINTR_KEYPAD, m_hevInterrupt, NULL, 0))
            {

                KeyPadIstLoop(m_hevInterrupt);
            }
        }

       
    return(FALSE);
    }

    DWORD KeyPadIsrThread(KeyPad
    *pKP)
    {
        RETAILMSG (
    1, (TEXT("------------------keypad KeyPadIsrThread\r\n")));
        pKP
    ->IsrThreadProc();
        RETAILMSG (
    1, (TEXT("------------------keypad KeyPadIsrThread\r\n")));
       
    return(0);
    }

    BOOL KeyPad::IsrThreadStart(
    void)
    {
        RETAILMSG (
    1, (TEXT("------------------keypad IsrThreadStart\r\n")));
       HANDLE hThread
    = CreateThread(NULL, 0, (LPTHREAD_START_ROUTINE)KeyPadIsrThread, this, 0, NULL);

       CloseHandle(hThread);
       RETAILMSG (
    1, (TEXT("------------------keypad IsrThreadStart\r\n")));
      
    return(TRUE);

    }



    当启动系统时提示如下的错误
    ------------------keypad IsrThreadStart
    ------------------keypad KeyPadIsrThread
    Exception 'Prefetch Abort' (3): Thread-Id=054a0002(pth=85303a34), Proc-Id=00400002(pprc=81d29308) 'NK.EXE', VM-active=01e40002(pprc=87e6ae4c) 'udevice.exe'
    PC=c0b41c28(???+0xc0b41c28) RA=c0b41c28(???+0xc0b41c28) SP=d364fe7c, BVA=c0b41c28
    这是什么错误,从提示看,应该是在执行pKP->IsrThreadProc();
    时出现的问题。
    大家有没有碰到这样的问题?这是什么异常啊?
    2009年7月23日 7:39

全部回复