linux/drivers/iio/accel/adis16209.c

// SPDX-License-Identifier: GPL-2.0-or-later
/*
 * ADIS16209 Dual-Axis Digital Inclinometer and Accelerometer
 *
 * Copyright 2010 Analog Devices Inc.
 */

#include <linux/device.h>
#include <linux/kernel.h>
#include <linux/module.h>
#include <linux/spi/spi.h>

#include <linux/iio/iio.h>
#include <linux/iio/imu/adis.h>

#define ADIS16209_STARTUP_DELAY_MS
#define ADIS16209_FLASH_CNT_REG

/* Data Output Register Definitions */
#define ADIS16209_SUPPLY_OUT_REG
#define ADIS16209_XACCL_OUT_REG
#define ADIS16209_YACCL_OUT_REG
/* Output, auxiliary ADC input */
#define ADIS16209_AUX_ADC_REG
/* Output, temperature */
#define ADIS16209_TEMP_OUT_REG
/* Output, +/- 90 degrees X-axis inclination */
#define ADIS16209_XINCL_OUT_REG
#define ADIS16209_YINCL_OUT_REG
/* Output, +/-180 vertical rotational position */
#define ADIS16209_ROT_OUT_REG

/*
 * Calibration Register Definitions.
 * Acceleration, inclination or rotation offset null.
 */
#define ADIS16209_XACCL_NULL_REG
#define ADIS16209_YACCL_NULL_REG
#define ADIS16209_XINCL_NULL_REG
#define ADIS16209_YINCL_NULL_REG
#define ADIS16209_ROT_NULL_REG

/* Alarm Register Definitions */
#define ADIS16209_ALM_MAG1_REG
#define ADIS16209_ALM_MAG2_REG
#define ADIS16209_ALM_SMPL1_REG
#define ADIS16209_ALM_SMPL2_REG
#define ADIS16209_ALM_CTRL_REG

#define ADIS16209_AUX_DAC_REG
#define ADIS16209_GPIO_CTRL_REG
#define ADIS16209_SMPL_PRD_REG
#define ADIS16209_AVG_CNT_REG
#define ADIS16209_SLP_CNT_REG

#define ADIS16209_MSC_CTRL_REG
#define ADIS16209_MSC_CTRL_PWRUP_SELF_TEST
#define ADIS16209_MSC_CTRL_SELF_TEST_EN
#define ADIS16209_MSC_CTRL_DATA_RDY_EN
/* Data-ready polarity: 1 = active high, 0 = active low */
#define ADIS16209_MSC_CTRL_ACTIVE_HIGH
#define ADIS16209_MSC_CTRL_DATA_RDY_DIO2

#define ADIS16209_STAT_REG
#define ADIS16209_STAT_ALARM2
#define ADIS16209_STAT_ALARM1
#define ADIS16209_STAT_SELFTEST_FAIL_BIT
#define ADIS16209_STAT_SPI_FAIL_BIT
#define ADIS16209_STAT_FLASH_UPT_FAIL_BIT
/* Power supply above 3.625 V */
#define ADIS16209_STAT_POWER_HIGH_BIT
/* Power supply below 2.975 V */
#define ADIS16209_STAT_POWER_LOW_BIT

#define ADIS16209_CMD_REG
#define ADIS16209_CMD_SW_RESET
#define ADIS16209_CMD_CLEAR_STAT
#define ADIS16209_CMD_FACTORY_CAL

#define ADIS16209_ERROR_ACTIVE

enum adis16209_scan {};

static const u8 adis16209_addresses[8][1] =;

static int adis16209_write_raw(struct iio_dev *indio_dev,
			       struct iio_chan_spec const *chan,
			       int val,
			       int val2,
			       long mask)
{}

static int adis16209_read_raw(struct iio_dev *indio_dev,
			      struct iio_chan_spec const *chan,
			      int *val, int *val2,
			      long mask)
{}

static const struct iio_chan_spec adis16209_channels[] =;

static const struct iio_info adis16209_info =;

static const char * const adis16209_status_error_msgs[] =;

static const struct adis_timeout adis16209_timeouts =;

static const struct adis_data adis16209_data =;

static int adis16209_probe(struct spi_device *spi)
{}

static struct spi_driver adis16209_driver =;
module_spi_driver();

MODULE_AUTHOR();
MODULE_DESCRIPTION();
MODULE_LICENSE();
MODULE_ALIAS();
MODULE_IMPORT_NS();