From 2687418a28855fc0d1ac2327dbdcb9c3db8589f0 Mon Sep 17 00:00:00 2001 From: raiden00pl Date: Thu, 14 Nov 2024 15:08:08 +0100 Subject: [PATCH] drivers/sensors: fix style issues in function headers fix style issues in function headers, add missing new lines --- drivers/sensors/ds18b20_uorb.c | 13 +++++++++++++ drivers/sensors/fakesensor_uorb.c | 1 + drivers/sensors/gnss_uorb.c | 1 + drivers/sensors/hyt271_uorb.c | 16 ++++++++++++++++ drivers/sensors/mpu9250_uorb.c | 18 ++++++++++++++++-- drivers/sensors/ms56xx_uorb.c | 2 ++ drivers/sensors/sensor.c | 2 ++ drivers/sensors/sensor_rpmsg.c | 3 +++ drivers/sensors/sht4x.c | 20 ++++++++++---------- drivers/sensors/usensor.c | 1 + include/nuttx/sensors/bmp180.h | 1 + include/nuttx/sensors/ds18b20.h | 1 + include/nuttx/sensors/fakesensor.h | 1 + include/nuttx/sensors/gnss.h | 1 + include/nuttx/sensors/hyt271.h | 1 + include/nuttx/sensors/mpu60x0.h | 11 ++++++++--- include/nuttx/sensors/mpu9250.h | 11 ++++++++--- include/nuttx/sensors/msa301.h | 3 +-- include/nuttx/sensors/sensor.h | 9 +++++++++ include/nuttx/sensors/wtgahrs2.h | 1 + 20 files changed, 97 insertions(+), 20 deletions(-) diff --git a/drivers/sensors/ds18b20_uorb.c b/drivers/sensors/ds18b20_uorb.c index ddbdb851b8852..2224d089bced4 100644 --- a/drivers/sensors/ds18b20_uorb.c +++ b/drivers/sensors/ds18b20_uorb.c @@ -324,6 +324,7 @@ static int ds18b20_isalarm(FAR struct onewire_master_s *master, * * Return: * OK - on success + * ****************************************************************************/ static int ds18b20_measure(FAR struct ds18b20_dev_s *dev) @@ -354,6 +355,7 @@ static int ds18b20_measure(FAR struct ds18b20_dev_s *dev) * * Return: * OK - on success + * ****************************************************************************/ static int ds18b20_write_spad(FAR struct ds18b20_dev_s *dev, int8_t th, @@ -387,6 +389,7 @@ static int ds18b20_write_spad(FAR struct ds18b20_dev_s *dev, int8_t th, * * Return: * OK - on success + * ****************************************************************************/ static int ds18b20_read_spad(FAR struct ds18b20_dev_s *dev, @@ -444,6 +447,7 @@ static int ds18b20_read_spad(FAR struct ds18b20_dev_s *dev, * * Return: * OK - on success + * ****************************************************************************/ static int ds18b20_set_res(FAR struct ds18b20_dev_s *dev, uint8_t res) @@ -495,6 +499,7 @@ static int ds18b20_set_res(FAR struct ds18b20_dev_s *dev, uint8_t res) * * Return: * OK - on success + * ****************************************************************************/ static int ds18b20_set_alarm(FAR struct ds18b20_dev_s *dev, @@ -549,6 +554,7 @@ static int ds18b20_set_alarm(FAR struct ds18b20_dev_s *dev, * * Return: * Timestamp in nsec + * ****************************************************************************/ static unsigned long ds18b20_curtime(void) @@ -596,6 +602,7 @@ static void ds18b20_notify(FAR struct ds18b20_dev_s *dev, * * Return: * OK - on success + * ****************************************************************************/ static int ds18b20_measure_read(FAR struct ds18b20_dev_s *dev, @@ -635,6 +642,7 @@ static int ds18b20_measure_read(FAR struct ds18b20_dev_s *dev, * * Return: * OK - on success + * ****************************************************************************/ static int ds18b20_fetch(FAR struct sensor_lowerhalf_s *lower, @@ -677,6 +685,7 @@ static int ds18b20_fetch(FAR struct sensor_lowerhalf_s *lower, * * Return: * OK - on success + * ****************************************************************************/ static int ds18b20_control(FAR struct sensor_lowerhalf_s *lower, @@ -745,6 +754,7 @@ static int ds18b20_control(FAR struct sensor_lowerhalf_s *lower, * * Return: * OK - on success + * ****************************************************************************/ static int ds18b20_active(FAR struct sensor_lowerhalf_s *lower, @@ -783,6 +793,7 @@ static int ds18b20_active(FAR struct sensor_lowerhalf_s *lower, * * Return: * OK - on success + * ****************************************************************************/ #ifdef CONFIG_SENSORS_DS18B20_POLL @@ -805,6 +816,7 @@ static int ds18b20_set_interval(FAR struct sensor_lowerhalf_s *lower, * Parameter: * argc - Number of arguments * argv - Pointer to argument list + * ****************************************************************************/ #ifdef CONFIG_SENSORS_DS18B20_POLL @@ -909,6 +921,7 @@ static int ds18b20_thread(int argc, char** argv) * * Returned Value: * Zero (OK) on success; a negated errno value on failure. + * ****************************************************************************/ int ds18b20_register(int devno, FAR struct onewire_master_s *onewire, diff --git a/drivers/sensors/fakesensor_uorb.c b/drivers/sensors/fakesensor_uorb.c index 8b2937d7ae349..ef8e50fad1307 100644 --- a/drivers/sensors/fakesensor_uorb.c +++ b/drivers/sensors/fakesensor_uorb.c @@ -392,6 +392,7 @@ static int fakesensor_thread(int argc, char** argv) * ... * devno - The user specifies which device of this type, from 0. * batch_number- The maximum number of batch + * ****************************************************************************/ int fakesensor_init(int type, FAR const char *file_name, diff --git a/drivers/sensors/gnss_uorb.c b/drivers/sensors/gnss_uorb.c index 87e8a6626a6a7..b553744c0ec9b 100644 --- a/drivers/sensors/gnss_uorb.c +++ b/drivers/sensors/gnss_uorb.c @@ -848,6 +848,7 @@ int gnss_register(FAR struct gnss_lowerhalf_s *lower, int devno, * instance is bound to the GNSS driver and must persists as long * as the driver persists. * devno - The user specifies which device of this type, from 0. + * ****************************************************************************/ void gnss_unregister(FAR struct gnss_lowerhalf_s *lower, int devno) diff --git a/drivers/sensors/hyt271_uorb.c b/drivers/sensors/hyt271_uorb.c index 7796b3a88b0fa..9f4557a077fab 100644 --- a/drivers/sensors/hyt271_uorb.c +++ b/drivers/sensors/hyt271_uorb.c @@ -153,6 +153,7 @@ static const struct sensor_ops_s g_hyt271_ops = * Parameter: * data - Pointer to internal datat structure for measured data * temp - Pointer to sensor data structure for humidity + * ****************************************************************************/ static void hyt271_humi_from_rawdata(FAR struct hyt271_sensor_data_s *data, @@ -170,6 +171,7 @@ static void hyt271_humi_from_rawdata(FAR struct hyt271_sensor_data_s *data, * Parameter: * data - Pointer to internal datat structure for measured data * temp - Pointer to sensor data structure for temperature + * ****************************************************************************/ static void hyt271_temp_from_rawdata(FAR struct hyt271_sensor_data_s *data, @@ -186,6 +188,7 @@ static void hyt271_temp_from_rawdata(FAR struct hyt271_sensor_data_s *data, * * Return: * Timestamp in nsec + * ****************************************************************************/ static unsigned long hyt271_curtime(void) @@ -205,6 +208,7 @@ static unsigned long hyt271_curtime(void) * buffer - Pointer to the buffers memory region * cmd - The command to set in the buffer * size - The buffer size + * ****************************************************************************/ static void hyt271_init_rw_buffer(FAR uint8_t *buffer, uint8_t cmd, @@ -233,6 +237,7 @@ static void hyt271_init_rw_buffer(FAR uint8_t *buffer, uint8_t cmd, * * Return: * OK - on success + * ****************************************************************************/ static int hyt271_df(FAR struct hyt271_dev_s *dev, @@ -264,6 +269,7 @@ static int hyt271_df(FAR struct hyt271_dev_s *dev, * * Return: * OK - on success + * ****************************************************************************/ static int hyt271_mr(FAR struct hyt271_dev_s *dev, @@ -306,6 +312,7 @@ static int hyt271_mr(FAR struct hyt271_dev_s *dev, * * Return: * OK - on success + * ****************************************************************************/ static int hyt271_cmd(FAR struct hyt271_dev_s *dev, @@ -341,6 +348,7 @@ static int hyt271_cmd(FAR struct hyt271_dev_s *dev, * * Return: * OK - on success + * ****************************************************************************/ static int hyt271_cmd_response(FAR struct hyt271_dev_s *dev, @@ -393,6 +401,7 @@ static int hyt271_cmd_response(FAR struct hyt271_dev_s *dev, * * Return: * OK - on success + * ****************************************************************************/ static int hyt271_change_addr(FAR struct hyt271_dev_s *dev, uint8_t addr) @@ -538,6 +547,7 @@ static int hyt271_change_addr(FAR struct hyt271_dev_s *dev, uint8_t addr) * Return: * OK - on success + * ****************************************************************************/ static int hyt271_measure_read(FAR struct hyt271_dev_s *dev, @@ -612,6 +622,7 @@ static int hyt271_measure_read(FAR struct hyt271_dev_s *dev, * * Return: * OK - on success + * ****************************************************************************/ static int hyt271_fetch(FAR struct sensor_lowerhalf_s *lower, @@ -667,6 +678,7 @@ static int hyt271_fetch(FAR struct sensor_lowerhalf_s *lower, * * Return: * OK - on success + * ****************************************************************************/ static int hyt271_control(FAR struct sensor_lowerhalf_s *lower, @@ -716,6 +728,7 @@ static int hyt271_control(FAR struct sensor_lowerhalf_s *lower, * * Return: * OK - on success + * ****************************************************************************/ static int hyt271_active(FAR struct sensor_lowerhalf_s *lower, @@ -754,6 +767,7 @@ static int hyt271_active(FAR struct sensor_lowerhalf_s *lower, * * Return: * OK - on success + * ****************************************************************************/ #ifdef CONFIG_SENSORS_HYT271_POLL @@ -776,6 +790,7 @@ static int hyt271_set_interval(FAR struct sensor_lowerhalf_s *lower, * Parameter: * argc - Number of arguments * argv - Pointer to argument list + * ****************************************************************************/ #ifdef CONFIG_SENSORS_HYT271_POLL @@ -871,6 +886,7 @@ static int hyt271_thread(int argc, char** argv) * * Returned Value: * Zero (OK) on success; a negated errno value on failure. + * ****************************************************************************/ int hyt271_register(int devno, FAR struct i2c_master_s *i2c, uint8_t addr, diff --git a/drivers/sensors/mpu9250_uorb.c b/drivers/sensors/mpu9250_uorb.c index 2ec20227c28a7..e64dc0ccf09f4 100644 --- a/drivers/sensors/mpu9250_uorb.c +++ b/drivers/sensors/mpu9250_uorb.c @@ -982,7 +982,7 @@ static inline int mpu9250_write_fifo_en(FAR struct mpu9250_dev_s *dev, } /**************************************************************************** - * mpu9250_write_gyro_range() : + * Name: mpu9250_write_gyro_range() * * Sets the @fs_sel bit in GYRO_CONFIG to the value provided. Per the * datasheet, the meaning of @fs_sel is as follows: @@ -997,6 +997,7 @@ static inline int mpu9250_write_fifo_en(FAR struct mpu9250_dev_s *dev, * 1 -> ± 500 deg/sec * 2 -> ± 1000 deg/sec * 3 -> ± 2000 deg/sec + * ****************************************************************************/ static inline int mpu9250_write_gyro_range(FAR struct mpu9250_dev_s *dev, @@ -1007,7 +1008,7 @@ static inline int mpu9250_write_gyro_range(FAR struct mpu9250_dev_s *dev, } /**************************************************************************** - * mpu9250_write_accel_range() : + * Name: mpu9250_write_accel_range() * * Sets the @afs_sel bit in ACCEL_CONFIG to the value provided. Per * the datasheet, the meaning of @afs_sel is as follows: @@ -1022,6 +1023,7 @@ static inline int mpu9250_write_gyro_range(FAR struct mpu9250_dev_s *dev, * 1 -> ± 4 g * 2 -> ± 8 g * 3 -> ± 16 g + * ****************************************************************************/ static inline int mpu9250_write_accel_range(FAR struct mpu9250_dev_s *dev, @@ -1036,6 +1038,7 @@ static inline int mpu9250_write_accel_range(FAR struct mpu9250_dev_s *dev, * * EXT_SYNC_SET : frame sync bit position * DLPF_CFG : digital low-pass filter bandwidth + * ****************************************************************************/ static inline int mpu9250_write_config(FAR struct mpu9250_dev_s *dev, @@ -1051,6 +1054,7 @@ static inline int mpu9250_write_config(FAR struct mpu9250_dev_s *dev, * * accel_fchoice_b : he inverted version of accel_fchoice * A_DLPF_CFG : Accelerometer low pass filter setting + * ****************************************************************************/ static inline int mpu9250_write_config2(FAR struct mpu9250_dev_s *dev, @@ -1071,6 +1075,7 @@ static inline int mpu9250_write_config2(FAR struct mpu9250_dev_s *dev, * * Return: * OK - on success + * ****************************************************************************/ static int mpu9250_initialize(FAR struct mpu9250_dev_s *dev) @@ -1283,6 +1288,7 @@ static int mpu9250_initialize(FAR struct mpu9250_dev_s *dev) * * Return: * OK - on success + * ****************************************************************************/ static int ak8963_initialize(FAR struct mpu9250_dev_s *dev, @@ -1438,6 +1444,7 @@ static int ak8963_initialize(FAR struct mpu9250_dev_s *dev, * * Return: * OK - on success + * ****************************************************************************/ static int get_mag_adjustment(FAR struct mpu9250_dev_s *dev) @@ -1516,6 +1523,7 @@ static int get_mag_adjustment(FAR struct mpu9250_dev_s *dev) * * Return: * OK - on success + * ****************************************************************************/ static int read_ak8963_reg(FAR struct mpu9250_dev_s *dev, @@ -1608,6 +1616,7 @@ static int read_ak8963_reg(FAR struct mpu9250_dev_s *dev, * * Return: * OK - on success + * ****************************************************************************/ static int write_ak8963_reg(FAR struct mpu9250_dev_s *dev, @@ -1700,6 +1709,7 @@ static int write_ak8963_reg(FAR struct mpu9250_dev_s *dev, * * Return: * do nothing if Big endian, swap H and L byte if little endian + * ****************************************************************************/ static uint16_t swap16(uint16_t val) @@ -1722,6 +1732,7 @@ static uint16_t swap16(uint16_t val) * * Return: * OK - on success + * ****************************************************************************/ static void mpu9250_accel_data(FAR struct mpu9250_sensor_s *priv, @@ -1760,6 +1771,7 @@ static void mpu9250_accel_data(FAR struct mpu9250_sensor_s *priv, * * Return: * OK - on success + * ****************************************************************************/ static void mpu9250_gyro_data(FAR struct mpu9250_sensor_s *priv, @@ -1798,6 +1810,7 @@ static void mpu9250_gyro_data(FAR struct mpu9250_sensor_s *priv, * * Return: * OK - on success + * ****************************************************************************/ static void mpu9250_mag_data(FAR struct mpu9250_sensor_s *priv, @@ -1849,6 +1862,7 @@ static void mpu9250_mag_data(FAR struct mpu9250_sensor_s *priv, * Parameter: * argc - Number of arguments * argv - Pointer to argument list + * ****************************************************************************/ static int mpu9250_thread(int argc, FAR char **argv) diff --git a/drivers/sensors/ms56xx_uorb.c b/drivers/sensors/ms56xx_uorb.c index c8c0630c21bae..645cbf46a10a6 100644 --- a/drivers/sensors/ms56xx_uorb.c +++ b/drivers/sensors/ms56xx_uorb.c @@ -159,6 +159,7 @@ static const struct sensor_ops_s g_sensor_ops = * * Return: * Timestamp in microseconds + * ****************************************************************************/ static unsigned long ms56xx_curtime(void) @@ -371,6 +372,7 @@ static inline void baro_measure_read(FAR struct ms56xx_dev_s *priv, * Parameter: * argc - Number of arguments * argv - Pointer to argument list + * ****************************************************************************/ static int ms56xx_thread(int argc, char **argv) diff --git a/drivers/sensors/sensor.c b/drivers/sensors/sensor.c index 2edfc4f5a0707..abb31d3122f2d 100644 --- a/drivers/sensors/sensor.c +++ b/drivers/sensors/sensor.c @@ -1377,6 +1377,7 @@ int sensor_custom_register(FAR struct sensor_lowerhalf_s *lower, * instance is bound to the sensor driver and must persists as long * as the driver persists. * devno - The user specifies which device of this type, from 0. + * ****************************************************************************/ void sensor_unregister(FAR struct sensor_lowerhalf_s *lower, int devno) @@ -1402,6 +1403,7 @@ void sensor_unregister(FAR struct sensor_lowerhalf_s *lower, int devno) * instance is bound to the sensor driver and must persists as long * as the driver persists. * path - The user specifies path of device, ex: /dev/uorb/xxx + * ****************************************************************************/ void sensor_custom_unregister(FAR struct sensor_lowerhalf_s *lower, diff --git a/drivers/sensors/sensor_rpmsg.c b/drivers/sensors/sensor_rpmsg.c index 1c8e91f89cc3b..58860760ebe5e 100644 --- a/drivers/sensors/sensor_rpmsg.c +++ b/drivers/sensors/sensor_rpmsg.c @@ -1446,6 +1446,7 @@ static void sensor_rpmsg_device_created(FAR struct rpmsg_device *rdev, * * Returned Value: * The takeover rpmsg lowerhalf returned on success, NULL on failure. + * ****************************************************************************/ FAR struct sensor_lowerhalf_s * @@ -1512,6 +1513,7 @@ sensor_rpmsg_register(FAR struct sensor_lowerhalf_s *lower, * * Input Parameters: * lower - The instance of lower half sensor driver. + * ****************************************************************************/ void sensor_rpmsg_unregister(FAR struct sensor_lowerhalf_s *lower) @@ -1539,6 +1541,7 @@ void sensor_rpmsg_unregister(FAR struct sensor_lowerhalf_s *lower) * * Returned Value: * OK on success; A negated errno value is returned on any failure. + * ****************************************************************************/ int sensor_rpmsg_initialize(void) diff --git a/drivers/sensors/sht4x.c b/drivers/sensors/sht4x.c index 7f61cb9bdfa52..d8cb2c98633e0 100644 --- a/drivers/sensors/sht4x.c +++ b/drivers/sensors/sht4x.c @@ -51,11 +51,11 @@ #define SHT4X_TEMP_UNIT "F" #else #define SHT4X_TEMP_UNIT "C" -#endif // defined(CONFIG_SHT4X_FAHRENHEIT) +#endif #ifndef CONFIG_SHT4X_I2C_FREQUENCY #define CONFIG_SHT4X_I2C_FREQUENCY 400000 -#endif // CONFIG_SHT4X_I2C_FREQUENCY +#endif #define SHT4X_CRC_INIT 0xFF /* Initial value of the calculated CRC. */ #define SHT4X_CRC_POLY 0x31 /* CRC calculation polynomial. */ @@ -82,12 +82,12 @@ struct sht4x_dev_s uint8_t addr; /* I2C address. */ #ifndef CONFIG_DISABLE_PSEUDOFS_OPERATIONS bool unlinked; /* True, driver has been unlinked. */ -#endif // CONFIG_DISABLE_PSEUDOFS_OPERATIONS +#endif struct timespec last_heat; /* Last time heater was active. */ enum sht4x_precision_e precision; /* The precision for read operations. */ #ifndef CONFIG_DISABLE_PSEUDOFS_OPERATIONS int16_t crefs; /* Number of open references. */ -#endif // CONFIG_DISABLE_PSEUDOFS_OPERATIONS +#endif mutex_t devlock; }; @@ -147,7 +147,7 @@ static const uint8_t g_crc_lookup[] = 0xe0, 0xd1, 0x46, 0x77, 0x24, 0x15, 0x3b, 0xa, 0x59, 0x68, 0xff, 0xce, 0x9d, 0xac, } -#endif // CONFIG_SHT4X_CRC_LOOKUP +#endif /* Measurement times for the various precisions, in microseconds. */ @@ -423,7 +423,7 @@ static int32_t sht4x_calc_temp(uint16_t temp) return -49000 + 315 * ((temp * 1000) / 65535); #else return -45000 + 175 * ((temp * 1000) / 65535); /* Millidegrees Celsius */ -#endif // CONFIG_SHT4X_FAHRENHEIT +#endif } /**************************************************************************** @@ -450,7 +450,7 @@ static int16_t sht4x_calc_hum(uint16_t humidity) hum = 10000; } -#endif // CONFIG_SHT4X_LIMIT_HUMIDITY +#endif return hum; } @@ -598,7 +598,7 @@ static ssize_t sht4x_read(FAR struct file *filep, FAR char *buffer, { #ifdef CONFIG_SHT4X_DEBUG sht4x_dbg("Could not read device: %d\n", err); -#endif // CONFIG_SHT4X_DEBUG +#endif nxmutex_unlock(&priv->devlock); return err; } @@ -732,7 +732,7 @@ static int sht4x_ioctl(FAR struct file *filep, int cmd, unsigned long arg) priv->precision = arg; #ifdef CONFIG_SHT4X_DEBUG sht4x_dbg("Precision set to %d\n", priv->precision); -#endif // CONFIG_SHT4X_DEBUG +#endif break; @@ -798,7 +798,7 @@ static int sht4x_unlink(FAR struct inode *inode) * i2c - An instance of the I2C interface to use to communicate with * the SHT4X * addr - The I2C address of the SHT4X. The I2C address is one of 0x44, - *0x45 and 0x46. + * 0x45 and 0x46. * * Returned Value: * Zero (OK) on success; a negated errno value on failure. diff --git a/drivers/sensors/usensor.c b/drivers/sensors/usensor.c index 8988d6242b3eb..dab1c7670dfaa 100644 --- a/drivers/sensors/usensor.c +++ b/drivers/sensors/usensor.c @@ -264,6 +264,7 @@ static int usensor_control(FAR struct sensor_lowerhalf_s *lower, * This function registers usensor character node "/dev/usensor", so that * application can register user sensor by this node. The node will * manager all user sensors in this character driver. + * ****************************************************************************/ int usensor_initialize(void) diff --git a/include/nuttx/sensors/bmp180.h b/include/nuttx/sensors/bmp180.h index 6cf615e4f1112..03ae6a57b57c9 100644 --- a/include/nuttx/sensors/bmp180.h +++ b/include/nuttx/sensors/bmp180.h @@ -79,6 +79,7 @@ extern "C" * Zero (OK) on success; a negated errno value on failure. * ****************************************************************************/ + #ifndef CONFIG_SENSORS_BMP180_UORB int bmp180_register(FAR const char *devpath, FAR struct i2c_master_s *i2c); #else diff --git a/include/nuttx/sensors/ds18b20.h b/include/nuttx/sensors/ds18b20.h index 873e317415679..b825959442cf7 100644 --- a/include/nuttx/sensors/ds18b20.h +++ b/include/nuttx/sensors/ds18b20.h @@ -83,6 +83,7 @@ extern "C" * * Returned Value: * Zero (OK) on success; a negated errno value on failure. + * ****************************************************************************/ int ds18b20_register(int devno, FAR struct onewire_master_s *dev, diff --git a/include/nuttx/sensors/fakesensor.h b/include/nuttx/sensors/fakesensor.h index 99ed1ee51b54b..78c4342b71db8 100644 --- a/include/nuttx/sensors/fakesensor.h +++ b/include/nuttx/sensors/fakesensor.h @@ -59,6 +59,7 @@ extern "C" * ... * devno - The user specifies which device of this type, from 0. * batch_number- The maximum number of batch + * ****************************************************************************/ int fakesensor_init(int type, FAR const char *file_name, diff --git a/include/nuttx/sensors/gnss.h b/include/nuttx/sensors/gnss.h index 988af0eb74eca..d7daa4521957d 100644 --- a/include/nuttx/sensors/gnss.h +++ b/include/nuttx/sensors/gnss.h @@ -224,6 +224,7 @@ int gnss_register(FAR struct gnss_lowerhalf_s *dev, int devno, * instance is bound to the GNSS driver and must persists as long * as the driver persists. * devno - The user specifies which device of this type, from 0. + * ****************************************************************************/ void gnss_unregister(FAR struct gnss_lowerhalf_s *dev, int devno); diff --git a/include/nuttx/sensors/hyt271.h b/include/nuttx/sensors/hyt271.h index decc1b21aa4ae..893e2df4192ba 100644 --- a/include/nuttx/sensors/hyt271.h +++ b/include/nuttx/sensors/hyt271.h @@ -98,6 +98,7 @@ extern "C" * * Returned Value: * Zero (OK) on success; a negated errno value on failure. + * ****************************************************************************/ int hyt271_register(int devno, FAR struct i2c_master_s *i2c, uint8_t addr, diff --git a/include/nuttx/sensors/mpu60x0.h b/include/nuttx/sensors/mpu60x0.h index 52b1961f1044c..e9ef51fbfa9c4 100644 --- a/include/nuttx/sensors/mpu60x0.h +++ b/include/nuttx/sensors/mpu60x0.h @@ -105,11 +105,16 @@ struct mpu_config_s * Public Function Prototypes ****************************************************************************/ -/* Declares the existence of an mpu60x0 chip, wired according to - * config; creates an interface to it at path. +/**************************************************************************** + * Name: mpu60x0_register + * + * Description: + * Declares the existence of an mpu60x0 chip, wired according to + * config; creates an interface to it at path. * * Returns 0 on success, or negative errno. - */ + * + ****************************************************************************/ int mpu60x0_register(FAR const char *path, FAR struct mpu_config_s *config); diff --git a/include/nuttx/sensors/mpu9250.h b/include/nuttx/sensors/mpu9250.h index caef21bfb337f..e042e32e8d716 100644 --- a/include/nuttx/sensors/mpu9250.h +++ b/include/nuttx/sensors/mpu9250.h @@ -158,11 +158,16 @@ struct mpu9250_config_s * Public Function Prototypes ****************************************************************************/ -/* Declares the existence of an mpu9250 chip, wired according to - * config; creates an interface to it at path. +/**************************************************************************** + * Name: mpu60x0_register + * + * Description: + * Declares the existence of an mpu9250 chip, wired according to + * config; creates an interface to it at path. * * Returns 0 on success, or negative errno. - */ + * + ****************************************************************************/ int mpu9250_register(int devno, FAR struct mpu9250_config_s *config); diff --git a/include/nuttx/sensors/msa301.h b/include/nuttx/sensors/msa301.h index 7557c85955408..89e5a363a4563 100644 --- a/include/nuttx/sensors/msa301.h +++ b/include/nuttx/sensors/msa301.h @@ -151,8 +151,7 @@ extern "C" ****************************************************************************/ int msa301_sensor_register(FAR const char *devpath, - FAR struct i2c_master_s *i2c - ); + FAR struct i2c_master_s *i2c); #ifdef __cplusplus } diff --git a/include/nuttx/sensors/sensor.h b/include/nuttx/sensors/sensor.h index 24d21ed9c57d1..d84b8483d8e19 100644 --- a/include/nuttx/sensors/sensor.h +++ b/include/nuttx/sensors/sensor.h @@ -560,6 +560,7 @@ struct sensor_lowerhalf_s * Returned Value: * The bytes of push is returned when success; * A negated errno value is returned on any failure. + * **********************************************************************/ sensor_push_event_t push_event; @@ -576,6 +577,7 @@ struct sensor_lowerhalf_s * * Input Parameters: * priv - Upper half driver handle + * **********************************************************************/ sensor_notify_event_t notify_event; @@ -589,6 +591,7 @@ struct sensor_lowerhalf_s * * Input Parameters: * priv - Upper half driver handle + * ****************************************************************************/ CODE void (*sensor_lock)(FAR void * priv); @@ -707,6 +710,7 @@ int sensor_custom_register(FAR struct sensor_lowerhalf_s *dev, * instance is bound to the sensor driver and must persists as long * as the driver persists. * devno - The user specifies which device of this type, from 0. + * ****************************************************************************/ void sensor_unregister(FAR struct sensor_lowerhalf_s *dev, int devno); @@ -723,6 +727,7 @@ void sensor_unregister(FAR struct sensor_lowerhalf_s *dev, int devno); * instance is bound to the sensor driver and must persists as long * as the driver persists. * path - The user specifies path of device, ex: /dev/uorb/xxx + * ****************************************************************************/ void sensor_custom_unregister(FAR struct sensor_lowerhalf_s *dev, @@ -735,6 +740,7 @@ void sensor_custom_unregister(FAR struct sensor_lowerhalf_s *dev, * This function registers usensor character node "/dev/usensor", so that * application can register user sensor by this node. The node will * manager all user sensor in this character dirver. + * ****************************************************************************/ #ifdef CONFIG_USENSOR @@ -754,6 +760,7 @@ int usensor_initialize(void); * * Returned Value: * The takeover rpmsg lowerhalf returned on success, NULL on failure. + * ****************************************************************************/ #ifdef CONFIG_SENSORS_RPMSG @@ -772,6 +779,7 @@ FAR struct sensor_lowerhalf_s *sensor_rpmsg_register( * * Input Parameters: * lower - The instance of lower half sensor driver. + * ****************************************************************************/ #ifdef CONFIG_SENSORS_RPMSG @@ -787,6 +795,7 @@ void sensor_rpmsg_unregister(FAR struct sensor_lowerhalf_s *lower); * * Returned Value: * OK on success; A negated errno value is returned on any failure. + * ****************************************************************************/ #ifdef CONFIG_SENSORS_RPMSG diff --git a/include/nuttx/sensors/wtgahrs2.h b/include/nuttx/sensors/wtgahrs2.h index b72e22065925e..26f8dade24ec7 100644 --- a/include/nuttx/sensors/wtgahrs2.h +++ b/include/nuttx/sensors/wtgahrs2.h @@ -54,6 +54,7 @@ extern "C" * Returned Value: * OK if the driver was successfully initialize; A negated errno value is * returned on any failure. + * ****************************************************************************/ int wtgahrs2_initialize(FAR const char *path, int devno);