| ISF 2.2 rev 5 Intelligent Sensing Framework for Kinetis with Processor Expert

- Main Page
- Modules
- Data Structures
- Files

- File List
- Globals

sensor_data_types.h
Go to the documentation of this file.
1 /*
2 *
3 * Copyright (c) 2015, Freescale Semiconductor, Inc.
4 *
5 */
6 /*
7 * sensor_data_types.h
8 *
9 * Created on: Nov 26, 2013,
10 * Author: B37804
11 */
12
13 #ifndef SENSOR_DATA_TYPES_H_
14 #define SENSOR_DATA_TYPES_H_
15
16 #include "basic_types.h"
17 #include "fusion_config.h"
18
19 // gyro sensor structure definition
20 struct PressureSensor
21 {
22 int32 iH; // most recent unaveraged height (counts)
23 int32 iP; // most recent unaveraged pressure (counts)
24 float fH; // most recent unaveraged height (m)
25 float fT; // most recent unaveraged temperature (C)
26 float fmPerCount; // meters per count
27 float fCPerCount; // degrees Celsius per count
28 int16 iT; // most recent unaveraged temperature (counts)
29 uint8 iWhoAmI; // sensor whoami
30 };
31
32 // accelerometer sensor structure definition
33 struct AccelSensor
34 {
35 //float fSumGpFast[3]; // sum of fast measurements
36 float fGs[3]; // most recent unaveraged measurement (counts)
37 float fGsAvg[3]; // averaged measurement (g)
38 float fgPerCount; // g per count
39 int16 iGsBuffer[ACCEL_OVERSAMPLE_RATIO][3]; // buffered measurements (counts)
40 int16 iGs[3]; // most recent unaveraged measurement (counts)
41 int16 iGsAvg[3]; // averaged measurement (counts)
42 int16 iCountsPerg; // counts per g
43 uint8 iWhoAmI; // sensor whoami
44 };
45
46 // magnetometer sensor structure definition
47 struct MagSensor
48 {
49 //float fSumBpFast[3]; // sum of fast measurements
50 float fBs[3]; // most recent unaveraged uncalibrated measurement (counts)
51 float fBsAvg[3]; // averaged un-calibrated measurement (uT)
52 float fBcAvg[3]; // averaged calibrated measurement (uT)
53 float fuTPerCount; // uT per count
54 float fCountsPeruT; // counts per uT
55 int16 iBsBuffer[MAG_OVERSAMPLE_RATIO][3]; // buffered uncalibrated measurement (counts)
56 int16 iBs[3]; // most recent unaveraged uncalibrated measurement (counts)
57 int16 iBsAvg[3]; // averaged uncalibrated measurement (counts)
58 int16 iBcAvg[3]; // averaged calibrated measurement (counts)
59 int16 iCountsPeruT; // counts per uT
60 uint8 iWhoAmI; // sensor whoami
61 };
62
63 // gyro sensor structure definition
64 struct GyroSensor
65 {
66 float fDegPerSecPerCount; // deg/s per count
67 float fYpBuffer[GYRO_OVERSAMPLE_RATIO][3]; // buffered sensor frame measurements (counts)
68 int16 iYsBuffer[GYRO_OVERSAMPLE_RATIO][3]; // buffered sensor frame measurements (counts)
69 int16 iCountsPerDegPerSec; // counts per deg/s
70 int16 iYs[3]; // most recent sensor frame measurement (counts)
71 uint8 iWhoAmI; // sensor whoami
72 };
73
74 // SampleData structure definition
75 struct sensorSampleData
76 {
77 struct PressureSensor pressureData;
78 struct AccelSensor AccelData;
79 struct MagSensor magData;
80 struct GyroSensor gyroData;
81 };
82
83 #endif /* SENSOR_DATA_TYPES_H_ */
84
PressureSensor::fCPerCount
float fCPerCount
Definition: sensor_data_types.h:27
AccelSensor::fgPerCount
float fgPerCount
Definition: sensor_data_types.h:38
PressureSensor::iT
int16 iT
Definition: sensor_data_types.h:28
uint8
unsigned char uint8
Definition: isf_types.h:76
MagSensor::iBsAvg
int16 iBsAvg[3]
Definition: sensor_data_types.h:57
PressureSensor::fmPerCount
float fmPerCount
Definition: sensor_data_types.h:26
GyroSensor::fDegPerSecPerCount
float fDegPerSecPerCount
Definition: sensor_data_types.h:66
PressureSensor::iH
int32 iH
Definition: sensor_data_types.h:22
sensorSampleData::gyroData
struct GyroSensor gyroData
Definition: sensor_data_types.h:80
MagSensor::iBcAvg
int16 iBcAvg[3]
Definition: sensor_data_types.h:58
PressureSensor::fH
float fH
Definition: sensor_data_types.h:24
AccelSensor::iGsAvg
int16 iGsAvg[3]
Definition: sensor_data_types.h:41
AccelSensor::iWhoAmI
uint8 iWhoAmI
Definition: sensor_data_types.h:43
MagSensor::fuTPerCount
float fuTPerCount
Definition: sensor_data_types.h:53
MagSensor::iBs
int16 iBs[3]
Definition: sensor_data_types.h:56
GYRO_OVERSAMPLE_RATIO
#define GYRO_OVERSAMPLE_RATIO
Definition: fusion_config.h:25
MagSensor::fBsAvg
float fBsAvg[3]
Definition: sensor_data_types.h:51
basic_types.h
AccelSensor::iGsBuffer
int16 iGsBuffer[ACCEL_OVERSAMPLE_RATIO][3]
Definition: sensor_data_types.h:39
PressureSensor::iP
int32 iP
Definition: sensor_data_types.h:23
sensorSampleData
Definition: sensor_data_types.h:75
AccelSensor
Definition: sensor_data_types.h:33
MagSensor
Definition: sensor_data_types.h:47
sensorSampleData::pressureData
struct PressureSensor pressureData
Definition: sensor_data_types.h:77
GyroSensor::iYsBuffer
int16 iYsBuffer[GYRO_OVERSAMPLE_RATIO][3]
Definition: sensor_data_types.h:68
sensorSampleData::magData
struct MagSensor magData
Definition: sensor_data_types.h:79
PressureSensor::fT
float fT
Definition: sensor_data_types.h:25
MagSensor::fBs
float fBs[3]
Definition: sensor_data_types.h:50
MAG_OVERSAMPLE_RATIO
#define MAG_OVERSAMPLE_RATIO
Definition: fusion_config.h:24
MagSensor::iWhoAmI
uint8 iWhoAmI
Definition: sensor_data_types.h:60
int16
signed short int int16
Definition: isf_types.h:73
AccelSensor::fGs
float fGs[3]
Definition: sensor_data_types.h:36
AccelSensor::iGs
int16 iGs[3]
Definition: sensor_data_types.h:40
GyroSensor::fYpBuffer
float fYpBuffer[GYRO_OVERSAMPLE_RATIO][3]
Definition: sensor_data_types.h:67
fusion_config.h
The fusion_config.h file contains additional static configuration for the Sensor Fusion based Virtual...
MagSensor::iCountsPeruT
int16 iCountsPeruT
Definition: sensor_data_types.h:59
AccelSensor::iCountsPerg
int16 iCountsPerg
Definition: sensor_data_types.h:42
GyroSensor::iYs
int16 iYs[3]
Definition: sensor_data_types.h:70
GyroSensor::iWhoAmI
uint8 iWhoAmI
Definition: sensor_data_types.h:71
int32
signed long int int32
Definition: isf_types.h:74
GyroSensor::iCountsPerDegPerSec
int16 iCountsPerDegPerSec
Definition: sensor_data_types.h:69
sensorSampleData::AccelData
struct AccelSensor AccelData
Definition: sensor_data_types.h:78
AccelSensor::fGsAvg
float fGsAvg[3]
Definition: sensor_data_types.h:37
MagSensor::iBsBuffer
int16 iBsBuffer[MAG_OVERSAMPLE_RATIO][3]
Definition: sensor_data_types.h:55
MagSensor::fCountsPeruT
float fCountsPeruT
Definition: sensor_data_types.h:54
ACCEL_OVERSAMPLE_RATIO
#define ACCEL_OVERSAMPLE_RATIO
Definition: fusion_config.h:23
PressureSensor::iWhoAmI
uint8 iWhoAmI
Definition: sensor_data_types.h:29
GyroSensor
Definition: sensor_data_types.h:64
MagSensor::fBcAvg
float fBcAvg[3]
Definition: sensor_data_types.h:52
PressureSensor
Definition: sensor_data_types.h:20
- © Freescale Semiconductor, Inc. 2016. All Rights Reserved.