1/*
2 $License:
3   Copyright 2011 InvenSense, Inc.
4
5 Licensed under the Apache License, Version 2.0 (the "License");
6 you may not use this file except in compliance with the License.
7 You may obtain a copy of the License at
8
9 http://www.apache.org/licenses/LICENSE-2.0
10
11 Unless required by applicable law or agreed to in writing, software
12 distributed under the License is distributed on an "AS IS" BASIS,
13 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 See the License for the specific language governing permissions and
15 limitations under the License.
16  $
17 */
18
19/*******************************************************************************
20 *
21 * $Id:$
22 *
23 ******************************************************************************/
24
25#ifndef INV_STORED_DATA_H
26#define INV_STORED_DATA_H
27
28#ifdef __cplusplus
29extern "C" {
30#endif
31
32/*
33    Includes.
34*/
35
36#include "mltypes.h"
37
38/*
39    Defines
40*/
41#define INV_CAL_ACCEL_LEN    (12)
42#define INV_CAL_COMPASS_LEN  (555 + 5)
43#define INV_CAL_HDR_LEN      (6)
44#define INV_CAL_CHK_LEN      (4)
45
46/*
47    APIs
48*/
49    inv_error_t inv_load_calibration(void);
50    inv_error_t inv_store_calibration(void);
51
52/*
53    Other prototypes
54*/
55    inv_error_t inv_load_cal(unsigned char *calData);
56    inv_error_t inv_store_cal(unsigned char *calData, int length);
57    unsigned int inv_get_cal_length(void);
58
59#ifdef __cplusplus
60}
61#endif
62#endif                          /* INV_STORED_DATA_H */
63