Subversion Repositories EDIS_Ignition

Rev

Rev 10 | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 10 Rev 23
Line 17... Line 17...
17
 
17
 
18
#if defined __cplusplus
18
#if defined __cplusplus
19
extern "C"
19
extern "C"
20
{
20
{
21
#endif
21
#endif
-
 
22
 
22
#pragma pack(push, 1)
23
#pragma pack(push, 1)
23
 
24
 
24
    ///\brief State of item
25
    ///\brief State of item
25
    /// this is expected to be packed into 16 bits 
26
    /// this is expected to be packed into 16 bits 
26
    typedef union
27
    typedef union
27
    {
28
    {
28
        struct
29
        struct
29
        {
30
        {
30
            unsigned tag : 8;
31
            unsigned tag : 8;
-
 
32
            unsigned filler;
31
            int val : 8;
33
            int val : 16;
32
        } data;
34
        } data;
33
        uint16_t u16;
35
        uint32_t word;
34
    } nvram_info_t;
36
    } nvram_info_t;
35
#pragma pack(pop)
37
#pragma pack(pop)
36
 
-
 
-
 
38
    typedef nvram_info_t CF_DATA;
37
 
39
 
38
    // Save data according to its tag field
40
    // Save data according to its tag field
39
    extern void write_nvram_data(nvram_info_t data);
41
    extern void write_nvram_data(nvram_info_t data);
40
 
42
 
41
    // find data according to the tag field or return null if no info
43
    // find data according to the tag field or return null if no info