Operation Theorem
•
61
4.
Start the thread( Use a boolean value to control the thread’s life )
ThreadOn=TRUE;
AfxBeginThread(IntThreadProc,GetSafeHwnd(),THREAD_PRIORIT
Y_NORMAL);
5.
Before exit the program, remember to let the thread go to end
naturally.
ThreadOn=FALSE;
We suggest user to create a thread and use WaitForSingleObject() for each
events in order to guarantee the performance.
You can also use _8136_Callback_Function() to receive INT event and
ignore the above method but the interrupt service routine in this function
should be programmed carefully. The total spent time in this call back
function should not be too long.
Relative Functions:
_8136_INT_Enable(), _8136_INT_Disable(),
_8136_S_Set_Int_Factor(), _8136_S_INT_Control(),
_8136_S_Get_Int_Status(), _8136_Callback_Function() refer to
section 5.9