mruby/c VM Source Code release 3.4
Loading...
Searching...
No Matches
rrt0.h File Reference

Realtime multitask monitor for mruby/c. More...

#include "vm.h"
Include dependency graph for rrt0.h:

Go to the source code of this file.

Data Structures

struct  RTcb
 Task control block. More...
struct  RMutex
 Mutex. More...

Macros

#define MRBC_TASK_NAME_LEN   15
#define MRBC_MUTEX_INITIALIZER   { 0 }

Typedefs

typedef struct RTcb mrbc_tcb
 Task control block.
typedef struct RMutex mrbc_mutex
 Mutex.

Enumerations

enum  MrbcTaskState {
  TASKSTATE_DORMANT = 0x00 , TASKSTATE_READY = 0x02 , TASKSTATE_RUNNING = 0x03 , TASKSTATE_WAITING = 0x04 ,
  TASKSTATE_SUSPENDED = 0x08
}
 Task state. More...
enum  MrbcTaskReason { TASKREASON_SLEEP = 0x01 , TASKREASON_MUTEX = 0x02 , TASKREASON_JOIN = 0x04 }

Variables

static const int MRBC_TASK_DEFAULT_PRIORITY = 128
static const int MRBC_TASK_DEFAULT_STATE = TASKSTATE_READY

Detailed Description

Realtime multitask monitor for mruby/c.

Copyright (C) 2015- Kyushu Institute of Technology.
Copyright (C) 2015- Shimane IT Open-Innovation Center.

This file is distributed under BSD 3-Clause License.

Definition in file rrt0.h.

Macro Definition Documentation

◆ MRBC_MUTEX_INITIALIZER

#define MRBC_MUTEX_INITIALIZER   { 0 }

Definition at line 104 of file rrt0.h.

◆ MRBC_TASK_NAME_LEN

#define MRBC_TASK_NAME_LEN   15

Definition at line 59 of file rrt0.h.

Typedef Documentation

◆ mrbc_mutex

typedef struct RMutex mrbc_mutex

Mutex.

◆ mrbc_tcb

typedef struct RTcb mrbc_tcb

Task control block.

Enumeration Type Documentation

◆ MrbcTaskReason

Enumerator
TASKREASON_SLEEP 
TASKREASON_MUTEX 
TASKREASON_JOIN 

Definition at line 49 of file rrt0.h.

◆ MrbcTaskState

Task state.

(Bit mapped) 0 0 0 0 0 0 0 0 ^ Running ^ Ready ^ Waiting ^ Suspended

Enumerator
TASKSTATE_DORMANT 

Domant.

TASKSTATE_READY 

Ready.

TASKSTATE_RUNNING 

Running.

TASKSTATE_WAITING 

Waiting.

TASKSTATE_SUSPENDED 

Suspended.

Definition at line 41 of file rrt0.h.

Variable Documentation

◆ MRBC_TASK_DEFAULT_PRIORITY

const int MRBC_TASK_DEFAULT_PRIORITY = 128
static

Definition at line 55 of file rrt0.h.

◆ MRBC_TASK_DEFAULT_STATE

const int MRBC_TASK_DEFAULT_STATE = TASKSTATE_READY
static

Definition at line 56 of file rrt0.h.