AutosarOS
App.c File Reference

Application code for resource management test procedure 1. More...

#include "assert.h"
#include "OS_API.h"
#include <avr/io.h>
#include <util/delay.h>
Include dependency graph for App.c:

Go to the source code of this file.

Macros

#define DELAY_MS(ms)   _delay_ms(ms)
 

Functions

 TASK (Idle)
 
 TASK (Task1)
 
void StartupHook (void)
 
void ShutdownHook (StatusType error)
 
void PreTaskHook (void)
 PreTask hook function. More...
 
void PostTaskHook (void)
 PostTask hook function. More...
 
void ErrorHook (StatusType error)
 PostTask hook function. More...
 
 ISR (INT0_vect)
 
 ISR (TIMER2_OVF_vect)
 

Variables

volatile bool isrFlag = false
 

Detailed Description

Application code for resource management test procedure 1.

Date
2020-07-16
Author
Pascal Romahn

Definition in file App.c.

Macro Definition Documentation

◆ DELAY_MS

#define DELAY_MS (   ms)    _delay_ms(ms)

Definition at line 24 of file App.c.

Function Documentation

◆ ErrorHook()

void ErrorHook ( StatusType  error)

PostTask hook function.

This hook function is called when a system service return StatusType not equal E_OK.

Warning
This function is executed with interrupts disabled and must not activate them!
Parameters
errorError that caused the ErrorHook to be called.

Definition at line 159 of file App.c.

◆ ISR() [1/2]

ISR ( INT0_vect  )

Definition at line 164 of file App.c.

◆ ISR() [2/2]

ISR ( TIMER2_OVF_vect  )

Definition at line 177 of file App.c.

◆ PostTaskHook()

void PostTaskHook ( void  )

PostTask hook function.

This hook function is called before a task leaves the running state but before a new task is selected. The ID of the task can be evaluated using OS_GetTaskID().

Warning
This function is executed with interrupts disabled and must not activate them!

Definition at line 151 of file App.c.

◆ PreTaskHook()

void PreTaskHook ( void  )

PreTask hook function.

This hook function is called after a new task has entered the running state but before it is executed. The ID of the task can be evaluated using OS_GetTaskID().

Warning
This function is executed with interrupts disabled and must not activate them!

Definition at line 143 of file App.c.

◆ ShutdownHook()

void ShutdownHook ( StatusType  error)

Definition at line 132 of file App.c.

◆ StartupHook()

void StartupHook ( void  )

Definition at line 92 of file App.c.

◆ TASK() [1/2]

TASK ( Idle  )

Definition at line 29 of file App.c.

◆ TASK() [2/2]

TASK ( Task1  )

Definition at line 34 of file App.c.

Variable Documentation

◆ isrFlag

volatile bool isrFlag = false

Definition at line 27 of file App.c.