main function is now executed as kosmos thread
This commit is contained in:
@@ -16,10 +16,7 @@
|
||||
#include "list.h"
|
||||
#include "shell.h"
|
||||
|
||||
#define TH_STACK_SIZE 256
|
||||
stack_t th_stack[TH_STACK_SIZE];
|
||||
struct thread_context th_ctx;
|
||||
static void th_func(void *arg)
|
||||
int main(void)
|
||||
{
|
||||
drv_open(&pwm_1);
|
||||
drv_open(&pwm_2);
|
||||
@@ -41,13 +38,6 @@ static void th_func(void *arg)
|
||||
sleep_ms(10);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
int main(void)
|
||||
{
|
||||
board_init();
|
||||
thread_create(&th_ctx, th_stack, TH_STACK_SIZE, th_func, NULL, THREAD_PRIO_LOW);
|
||||
schedule_start();
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
Reference in New Issue
Block a user