chenlh
2026-01-20 fe4d335b54ede7a47fd4bcf5c228fb427cbcc8c9
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
/*
 * gvar_state.h
 *
 *  Created on: 2025Äê7ÔÂ23ÈÕ
 *      Author: 86189
 */
 
#ifndef VAR_STATE_H_
#define VAR_STATE_H_
 
#include "typedefs.h"
#include "scene.h"
#include "config.h"
 
//Global variable declaration places here.
class VarState{
private:
public:
    ubool  clock_ok;  //ÊÇ·ñÓÐʱÖÓ
    ubool  TopoLoading = 0;
    ubool  TopoStatus = 0;
    ubool  HandShakeSuccesful = ufalse;
 
    s16 dsp_status =0;
    u16  g_level_report_interval = LEVEL_REPORT_TIME(200); //NLPûÓÃ
 
    Scene* pscene = NULL;
    u32 master_intr =0; //Ö÷ÖжϺÅ,´æÔÚ¶à¸öÖжÏÖ»ÓÐÔÚÖ÷ÖжϺÅÏ²ŽøÐÐÄ£¿é´¦Àí.
 
    static VarState& GetInstance(){
        static VarState _var;
        return _var;
    }
 
    hw_adapter_t* get_hw_adapter()
    {
        if(pscene)
            return pscene->get_base_hw_adapter();
        else
            return NULL;
    }
};
 
 
#endif /* VAR_STATE_H_ */