aboutsummaryrefslogtreecommitdiffstats
path: root/policy_manager/stm/zipc/StateTransitionor/HomeScreenLayer/ZHSL_HomeScreen.c
blob: 1375c66ddb902f12c5bcf2be22ea1fcff69c96ad (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
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
/************************************************************/
/*     ZHSL_HomeScreen.c                                    */
/*     HomeScreen State transition model source file        */
/*     ZIPC Designer Version 1.2.0                          */
/************************************************************/
#include "../ZST_include.h"

/* State management variable */
static uint8_t ZHSL_HomeScreenState[ZHSL_HOMESCREENSTATENOMAX];

static void ZHSL_HomeScreens0e0( void );
static void ZHSL_HomeScreens0Event( void );
static void ZHSL_HomeScreens1Event( void );

/****************************************/
/* Action function                      */
/*   STM : HomeScreen                   */
/*   State : none( No 0 )               */
/*   Event : ara_fullscreen( No 0 )     */
/****************************************/
static void ZHSL_HomeScreens0e0( void )
{
    ZHSL_HomeScreenState[ZHSL_HOMESCREEN] = ( uint8_t )ZHSL_HOMESCREENS1;
    stm_hsl_start_activity_homescreen();
}

/****************************************/
/* Event appraisal function             */
/*   STM : HomeScreen                   */
/*   State : none( No 0 )               */
/****************************************/
static void ZHSL_HomeScreens0Event( void )
{
    /*evt_activate*/
    if( g_stm_event == StmEvtNoActivate )
    {
        /*ctg_homescreen*/
        if( g_stm_category == StmCtgNoHomescreen )
        {
            /*ara_fullscreen*/
            if( g_stm_area == StmAreaNoFullscreen )
            {
                ZHSL_HomeScreens0e0();
            }
            else
            {
                /*Else and default design have not done.*/
                /*Please confirm the STM and design else and default.*/
            }
        }
        else
        {
            /*Else and default design have not done.*/
            /*Please confirm the STM and design else and default.*/
        }
    }
    else
    {
        /*Else and default design have not done.*/
        /*Please confirm the STM and design else and default.*/
    }
}

/****************************************/
/* Event appraisal function             */
/*   STM : HomeScreen                   */
/*   State : homescreen( No 1 )         */
/****************************************/
static void ZHSL_HomeScreens1Event( void )
{
}

/****************************************/
/* Event call function                  */
/*   STM : HomeScreen                   */
/****************************************/
void stm_hsl_event_call( void )
{
    stm_hsl_start_stm();
    switch( ZHSL_HomeScreenState[ZHSL_HOMESCREEN] )
    {
    case ZHSL_HOMESCREENS0:
        ZHSL_HomeScreens0Event();
        break;
    case ZHSL_HOMESCREENS1:
        ZHSL_HomeScreens1Event();
        break;
    default:
        /*Not accessible to this else (default).*/
        break;
    }
}

/****************************************/
/* Initial function                     */
/*   STM : HomeScreen                   */
/****************************************/
void stm_hsl_initialize( void )
{
    ZHSL_HomeScreenState[ZHSL_HOMESCREEN] = ( uint8_t )ZHSL_HOMESCREENS0;
    stm_hsl_start_activity_none();
}

/****************************************/
/* Terminate function                   */
/*   STM : HomeScreen                   */
/****************************************/
void ZHSL_HomeScreenTerminate( void )
{
    ZHSL_HomeScreenState[ZHSL_HOMESCREEN] = ( uint8_t )ZHSL_HOMESCREENTERMINATE;
}