You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
42 lines
766 B
42 lines
766 B
![]()
9 years ago
|
/*
|
||
|
* Copyright (C) 2013 INRIA
|
||
|
*
|
||
|
* This file is subject to the terms and conditions of the GNU Lesser General
|
||
|
* Public License. See the file LICENSE in the top level directory for more
|
||
|
* details.
|
||
|
*/
|
||
|
|
||
|
/**
|
||
|
* @ingroup tests
|
||
|
* @{
|
||
|
*
|
||
|
* @file
|
||
|
* @brief Thread test application
|
||
|
*
|
||
|
* @author Oliver Hahm <oliver.hahm@inria.fr>
|
||
|
*
|
||
|
* @}
|
||
|
*/
|
||
|
|
||
![]()
9 years ago
|
#include <stdio.h>
|
||
![]()
9 years ago
|
#include "thread.h"
|
||
![]()
9 years ago
|
|
||
![]()
9 years ago
|
char t2_stack[KERNEL_CONF_STACKSIZE_MAIN];
|
||
![]()
9 years ago
|
|
||
![]()
9 years ago
|
void *second_thread(void *arg)
|
||
![]()
9 years ago
|
{
|
||
![]()
9 years ago
|
(void) arg;
|
||
![]()
9 years ago
|
puts("second thread\n");
|
||
![]()
9 years ago
|
return NULL;
|
||
![]()
9 years ago
|
}
|
||
|
|
||
|
int main(void)
|
||
|
{
|
||
![]()
9 years ago
|
(void) thread_create(
|
||
|
t2_stack, sizeof(t2_stack),
|
||
|
PRIORITY_MAIN - 1, CREATE_WOUT_YIELD | CREATE_STACKTEST,
|
||
![]()
9 years ago
|
second_thread, NULL, "nr2");
|
||
![]()
9 years ago
|
puts("first thread\n");
|
||
![]()
9 years ago
|
return 0;
|
||
![]()
9 years ago
|
}
|