tasks, processes, threads
One of the main problems faced by embedded applications is how to assign processors to different tasks. In real-time operating systems, processes and threads are sometimes used instead of tasks. A process is a completely independent program with its own address space, which is a semi-independent program segment that executes within a process. Multiple threads share the address space of the owning process, and the expense of thread management is small.
---------------
threads are counting output, and the results are similar to the following: X: 1 of T2X: 1 of T1X: 1 in the main threadX: 2 of T2X: 2 of T1X: 2 in the main threadX: 3 of T2X: 3 of T1X: 3 in the main threadX: 4 of T2X: 4 of T1X: 4 in the main threadX: 5 of T2X: 5 of T1X: 5 in the main thread The order of the three th
I. It is best to use the _ beginthreadex () function in the C ++ Runtime Library to create a process. _ beginthreadex is implemented using createthread, but some processing is done for the c ++ language. For details, see chapter 6th of Windows core programming.
# Pragma once # include
Use remusethread () to continue executing the process: Call the waitforsingleobject () function to let the main thread wait for the sub-thread.
Class threadx {int loops
Document directory
5 can the MiniGUI be directly transplanted to various embedded panels?
1. Which operating systems can the MiniGUI run on? 1.1 short answer
MiniGUI can run on Linux, uClinux, VxWorks, threadx, ECOs, nucleus, uC/OS-II, PSOs, ose, and other operating systems and Win32 platforms. At the same time, MiniGUI on different operating systems provides fully compatible API interfaces.1.2 long answer
Theoretically, MiniGUI can run on any embe
the system runs a long time, by sorting the program name can help the administrator to find their own program of interest. But this is still not the easiest way. As the system administrator in other operating systems now found a trojan called ThreadX in the background of the system to run. For this reason the administrator needs to see if there is a trojan running on the other computer. What should be done at this point? Sort the name of the program
time, by sorting the program name can help the administrator to find their own program of interest. But this is still not the easiest way. As the system administrator in other operating systems now found a trojan called ThreadX in the background of the system to run. For this reason the administrator needs to see if there is a trojan running on the other computer. What should be done at this point? Sort the name of the program using the Sort function
shortage of mtk pa in the second half of the year and taking advantage of the market share of mtk. The development mode of Zhan Xun is similar to that of MTK. It basically provides the overall solution for the manufacturer. For the difference with MTK, see http://www.chinabyte.com/telecom/267/2504177.shtml. In China, xiaxin, Lenovo, and Wentai use the spreadtrum platform. The embedded operating system adopted by the Zhan Xun platform is threadx.
platform. The embedded operating system adopted by the Zhan Xun platform is threadx. threadx has a book titled multi-thread computing of embedded real-time operating systems: Based on threadx and arm. Similar to the MTK platform, it is a closed platform with a development language of C and a development environment of vc6. The control and window of MMI communica
their own program of interest. But this is still not the easiest way. As the system administrator in other operating systems now found a trojan called ThreadX in the background of the system to run. For this reason the administrator needs to see if there is a trojan running on the other computer. What should be done at this point? Sort the name of the program using the Sort function (note that the PID is not sorted by the program, because the PID num
zdnetchina Chinese community http://bbs.zdnet.com.cn, this post address: http://bbs.zdnet.com.cn/viewthread.php? Tid = 251766
5. Zhan Xun:The spreadtrum platform has also developed rapidly in, taking advantage of the shortage of mtk pa in the second half of the year and taking advantage of the market share of MTK. The development mode of Zhan Xun is similar to that of MTK. It basically provides the overall solution for the manufacturer. For the difference with MTK, see http://www.chinabyte.com/
time, by sorting the program name can help the administrator to find their own program of interest. But this is still not the easiest way. As the system administrator in other operating systems now found a trojan called ThreadX in the background of the system to run. For this reason the administrator needs to see if there is a trojan running on the other computer. What should be done at this point? Sort the name of the program using the Sort function
time, by sorting the program name can help the administrator to find their own program of interest. But this is still not the easiest way. As the system administrator in other operating systems now found a trojan called ThreadX in the background of the system to run. For this reason the administrator needs to see if there is a trojan running on the other computer. What should be done at this point? Sort the name of the program using the Sort function
system. It is often impossible for a system administrator to master so many parameters and the difference between the case of the parameter. In addition to using commonly used parameters to increase the impression of the value of the system administrator, this system command online help is indeed indispensable. This system help provides an online guide for administrators to use system commands.V. Reporting on the operation of specific programs.When the system runs a long time, by sorting the pr
. But this is still not the easiest way. As the system administrator in other operating systems now found a trojan called ThreadX in the background of the system to run. For this reason the administrator needs to see if there is a trojan running on the other computer. What should be done at this point? Sort the name of the program using the Sort function (note that the PID is not sorted by the program, because the PID number is different, even if the
master so many parameters and the difference between the case of the parameter. In addition to using commonly used parameters to increase the impression of the value of the system administrator, this system command online help is indeed indispensable. This system help provides an online guide for administrators to use system commands.V. Reporting on the operation of specific programs.When the system runs a long time, by sorting the program name can help the administrator to find their own progr
In multi-threaded programs, we often encounter this situation, the main thread starts loading some parameters into the memory of an object or data structure, the object or data structure as parameters passed into each sub-thread, in order to avoid the copying and copy of the object, often passed pointer, sub-thread start, business logic processing, You need to get Value,value = M_pparam->get (key) in Hashtable based on the key value, as shown in the code below//run the required parameters with t
() method returns True, it cannot distinguish between a ready state, a blocking state, or a running state.Precautions:For any state, if the invoked method and state do not match, it can cause illegal state handling exceptions. Like what. When a line isconcurrently is created, only the start () or stop () method can be invoked, which can cause illegal state processing if other methods are invoked.
Sleep methodYou can invoke the static method of thread:public static void sleep (Long mills) throws
. threadGroup groupForThreadX = threadX. getThreadGroup (); groupForThreadX is a reference to the ThreadGroup that threadX belongs. if a thread is no longer alive, getThreadGroup () returns null instead of a ThreadGroup. to determine which thread group the thread executing a block of code belongs to, use: ThreadGroup group = Thread. currentThread (). getThreadGroup ();
ActiveCount ()The activeCount () metho
;\ /X/ \Thread Y:---channel B (event B1)--"channel A (event A2)---channel A (event A3)--->However, this also has a disadvantage, when the first channelevent in the same channel is not finished, then the next channelevent will not be executed.There is also a point to note: Not that channela this call is THREADX, the next time the channelevent will still call THREADX, this cannot be guaranteed.A different way
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.