/*
 * threadwrap.c
 *
 *  Created on: 15.04.2011
 *      Author: uwe
 */

unsigned int MAXTHREADS = 32;
unsigned int USETHREADS = 2;

unsigned int get_MAXTHREADS()
{
	return MAXTHREADS;
}
unsigned int get_USETHREADS()
{
	return USETHREADS;
}
void set_MAXTHREADS(unsigned int i)
{
	if(i < 100 && i > 0){
		MAXTHREADS = i;
		if(MAXTHREADS < USETHREADS){
			USETHREADS = MAXTHREADS;
		}
	}
}
void set_USETHREADS(unsigned int i)
{
	if(i <= MAXTHREADS){
		USETHREADS = i;
	}else{
		USETHREADS = MAXTHREADS;
	}
}
