monoZ docs
MZ_app1_instance.c
Go to the documentation of this file.
1
8#include "MZ_sys_cmsis_os2.h"
9#include "MZ_app1_instance.h"
10
11#define APP1_STACK_SIZE (128)
12
14static StaticTask_t app1_cb_mem;
15static StackType_t app1_stack[APP1_STACK_SIZE];
22static void app1_scheduler(void * arg)
23{
24 (void)arg;
25
26 /* Place code here That need to run once during application start */
27
28 /*
29 * This is the infinite loop for this thread - the thread will execute this
30 * loop forever and not come outside of this loop
31 */
32 while(1)
33 {
34 /* Need to write the periodic executing logic in this loop block */
35 __NOP();
36
37 }//End of while(1) - Do not place any code after this.
38}
39
41{
42 mz_error_t _ret = MZ_OK;
43 // Create the Application thread
45 "App1 Scheduler",
47 NULL,
48 osPriorityNormal,
52 sizeof(app1_cb_mem)))
53 {
55 }
56 return _ret;
57}
static void app1_scheduler(void *arg)
App1 Scheduler.
static StackType_t app1_stack[APP1_STACK_SIZE]
static StaticTask_t app1_cb_mem
#define APP1_STACK_SIZE
Defines APP stack Size.
static mz_thread_t app1_thread_id
mz_error_t mz_app1_init(void)
Initiate Monoz App1.
This is a tool generated file. Edit it as per requirement.
mz_error_t
Enumeration of monoZ Error Flags.
@ MZ_THREAD_CREATE_FAIL
@ MZ_OK
monoZ system CMSIS OS2 This is an abstraction layer and includes FreeRTOS configuration,...
osThreadId_t mz_thread_t
mz_thread_t variable of type osThreadId_t
uint8_t mz_thread_create(mz_thread_t *t, const char *name, mz_fn thread_func, void *const arg, mz_thread_prio_t prio, StackType_t *stack_mem, size_t stack_size, StaticTask_t *cb_mem, uint32_t cb_size)
This function is used to check the message queue object validity Create a thread and add it to Active...