Subversion Repositories FlightCtrl

Rev

Rev 1994 | Rev 2000 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 1994 Rev 1995
Line 1... Line 1...
1
#ifndef _CAPACITY_H
1
#ifndef _CAPACITY_H
2
#define _CAPACITY_H
2
#define _CAPACITY_H
3
 
3
 
4
typedef struct
4
typedef struct
5
{
5
{
6
        unsigned short ActualCurrent; // in 0.1A Steps
6
        unsigned short ActualCurrent; // in 0.1A Steps
7
        unsigned short ActualPower;   // in 0.1W
7
        unsigned short ActualPower;   // in 0.1W
8
        unsigned short UsedCapacity;  // in mAh
8
        signed short UsedCapacity;  // in mAh           //Modified  by metro
-
 
9
        signed short RemainCapacity;  // in mAh //Added by metro
9
        unsigned char MinOfMaxPWM;        // BL Power Limit
10
        unsigned char MinOfMaxPWM;        // BL Power Limit
10
} __attribute__((packed)) Capacity_t;
11
} __attribute__((packed)) Capacity_t;
11
 
12
 
12
extern Capacity_t Capacity;
13
extern Capacity_t Capacity;
13
 
14
 
14
void Capacity_Init(void);
15
void Capacity_Init(void);
15
void Capacity_Update(void);
16
void Capacity_Update(void);
16
 
17
 
17
#endif //_CAPACITY_H
18
#endif //_CAPACITY_H
18
 
19