For event synchronization, eventwaithandle is encapsulated in C #, which is very convenient to use. Even in the wince system, autoresetevent and manualresetevent are still supported. However, if you want to cross-process, you must use eventwaithandle (I don't know if I am alone, but I don't know if there are other methods ). Unfortunately, this class is not supported in the wince system. For this reason, I was depressed for a while.
In desperation, prepare to call the API functions-openevent, setevent, and resetevent. The result is that only openevent is successfully called, and both setevent and resetevent fail to be called. At the beginning, I still suspected that my code was wrong. Later I checked coredll. dll, and there were no setevent or resetevent functions. For this reason, I am so angry with the class C # language.
When checking coredll. dll, we accidentally found a good function ceeventmodify (handle hhandle, uint func). As long as the func value is changed, we can implement the setevent or resetevent function. Oh, it seems that God cares for me!