Threads Functions

These functions start or stop threads, or return the thread number.