aboutsummaryrefslogtreecommitdiffstats
path: root/Software/Embedded_SW/Embedded/StateMachines/Initialization/PowerOffSequence.h
blob: 5f347c5ba4fd43903da9b18da0b8b4ad63394af4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
/*
 * PowerOffSequence.h
 *
 *  Created on: Apr 2, 2019
 *      Author: shlomo
 */

#ifndef STATEMACHINES_INITIALIZATION_POWEROFFSEQUENCE_H_
#define STATEMACHINES_INITIALIZATION_POWEROFFSEQUENCE_H_

    typedef enum
    {
        POWER_OFF_INIT,
        POWER_OFF_STOP_RUNNING_JOB,
        POWER_OFF_HEAD_CLEAN,
        POWER_OFF_MIXER_FLUSH,
        POWER_OFF_HEATERS_OFF,
        POWER_OFF_STORE_DATA,
        POWER_OFF_SET_VALVE_POSITION,
        POWER_OFF_WAIT_FOR_TEMPERATURE,
        POWER_OFF_WAIT_FOR_PROCESSES,//wait for waste emptying, ink filling, thread loading
        POWER_OFF_TURN_OFF_DRYER_FAN,
        POWER_OFF_TURN_OFF_COOLER,
        POWER_OFF_TURN_OFF_BLOWER,
        POWER_OFF_POWER_OFF,
        POWER_OFF_ERROR,
        POWER_OFF_CANCELLED,
        POWER_OFF_MAX,
    }POWER_OFF_STAGES_ENUM;


uint32_t PowerOffInit(void);
uint32_t PowerOffCancel(void);//POWER_OFF_CANCELLED
void PowerOffSetTemperatureThreshold (int32_t temperature); //celsius temperature

bool PowerOffInProcessGetState(void);
uint32_t PowerOffHeatersOff(void);

uint32_t PowerDownUpdateFunc(MessageContainer* requestContainer);
uint32_t AbortPowerDownFunc(MessageContainer* requestContainer);


#endif /* STATEMACHINES_INITIALIZATION_POWEROFFSEQUENCE_H_ */