Safety condition handling and (flash) memory tests. More...
#include <avr/io.h>#include <avr/wdt.h>#include <avr/pgmspace.h>#include <avr/interrupt.h>#include "xtypes.h"#include "global.h"#include "fan.h"#include "relay.h"#include "safety.h"
Go to the source code of this file.
Defines | |
| #define | EXPORT |
Functions | |
| void | safety_Init (void) |
| Init function of safety module. | |
| void | safety_SetCondition (E_SAFETY_CONDITION eCond) |
| Set method for mg_eCondition. | |
| void | safety_ClearCondition (E_SAFETY_CONDITION eCond) |
| Clear method for mg_eCondition. | |
| UINT32 | safety_GetCRC (void) |
| Get method for mg_u32ApplCRC. | |
| E_SAFETY_CONDITION | safety_GetCondition (void) |
| Get method for mg_eCondition. | |
| void | safety_MemoryTest (void) |
| Continue flash memory test. | |
| void | safety_SafeMode (void) |
| Safe mode of entire system. | |
Variables | |
| static E_SAFETY_CONDITION | mg_eCondition = COND_OK |
| Variable to hold the current safety status. | |
| static UINT16 | mg_u16MemIdx = 0U |
| Index variable for flash memory testing. Equates a byte address. | |
| static UINT32 | mg_u32CalcCRC = 0xFFFFFFFFUL |
| Variable to hold the calculated memory CRC value. | |
| static UINT32 | mg_u32ApplCRC = 0x00000000UL |
| Variable to hold the stored memory CRC value. Will be set only once in the init function of this module. | |
This module provides a common interface to handle safety conditions and functionality to perform memory tests.
Definition in file safety.c.
1.7.2