123
Fork of LG by
Diff: DeviceCCS.h
- Revision:
- 198:78dd6d14d108
- Parent:
- 197:7a05523bf588
diff -r 7a05523bf588 -r 78dd6d14d108 DeviceCCS.h --- a/DeviceCCS.h Wed Oct 19 10:55:05 2016 +0000 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,35 +0,0 @@ -#ifndef __DEVICE_CCS_H__ -#define __DEVICE_CCS_H__ - -typedef struct _DeviceCCSTransferFunction { - int32_t points; //Used points count - int32_t raw[16]; //Current - ADC code - int32_t mA[16]; //Current - mA in 16.16 format -} DeviceCCSTransferFunction; - -typedef struct _DeviceCCSCurrentSettings { - DeviceCCSTransferFunction transfer; -} DeviceCCSCurrentSettings; - -typedef struct _DeviceCCSCurrentState { - int32_t sum; //Sum of last 32 current measurements - ADC code - int32_t raw; //Average current - ADC code - int32_t mA; //Average current - degrees in 16.16 format -} DeviceCCSCurrentState; - -typedef struct _DeviceCCSCurrent { - DeviceCCSCurrentSettings settings; - DeviceCCSCurrentState state; -} DeviceCCSCurrent; - -typedef struct _DeviceCCS { - DeviceCCSCurrent current[2]; -} DeviceCCS; - -void InitCCSDefaultSettings(void); -void InitCCSState(void); -void DeviceStartCCS(void); - -void ccsProcess(void); - -#endif /* __DEVICE_CCS_H__ */ \ No newline at end of file