Protothreads are a type of extremely lightweight, stackless threads written in 100% portable C. While protothreads were originally designed for severely memory-constrained systems such as deeply embedded systems, they have found a number of uses as a general purpose portable library as well.
| Tags | Software Development Embedded Systems Libraries |
|---|---|
| Licenses | BSD Revised |
| Operating Systems | OS Independent |
| Implementation | C |
Recent releases


Changes: PT_SCHEDULE() now returns true both when a protothread is waiting and when it has yielded. A README file has been added for Visual C++ users that explains how protothreads may trigger a compiler bug and how to prevent this from happening.


Changes: It is now possible to determine if a protothread is waiting, or has yielded, exited, or ended by looking at the return value of a protothread function.


Changes: This release fixes a typo in example-buffer.c so that the examples now compile cleanly.


Changes: A missing parenthesis in the implementation of PT_SCHEDULE() that could cause problems has been fixed. The PT_YIELDING() macro is no longer needed inside a protothread that yields.


Changes: This release adds PT_YIELD() functionality that allows a protothread to yield the CPU. PT_SPAWN() now properly takes two pt state structures as parameters. The examples should compile under MS Windows.