ISF  2.2 rev 5
Intelligent Sensing Framework for Kinetis with Processor Expert
MMA8491Q_1.c
Go to the documentation of this file.
1 /* ###################################################################
2 ** This component module is generated by Processor Expert. Do not modify it.
3 ** Filename : MMA8491Q_1.c
4 ** CDE edition : Community
5 ** Project : ISF2P2_K64F_MQX_PROJ
6 ** Processor : MK64FN1M0VLL12
7 ** Component : ISF_KSDK_Sensor_MMA8491Q_Accelerometer
8 ** Version : Component 02.500, Driver 01.00, CPU db: 3.00.000
9 ** Repository : My Components
10 ** Compiler : GNU C Compiler
11 ** Date/Time : 2016-10-06, 13:38, # CodeGen: 0
12 ** Abstract :
13 **
14 ** Settings :
15 ** Component Name : MMA8491Q_1
16 ** Device Address : 0x55
17 ** Comm Channel : I2C1
18 ** Allowed Sample Rates : 200Hz
19 ** Sensor_Enable : fsl_gpio
20 ** X_Out : fsl_gpio
21 ** Y_Out : fsl_gpio
22 ** Z_Out : fsl_gpio
23 ** Contents :
24 ** No public methods
25 **
26 ** For non-commercial use only.
27 (c) Copyright <company/user-name>, 2015
28 http://www.<company>.com
29 mail: info@<company>.com
30 ** ###################################################################*/
31 /*!
32 ** @file MMA8491Q_1.c
33 ** @version 01.00
34 ** @brief
35 **
36 */
37 /*!
38 ** @addtogroup MMA8491Q_1_module MMA8491Q_1 module documentation
39 ** @{
40 */
41 
42 /* MODULE MMA8491Q_1. */
43 
44 #include "MMA8491Q_1.h"
45 #include "mma8491q.h"
46 
48 {
49  .padding = 0 //This sensor does not have any configutation registers.
50 };
51 
52 /*!
53  * @brief This creates the sensor adapter instance for the target sensor.
54  *
55  */
57 {
59  .devInfo.pSupportedSensorDataTypes = mma8491q_SupportedDataTypes,
60  .devInfo.nNativeDataSetSize = sizeof(mma8491q_DataBuffer_t),
61  .control.Initialize = &fsl_mma8491q_i2c_3D_accel_Initialize,
62  .control.ValidateSettings = &fsl_mma8491q_i2c_3D_accel_ValidateSettings,
63  .control.Configure = &fsl_mma8491q_i2c_3D_accel_Configure,
64  .control.StartData = &fsl_mma8491q_i2c_3D_accel_StartData,
65  .control.EndData = &fsl_mma8491q_i2c_3D_accel_EndData,
66  .control.Calibrate = &fsl_mma8491q_i2c_3D_accel_Calibrate,
67  .control.Shutdown = &fsl_mma8491q_i2c_3D_accel_Shutdown,
68  .control.Convert = &fsl_mma8491q_i2c_3D_accel_Convert
69 };
70 
71 const i2c_device_t MMA8491Q_1_DeviceInfo =
72 {
73  .baudRate_kbps = 400, // default baud rate (kbps).
74  .address = 85 // instance specific device address.
75 };
76 
77 
78 /* END MMA8491Q_1. */
79 
80 /*!
81 ** @}
82 */
83 /*
84 ** ###################################################################
85 **
86 ** This file was created by Processor Expert 10.5 [05.21]
87 ** for the Freescale Kinetis series of microcontrollers.
88 **
89 ** ###################################################################
90 */
isf_status_t fsl_mma8491q_i2c_3D_accel_Calibrate(isf_SensorHandle_t *pSensorHandle, void *pCalData)
const isf_dsa_Adapter_t MMA8491Q_1_Adapter
This creates the sensor adapter instance for the target sensor.
Definition: MMA8491Q_1.c:56
isf_dsa_status_t fsl_mma8491q_i2c_3D_accel_Shutdown(isf_SensorHandle_t *pSensorHandle)
const i2c_device_t MMA8491Q_1_DeviceInfo
This allows access to the sensor communications specific configuration.
Definition: MMA8491Q_1.c:71
isf_status_t fsl_mma8491q_i2c_3D_accel_EndData(isf_SensorHandle_t *pSensorHandle)
isf_dsa_status_t fsl_mma8491q_i2c_3D_accel_ValidateSettings(isf_SensorHandle_t *pSensorHandle, isf_dsa_SensorSettings_t *pSensorSettings)
mma8491q_Sensor_Specific_Settings_t MMA8491Q_1_Sensor_Specific_Config
This allows access to the sensor specific configuration for the target sensor.
Definition: MMA8491Q_1.c:47
isf_dsa_DeviceInfoBlock_t devInfo
This defines the DSA adapter structure required for static initialization of the concrete instance of...
isf_status_t fsl_mma8491q_i2c_3D_accel_StartData(isf_SensorHandle_t *pSensorHandle)
isf_dsa_status_t fsl_mma8491q_i2c_3D_accel_Configure(isf_SensorHandle_t *pSensorHandle, isf_dsa_SensorSettings_t *pSensorSettings)
isf_SensorTypes_t * pSupportedSensorTypes
The mma8491q.h contains register definitions and macros as well as the type definitions and public fu...
MMA8491Q data buffer format.
isf_SensorDataTypes_t mma8491q_SupportedDataTypes[]
isf_dsa_status_t fsl_mma8491q_i2c_3D_accel_Convert(volatile isf_SensorHandle_t *pSensorHandle, isf_SensorDataTypes_t convertToType, isf_dsa_result_types_t resultType, void *pNativeSample, void *pConvertedSample, int32 *numBytes)
isf_dsa_status_t fsl_mma8491q_i2c_3D_accel_Initialize(isf_SensorHandle_t *pSensorHandle)
isf_SensorTypes_t mma8491q_SupportedSensorTypes[]
Supported sensor and data types for MMA8491q.