aboutsummaryrefslogtreecommitdiffstats
path: root/os/hal
diff options
context:
space:
mode:
authorroccomarco <roccomarco@35acf78f-673a-0410-8e92-d51de3d6d3f4>2017-07-02 09:29:51 +0000
committerroccomarco <roccomarco@35acf78f-673a-0410-8e92-d51de3d6d3f4>2017-07-02 09:29:51 +0000
commit291f788fbcbc2749a5240a38f74cd4b906c6c4fd (patch)
tree028ef55fa152e210b83951ff20a60f570f5fdb22 /os/hal
parentc6d3697eda985c4ecbd0021ae0c20e5194436c9f (diff)
downloadChibiOS-291f788fbcbc2749a5240a38f74cd4b906c6c4fd.tar.gz
ChibiOS-291f788fbcbc2749a5240a38f74cd4b906c6c4fd.tar.bz2
ChibiOS-291f788fbcbc2749a5240a38f74cd4b906c6c4fd.zip
Improved ChibiOS\EX documentation (almost complete)
git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@10285 35acf78f-673a-0410-8e92-d51de3d6d3f4
Diffstat (limited to 'os/hal')
-rw-r--r--os/hal/lib/peripherals/flash/hal_flash.c16
-rw-r--r--os/hal/lib/peripherals/flash/hal_flash.h4
2 files changed, 16 insertions, 4 deletions
diff --git a/os/hal/lib/peripherals/flash/hal_flash.c b/os/hal/lib/peripherals/flash/hal_flash.c
index ce03624cc..7bc0845bb 100644
--- a/os/hal/lib/peripherals/flash/hal_flash.c
+++ b/os/hal/lib/peripherals/flash/hal_flash.c
@@ -50,7 +50,10 @@
* @brief Waits until the current erase operation is finished.
*
* @param[in] devp pointer to a @p BaseFlash object
- * @param[in] cb polling callback or @p NULL
+ *
+ * @return An error code.
+ * @retval FLASH_NO_ERROR if there is no erase operation in progress.
+ * @retval FLASH_ERROR_ERASE if the erase operation failed.
*/
flash_error_t flashWaitErase(BaseFlash *devp) {
@@ -71,6 +74,11 @@ flash_error_t flashWaitErase(BaseFlash *devp) {
/**
* @brief Returns the offset of a sector.
+ *
+ * @param[in] devp pointer to a @p BaseFlash object
+ * @param[in] sector flash sector number
+ *
+ * @return the offset of the sector
*/
flash_offset_t flashGetSectorOffset(BaseFlash *devp,
flash_sector_t sector) {
@@ -91,6 +99,11 @@ flash_offset_t flashGetSectorOffset(BaseFlash *devp,
/**
* @brief Returns the size of a sector.
+ *
+ * @param[in] devp pointer to a @p BaseFlash object
+ * @param[in] sector flash sector number
+ *
+ * @return the size of the sector
*/
uint32_t flashGetSectorSize(BaseFlash *devp,
flash_sector_t sector) {
@@ -108,5 +121,4 @@ uint32_t flashGetSectorSize(BaseFlash *devp,
return size;
}
-
/** @} */
diff --git a/os/hal/lib/peripherals/flash/hal_flash.h b/os/hal/lib/peripherals/flash/hal_flash.h
index f7066e2ef..f6e83d580 100644
--- a/os/hal/lib/peripherals/flash/hal_flash.h
+++ b/os/hal/lib/peripherals/flash/hal_flash.h
@@ -200,7 +200,7 @@ typedef struct {
* @brief Sensors get axes number.
*
* @param[in] ip pointer to a @p BaseFlash or derived class
- * @return An error code.
+ * @return A flash device descriptor.
*
* @api
*/
@@ -230,7 +230,7 @@ typedef struct {
* @param[in] ip pointer to a @p BaseFlash or derived class
* @param[in] offset flash offset
* @param[in] n number of bytes to be programmed
- * @param[in] wp pointer to the data buffer
+ * @param[in] pp pointer to the data buffer
* @return An error code.
* @retval FLASH_NO_ERROR if there is no erase operation in progress.
* @retval FLASH_BUSY_ERASING if there is an erase operation in progress.