doc: update some comments for doxygen style
This commit is contained in:
1 parent
ef6b971211
commit
2e4d50e6b1
2 files changed
+28
-32
No files matched your search
+17
-21
@@ -1,3 +1,7 @@
|
||||
/**
|
||||
* @file zh_aht.h
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "esp_err.h"
|
||||
@@ -10,21 +14,26 @@
|
||||
#include "freertos/FreeRTOS.h"
|
||||
#include "freertos/task.h"
|
||||
|
||||
/**
|
||||
* @brief AHT sensor initial default values.
|
||||
*/
|
||||
#define ZH_AHT_INIT_CONFIG_DEFAULT() \
|
||||
{ \
|
||||
.i2c_port = 0 \
|
||||
}
|
||||
.i2c_port = 0}
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif
|
||||
|
||||
typedef struct // Structure for initial initialization of AHT sensor.
|
||||
/**
|
||||
* @brief Structure for initial initialization of AHT sensor.
|
||||
*/
|
||||
typedef struct
|
||||
{
|
||||
bool i2c_port; // I2C port.
|
||||
bool i2c_port; /*!< I2C port. */
|
||||
#ifndef CONFIG_IDF_TARGET_ESP8266
|
||||
i2c_master_bus_handle_t i2c_handle; // Unique I2C bus handle.
|
||||
i2c_master_bus_handle_t i2c_handle; /*!< Unique I2C bus handle. */
|
||||
#endif
|
||||
} zh_aht_init_config_t;
|
||||
|
||||
@@ -39,11 +48,7 @@ extern "C"
|
||||
*
|
||||
* @code zh_aht_init_config_t config = ZH_AHT_INIT_CONFIG_DEFAULT() @endcode
|
||||
*
|
||||
* @return
|
||||
* - ESP_OK if initialization was success
|
||||
* - ESP_ERR_INVALID_ARG if parameter error
|
||||
* - ESP_ERR_NOT_FOUND if sensor not connected or not responded
|
||||
* - ESP_ERR_INVALID_RESPONSE if I2C driver error
|
||||
* @return ESP_OK if success or an error code otherwise.
|
||||
*/
|
||||
esp_err_t zh_aht_init(const zh_aht_init_config_t *config);
|
||||
|
||||
@@ -53,23 +58,14 @@ extern "C"
|
||||
* @param[out] humidity Pointer for AHT sensor reading data of humidity.
|
||||
* @param[out] temperature Pointer for AHT sensor reading data of temperature.
|
||||
*
|
||||
* @return
|
||||
* - ESP_OK if read was success
|
||||
* - ESP_ERR_INVALID_ARG if parameter error
|
||||
* - ESP_ERR_NOT_FOUND if sensor is not initialized
|
||||
* - ESP_ERR_INVALID_CRC if check CRC is fail
|
||||
* - ESP_ERR_INVALID_RESPONSE if I2C driver error
|
||||
* - ESP_ERR_TIMEOUT if sensor has not responded
|
||||
* @return ESP_OK if success or an error code otherwise.
|
||||
*/
|
||||
esp_err_t zh_aht_read(float *humidity, float *temperature);
|
||||
|
||||
/**
|
||||
* @brief Reset AHT sensor.
|
||||
*
|
||||
* @return
|
||||
* - ESP_OK if reset was success
|
||||
* - ESP_ERR_NOT_FOUND if sensor is not initialized
|
||||
* - ESP_ERR_INVALID_RESPONSE if I2C driver error
|
||||
* @return ESP_OK if success or an error code otherwise.
|
||||
*/
|
||||
esp_err_t zh_aht_reset(void);
|
||||
|
||||
|
||||
Reference in new issue
Block a user