LSM9DS1 Library  0.7.0-alpha
C Library for the LSM9DS1 device.
lsm9ds1_error.h
Go to the documentation of this file.
1 /*
2  * This file is part of the lsm9ds1 library (https://github.com/ChristopherJD/lsm9ds1.git).
3  * Copyright (c) 2019 Christopher Jordan-Denny.
4  *
5  * This program is free software: you can redistribute it and/or modify
6  * it under the terms of the GNU General Public License as published by
7  * the Free Software Foundation, version 3.
8  *
9  * This program is distributed in the hope that it will be useful, but
10  * WITHOUT ANY WARRANTY; without even the implied warranty of
11  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12  * General Public License for more details.
13  *
14  * You should have received a copy of the GNU General Public License
15  * along with this program. If not, see <http://www.gnu.org/licenses/>.
16 */
17 
25 #ifndef LSM9DS1_ERROR_H_
26 #define LSM9DS1_ERROR_H_
27 
32 typedef enum lsm9ds1_status {
33  LSM9DS1_SUCCESS = 0,
34  LSM9DS1_NOT_FOUND = -1,
35  LSM9DS1_SPI_BUS_XFER_ERROR = -2,
36  LSM9DS1_UNABLE_TO_GET_SPI_MODE = -3,
37  LSM9DS1_MODE_3_NOT_SET = -4,
38  LSM9DS1_NUM_BITS_NOT_SET = -5,
39  LSM9DS1_CLOCK_NOT_SET = -6,
40  LSM9DS1_BUS_NOT_SUPPORTED = -7,
41  LSM9DS1_UNKNOWN_ERROR = -8,
42  LSM9DS1_ALREADY_INIT_ERROR = -9,
43  LSM9DS1_UNKNOWN_SUB_DEVICE = -10,
44  LSM9DS1_NOT_INITIALIZED = -11,
45  LSM9DS1_UNSUPPORTED_OP = -12,
46  LSM9DS1_UKNOWN_ACCEL_RANGE = -13,
47  LSM9DS1_BUS_NOT_INTIALIZED = -14,
48  LSM9DS1_UKNOWN_GAIN_RANGE = -15,
49  LSM9DS1_UNABLE_TO_SET_CS_DIR = -16,
50  LSM9DS1_UNABLE_TO_OPEN_MAG_CS = -17,
51  LSM9DS1_UNABLE_TO_SET_CS = -18,
52  LSM9DS1_MALLOC_DEVICE_ERROR = -19,
53  LSM9DS1_NO_BUS_FOUND = -20,
54  LSM9DS1_MAG_ALREADY_RESET = -21,
55  LSM9DS1_ACCEL_GYRO_ALREADY_RESET = -22,
56  LSM9DS1_BUS_ALREADY_OPEN = -23,
57  LSM9DS1_CONFIG_FILE_NOT_FOUND = -24,
58  LSM9DS1_CONFIG_FILE_SIZE_UKNOWN = -25,
59  LSM9DS1_UNABLE_TO_READ_CONFIG = -26,
60  LSM9DS1_UNABLE_TO_PARSE_JSON = -27,
61  LSM9DS1_NO_SETTINGS = -28,
62  LSM9DS1_INVALID_SETTING = -29,
63  LSM9DS1_NULL_PARAMETER = -30,
65 
66 #endif
enum lsm9ds1_status lsm9ds1_status_t
Contains the possible error codes returned by the functions.
lsm9ds1_status
Contains the possible error codes returned by the functions.
Definition: lsm9ds1_error.h:32