From 3ad298488c46e19e566e0b3817cb02a5a7d34a18 Mon Sep 17 00:00:00 2001 From: Senthil Ramakrishnan Date: Tue, 24 Oct 2017 10:05:45 -0500 Subject: [PATCH 1/3] Doxygen comment updates and fixes --- doxyfile_options | 2 +- drivers/UARTSerial.h | 7 +++++++ platform/ATCmdParser.h | 16 ++++++++++++++-- platform/CThunk.h | 10 ++++++++-- platform/CallChain.h | 19 ++++++++++++++----- platform/Callback.h | 16 ++++++++-------- platform/CircularBuffer.h | 10 +++++++++- platform/CriticalSectionLock.h | 10 ++++++++++ platform/DeepSleepLock.h | 11 +++++++++++ platform/DirHandle.h | 8 +++++++- platform/FileBase.h | 19 +++++++++++++------ platform/FileHandle.h | 11 ++++++++++- platform/FileLike.h | 14 ++++++++++---- platform/FilePath.h | 20 ++++++++++++++++---- platform/FileSystemHandle.h | 6 ++++++ platform/FileSystemLike.h | 9 ++++++++- platform/FunctionPointer.h | 16 +++++++++------- platform/LocalFileSystem.h | 9 ++++++++- platform/PlatformMutex.h | 9 ++++++++- platform/SingletonPtr.h | 8 ++++++-- platform/Stream.h | 8 ++++++-- platform/Transaction.h | 9 +++++++-- platform/mbed_application.h | 5 +---- platform/mbed_assert.h | 22 +++++++++++++++++++++- platform/mbed_critical.h | 13 ++++++++++--- platform/mbed_debug.h | 10 +++++++++- platform/mbed_error.h | 5 +++++ platform/mbed_interface.h | 11 +++++++++++ platform/mbed_mem_trace.h | 8 ++++++++ platform/mbed_mktime.h | 7 +++++++ platform/mbed_poll.h | 10 +++++++++- platform/mbed_preprocessor.h | 6 ++++++ platform/mbed_retarget.h | 12 ++++++++++++ platform/mbed_rtc_time.h | 5 +++++ platform/mbed_semihost_api.h | 4 +--- platform/mbed_sleep.h | 6 ++++++ platform/mbed_stats.h | 12 ++++++++++++ platform/mbed_toolchain.h | 6 ++++++ platform/mbed_wait_api.h | 6 ++++++ rtos/EventFlags.h | 10 ++++++++-- rtos/Mail.h | 11 +++++++++-- rtos/MemoryPool.h | 10 ++++++++-- rtos/Mutex.h | 11 ++++++++--- rtos/Queue.h | 9 +++++++-- rtos/RtosTimer.h | 10 ++++++++-- rtos/Semaphore.h | 9 +++++++-- rtos/Thread.h | 9 +++++++-- rtos/rtos_idle.h | 11 +++++++++++ 48 files changed, 404 insertions(+), 81 deletions(-) diff --git a/doxyfile_options b/doxyfile_options index 959cb706cf4..9ba838c104a 100644 --- a/doxyfile_options +++ b/doxyfile_options @@ -32,7 +32,7 @@ DOXYFILE_ENCODING = UTF-8 # title of most generated pages and in a few other places. # The default value is: My Project. -PROJECT_NAME = "My Project" +PROJECT_NAME = "Mbed OS Reference" # The PROJECT_NUMBER tag can be used to enter a project or revision number. This # could be handy for archiving the generated documentation or if some version diff --git a/drivers/UARTSerial.h b/drivers/UARTSerial.h index c0069adcb75..f6ff523f8f6 100644 --- a/drivers/UARTSerial.h +++ b/drivers/UARTSerial.h @@ -39,6 +39,13 @@ namespace mbed { +/** \addtogroup drivers */ + +/** Class providing buffered UART communication functionality using separate circular buffer for send and receive channels + * + * @ingroup drivers + */ + class UARTSerial : private SerialBase, public FileHandle, private NonCopyable { public: diff --git a/platform/ATCmdParser.h b/platform/ATCmdParser.h index 1201a6055f5..c8fb0406340 100644 --- a/platform/ATCmdParser.h +++ b/platform/ATCmdParser.h @@ -24,6 +24,15 @@ #include #include "Callback.h" +namespace mbed { + +/** \addtogroup platform */ +/** @{*/ +/** + * \defgroup platform_ATCmdParser ATCmdParser class + * @{ + */ + /** * Parser class for parsing AT commands * @@ -43,8 +52,6 @@ * @endcode */ -namespace mbed { - class ATCmdParser : private NonCopyable { private: @@ -299,6 +306,11 @@ class ATCmdParser : private NonCopyable */ bool process_oob(void); }; + +/**@}*/ + +/**@}*/ + } //namespace mbed #endif //MBED_ATCMDPARSER_H diff --git a/platform/CThunk.h b/platform/CThunk.h index 90e150b6a9c..73c3aba1389 100644 --- a/platform/CThunk.h +++ b/platform/CThunk.h @@ -1,6 +1,10 @@ /** \addtogroup platform */ /** @{*/ +/** + * \defgroup platform_CThunk CThunk class + * @{ + */ /* General C++ Object Thunking class * * - allows direct callbacks to non-static C++ class functions @@ -73,13 +77,11 @@ /* IRQ/Exception compatible thunk entry function */ typedef void (*CThunkEntry)(void); -/** @}*/ /** * Class for created a pointer with data bound to it * * @note Synchronization level: Not protected - * @ingroup platform */ template class CThunk @@ -243,5 +245,9 @@ class CThunk } }; +/**@}*/ + +/**@}*/ + #endif/*__CTHUNK_H__*/ diff --git a/platform/CallChain.h b/platform/CallChain.h index 42e97e6d288..ffb786d2c2a 100644 --- a/platform/CallChain.h +++ b/platform/CallChain.h @@ -22,7 +22,17 @@ #include namespace mbed { + + +typedef Callback *pFunctionPointer_t; +class CallChainLink; + /** \addtogroup platform */ +/** @{*/ +/** + * \defgroup platform_CallChain CallChain class + * @{ + */ /** Group one or more functions in an instance of a CallChain, then call them in * sequence using CallChain::call(). Used mostly by the interrupt chaining code, @@ -60,12 +70,7 @@ namespace mbed { * chain.call(); * } * @endcode - * @ingroup platform */ - -typedef Callback *pFunctionPointer_t; -class CallChainLink; - class CallChain : private NonCopyable { public: /** Create an empty chain @@ -183,6 +188,10 @@ class CallChain : private NonCopyable { CallChainLink *_chain; }; +/**@}*/ + +/**@}*/ + } // namespace mbed #endif diff --git a/platform/Callback.h b/platform/Callback.h index cb2c5a95b30..b300afefadc 100644 --- a/platform/Callback.h +++ b/platform/Callback.h @@ -24,12 +24,15 @@ namespace mbed { /** \addtogroup platform */ - +/** @{*/ +/** + * \defgroup platform_Callback Callback class + * @{ + */ /** Callback class based on template specialization * * @note Synchronization level: Not protected - * @ingroup platform */ template class Callback; @@ -67,7 +70,6 @@ namespace detail { /** Callback class based on template specialization * * @note Synchronization level: Not protected - * @ingroup platform */ template class Callback { @@ -642,7 +644,6 @@ class Callback { /** Callback class based on template specialization * * @note Synchronization level: Not protected - * @ingroup platform */ template class Callback { @@ -1218,7 +1219,6 @@ class Callback { /** Callback class based on template specialization * * @note Synchronization level: Not protected - * @ingroup platform */ template class Callback { @@ -1795,7 +1795,6 @@ class Callback { /** Callback class based on template specialization * * @note Synchronization level: Not protected - * @ingroup platform */ template class Callback { @@ -2373,7 +2372,6 @@ class Callback { /** Callback class based on template specialization * * @note Synchronization level: Not protected - * @ingroup platform */ template class Callback { @@ -2952,7 +2950,6 @@ class Callback { /** Callback class based on template specialization * * @note Synchronization level: Not protected - * @ingroup platform */ template class Callback { @@ -4546,6 +4543,9 @@ Callback callback(const volatile U *obj, R (*func)(const return Callback(func, obj); } +/**@}*/ + +/**@}*/ } // namespace mbed diff --git a/platform/CircularBuffer.h b/platform/CircularBuffer.h index bb7fd38c547..b721791b810 100644 --- a/platform/CircularBuffer.h +++ b/platform/CircularBuffer.h @@ -20,11 +20,15 @@ namespace mbed { /** \addtogroup platform */ +/** @{*/ +/** + * \defgroup platform_CircularBuffer CircularBuffer functions + * @{ + */ /** Templated Circular buffer class * * @note Synchronization level: Interrupt safe - * @ingroup platform */ template class CircularBuffer { @@ -112,6 +116,10 @@ class CircularBuffer { volatile bool _full; }; +/**@}*/ + +/**@}*/ + } #endif diff --git a/platform/CriticalSectionLock.h b/platform/CriticalSectionLock.h index 5199fbaf691..cb619769c8e 100644 --- a/platform/CriticalSectionLock.h +++ b/platform/CriticalSectionLock.h @@ -22,6 +22,13 @@ namespace mbed { +/** \addtogroup platform */ +/** @{*/ +/** + * \defgroup platform_CriticalSectionLock CriticalSectionLock functions + * @{ + */ + /** RAII object for disabling, then restoring, interrupt state * Usage: * @code @@ -65,6 +72,9 @@ class CriticalSectionLock { } }; +/**@}*/ + +/**@}*/ } // namespace mbed diff --git a/platform/DeepSleepLock.h b/platform/DeepSleepLock.h index 17abe15614f..6b64022fc06 100644 --- a/platform/DeepSleepLock.h +++ b/platform/DeepSleepLock.h @@ -22,6 +22,12 @@ namespace mbed { +/** \addtogroup platform */ +/** @{*/ +/** + * \defgroup platform_DeepSleepLock DeepSleepLock functions + * @{ + */ /** RAII object for disabling, then restoring the deep sleep mode * Usage: @@ -82,6 +88,11 @@ class DeepSleepLock { } }; +/**@}*/ + +/**@}*/ + + } #endif diff --git a/platform/DirHandle.h b/platform/DirHandle.h index b1dcfe2b1f0..116ebf581dc 100644 --- a/platform/DirHandle.h +++ b/platform/DirHandle.h @@ -23,6 +23,11 @@ namespace mbed { /** \addtogroup platform */ +/** @{*/ +/** + * \defgroup platform_DirHandle DirHandle functions + * @{ + */ /** Represents a directory stream. Objects of this type are returned @@ -40,7 +45,6 @@ namespace mbed { * * @note to create a directory, @see Dir * @note Synchronization level: Set by subclass - * @ingroup platform */ class DirHandle : private NonCopyable { public: @@ -142,7 +146,9 @@ class DirHandle : private NonCopyable { virtual void seekdir(off_t location) { seek(location); } }; +/**@}*/ +/**@}*/ } // namespace mbed #endif /* MBED_DIRHANDLE_H */ diff --git a/platform/FileBase.h b/platform/FileBase.h index 5df9ef8550d..4f6371923b2 100644 --- a/platform/FileBase.h +++ b/platform/FileBase.h @@ -27,19 +27,22 @@ typedef int FILEHANDLE; #include "platform/NonCopyable.h" namespace mbed { -/** \addtogroup platform */ -/** @{*/ - + typedef enum { FilePathType, FileSystemPathType } PathType; -/** @}*/ +/** \addtogroup platform */ +/** @{*/ /** - * @class FileBase - * @ingroup platform + * \defgroup platform_FileBase FileBase class + * @{ */ +/** Class FileBase + * + */ + class FileBase : private NonCopyable { public: FileBase(const char *name, PathType t); @@ -62,6 +65,10 @@ class FileBase : private NonCopyable { const PathType _path_type; }; +/**@}*/ + +/**@}*/ + } // namespace mbed #endif diff --git a/platform/FileHandle.h b/platform/FileHandle.h index a6b306b3fa6..6a769b4b8f2 100644 --- a/platform/FileHandle.h +++ b/platform/FileHandle.h @@ -26,6 +26,11 @@ typedef int FILEHANDLE; namespace mbed { /** \addtogroup platform */ +/** @{*/ +/** + * \defgroup platform_FileHandle FileHandle functions + * @{ + */ /** Class FileHandle @@ -36,7 +41,6 @@ namespace mbed { * * @note to create a file, @see File * @note Synchronization level: Set by subclass - * @ingroup platform */ class FileHandle : private NonCopyable { public: @@ -254,6 +258,11 @@ class FileHandle : private NonCopyable { std::FILE *fdopen(FileHandle *fh, const char *mode); +/**@}*/ + +/**@}*/ + + } // namespace mbed #endif diff --git a/platform/FileLike.h b/platform/FileLike.h index 91a3f304d09..e75be50bfd3 100644 --- a/platform/FileLike.h +++ b/platform/FileLike.h @@ -23,14 +23,17 @@ namespace mbed { /** \addtogroup platform */ - - -/* Class FileLike +/** @{*/ +/** + * \defgroup platform_FileLike FileLike class + * @{ + */ +/** Class FileLike + * * A file-like object is one that can be opened with fopen by * fopen("/name", mode). * * @note Synchronization level: Set by subclass - * @ingroup platform */ class FileLike : public FileHandle, public FileBase, private NonCopyable { public: @@ -42,6 +45,9 @@ class FileLike : public FileHandle, public FileBase, private NonCopyable { */ virtual int mkdir(const char *path, mode_t mode); }; +/**@}*/ +/**@}*/ } // namespace mbed diff --git a/platform/FileSystemLike.h b/platform/FileSystemLike.h index d8923391d6a..aef7913cf67 100644 --- a/platform/FileSystemLike.h +++ b/platform/FileSystemLike.h @@ -25,6 +25,11 @@ namespace mbed { /** \addtogroup platform */ +/** @{*/ +/** + * \defgroup platform_FileSystemLike FileSystemLike functions + * @{ + */ /** A filesystem-like object is one that can be used to open file-like @@ -34,7 +39,6 @@ namespace mbed { * of the rest of the functions just return error values). * * @note Synchronization level: Set by subclass - * @ingroup platform */ class FileSystemLike : public FileSystemHandle, public FileBase, private NonCopyable { public: @@ -79,6 +83,9 @@ class FileSystemLike : public FileSystemHandle, public FileBase, private NonCopy } }; +/**@}*/ + +/**@}*/ } // namespace mbed diff --git a/platform/FunctionPointer.h b/platform/FunctionPointer.h index a57195f7a83..18c34c2106e 100644 --- a/platform/FunctionPointer.h +++ b/platform/FunctionPointer.h @@ -23,13 +23,14 @@ namespace mbed { /** \addtogroup platform */ - +/** @{*/ +/** + * \defgroup platform_FunctionPointer FunctionPointer class + * @{ + */ // Declarations for backwards compatibility // To be foward compatible, code should adopt the Callback class -/** - * @ingroup platform - */ template class FunctionPointerArg1 : public Callback { public: @@ -61,9 +62,6 @@ class FunctionPointerArg1 : public Callback { } }; -/** - * @ingroup platform - */ template class FunctionPointerArg1 : public Callback { public: @@ -97,6 +95,10 @@ class FunctionPointerArg1 : public Callback { typedef FunctionPointerArg1 FunctionPointer; +/**@}*/ + +/**@}*/ + } // namespace mbed diff --git a/platform/LocalFileSystem.h b/platform/LocalFileSystem.h index 3bd64d8377e..ce0baafaf07 100644 --- a/platform/LocalFileSystem.h +++ b/platform/LocalFileSystem.h @@ -27,9 +27,12 @@ namespace mbed { /** \addtogroup platform */ /** @{*/ +/** + * \defgroup platform_LocalFileSystem LocalFileSystem functions + * @{ + */ FILEHANDLE local_file_open(const char* name, int flags); -/** @}*/ /** * @class LocalFileHandle @@ -112,6 +115,10 @@ class LocalFileSystem : public FileSystemLike, private NonCopyable { public: @@ -50,3 +54,6 @@ class PlatformMutex : private mbed::NonCopyable { #endif +/**@}*/ + +/**@}*/ diff --git a/platform/SingletonPtr.h b/platform/SingletonPtr.h index 369d6dbe2f1..848fd099f46 100644 --- a/platform/SingletonPtr.h +++ b/platform/SingletonPtr.h @@ -1,6 +1,10 @@ /** \addtogroup platform */ /** @{*/ +/** + * \defgroup platform_SingletonPtr SingletonPtr class + * @{ + */ /* mbed Microcontroller Library * Copyright (c) 2006-2013 ARM Limited * @@ -55,7 +59,6 @@ inline static void singleton_unlock(void) osMutexRelease (singleton_mutex_id); #endif } -/** @}*/ /** Utility class for creating an using a singleton * @@ -68,7 +71,6 @@ inline static void singleton_unlock(void) * @note: This class is lazily initialized on first use. * This class is a POD type so if it is not used it will * be garbage collected. - * @ingroup platform */ template struct SingletonPtr { @@ -108,4 +110,6 @@ struct SingletonPtr { }; #endif +/**@}*/ +/**@}*/ diff --git a/platform/Stream.h b/platform/Stream.h index fd74b0520f1..20b7e44afcb 100644 --- a/platform/Stream.h +++ b/platform/Stream.h @@ -26,16 +26,18 @@ namespace mbed { /** \addtogroup platform */ /** @{*/ +/** + * \defgroup platform_Stream Stream class + * @{ + */ extern void mbed_set_unbuffered_stream(std::FILE *_file); extern int mbed_getc(std::FILE *_file); extern char* mbed_gets(char *s, int size, std::FILE *_file); -/** @}*/ /** File stream * * @note Synchronization level: Set by subclass - * @ingroup platform */ class Stream : public FileLike, private NonCopyable { @@ -82,7 +84,9 @@ class Stream : public FileLike, private NonCopyable { // Stub } }; +/**@}*/ +/**@}*/ } // namespace mbed #endif diff --git a/platform/Transaction.h b/platform/Transaction.h index 8e262368800..23f03e07f22 100644 --- a/platform/Transaction.h +++ b/platform/Transaction.h @@ -21,9 +21,13 @@ namespace mbed { /** \addtogroup platform */ +/** @{*/ +/** + * \defgroup platform_Transaction Transaction class + * @{ + */ /** Transaction structure - * @ingroup platform */ typedef struct { void *tx_buffer; /**< Tx buffer */ @@ -38,7 +42,6 @@ typedef struct { /** Transaction class defines a transaction. * * @note Synchronization level: Not protected - * @ingroup platform */ template class Transaction { @@ -72,7 +75,9 @@ class Transaction { Class* _obj; transaction_t _data; }; +/**@}*/ +/**@}*/ } #endif diff --git a/platform/mbed_application.h b/platform/mbed_application.h index 633b6a8572e..43b4813f755 100644 --- a/platform/mbed_application.h +++ b/platform/mbed_application.h @@ -1,6 +1,3 @@ - -/** \addtogroup platform */ -/** @{*/ /* mbed Microcontroller Library * Copyright (c) 2017-2017 ARM Limited * @@ -16,6 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + #ifndef MBED_APPLICATION_H #define MBED_APPLICATION_H @@ -52,4 +50,3 @@ void mbed_start_application(uintptr_t address); #endif -/** @}*/ diff --git a/platform/mbed_assert.h b/platform/mbed_assert.h index bd86983fc8b..d651f1e8c00 100644 --- a/platform/mbed_assert.h +++ b/platform/mbed_assert.h @@ -1,6 +1,10 @@ /** \addtogroup platform */ /** @{*/ +/** + * \defgroup platform_Assert Assert macros + * @{ + */ /* mbed Microcontroller Library * Copyright (c) 2006-2013 ARM Limited * @@ -39,6 +43,19 @@ void mbed_assert_internal(const char *expr, const char *file, int line); } #endif +/** MBED_ASSERT + * Declare runtime assertions: results in runtime error if condition is false + * + * @note + * Use of MBED_ASSERT is limited debug builds only. + * + * @code + * + * int Configure(serial_t *obj) { + * MBED_ASSERT(obj); + * } + * @endcode + */ #ifdef NDEBUG #define MBED_ASSERT(expr) ((void)0) @@ -110,4 +127,7 @@ do { \ #endif -/** @}*/ +/**@}*/ + +/**@}*/ + diff --git a/platform/mbed_critical.h b/platform/mbed_critical.h index 8aa314a8e99..0b7cb2a8b1a 100644 --- a/platform/mbed_critical.h +++ b/platform/mbed_critical.h @@ -1,6 +1,4 @@ -/** \addtogroup platform */ -/** @{*/ /* * Copyright (c) 2015-2016, ARM Limited, All Rights Reserved * SPDX-License-Identifier: Apache-2.0 @@ -29,6 +27,12 @@ extern "C" { #endif +/** \addtogroup platform */ +/** @{*/ +/** + * \defgroup platform_critical critical section function + * @{ + */ /** Determine the current interrupts enabled state * @@ -363,8 +367,11 @@ void *core_util_atomic_decr_ptr(void **valuePtr, ptrdiff_t delta); #ifdef __cplusplus } // extern "C" #endif +/**@}*/ +/**@}*/ #endif // __MBED_UTIL_CRITICAL_H__ -/** @}*/ + + diff --git a/platform/mbed_debug.h b/platform/mbed_debug.h index 761c1eb99f6..5f9a19805d6 100644 --- a/platform/mbed_debug.h +++ b/platform/mbed_debug.h @@ -1,6 +1,11 @@ /** \addtogroup platform */ /** @{*/ +/** + * \defgroup platform_debug Debug functions + * @{ + */ + /* mbed Microcontroller Library * Copyright (c) 2006-2013 ARM Limited * @@ -68,4 +73,7 @@ static inline void debug_if(int condition, const char *format, ...) { #endif -/** @}*/ +/**@}*/ + +/**@}*/ + diff --git a/platform/mbed_error.h b/platform/mbed_error.h index 1da55135b9e..8f5cd9baff1 100644 --- a/platform/mbed_error.h +++ b/platform/mbed_error.h @@ -1,6 +1,10 @@ /** \addtogroup platform */ /** @{*/ +/** + * \defgroup platform_error Error functions + * @{ + */ /* mbed Microcontroller Library * Copyright (c) 2006-2013 ARM Limited * @@ -75,3 +79,4 @@ void error(const char* format, ...); #endif /** @}*/ +/** @}*/ diff --git a/platform/mbed_interface.h b/platform/mbed_interface.h index 538a6a7cbfd..94baa34f775 100644 --- a/platform/mbed_interface.h +++ b/platform/mbed_interface.h @@ -1,6 +1,11 @@ /** \addtogroup platform */ /** @{*/ +/** + * \defgroup platform_interface Network interface and other utility functions + * @{ + */ + /* mbed Microcontroller Library * Copyright (c) 2006-2013 ARM Limited * @@ -42,6 +47,11 @@ extern "C" { #if DEVICE_SEMIHOST +/** + * \defgroup platform_interface interface functions + * @{ + */ + /** Functions to control the mbed interface * * mbed Microcontrollers have a built-in interface to provide functionality such as @@ -137,6 +147,7 @@ void mbed_error_printf(const char* format, ...); * */ void mbed_error_vfprintf(const char * format, va_list arg); +/** @}*/ #ifdef __cplusplus } diff --git a/platform/mbed_mem_trace.h b/platform/mbed_mem_trace.h index 0267255ba78..59da721e2fe 100644 --- a/platform/mbed_mem_trace.h +++ b/platform/mbed_mem_trace.h @@ -1,6 +1,7 @@ /** \addtogroup platform */ /** @{*/ + /* mbed Microcontroller Library * Copyright (c) 2006-2016 ARM Limited * @@ -35,6 +36,11 @@ enum { MBED_MEM_TRACE_FREE }; +/** + * \defgroup platform_mem_trace mem_trace functions + * @{ + */ + /* Prefix for the output of the default tracer */ #define MBED_MEM_DEFAULT_TRACER_PREFIX "#" @@ -133,6 +139,8 @@ void mbed_mem_trace_free(void *ptr, void *caller); */ void mbed_mem_trace_default_callback(uint8_t op, void *res, void *caller, ...); +/** @}*/ + #ifdef __cplusplus } #endif diff --git a/platform/mbed_mktime.h b/platform/mbed_mktime.h index b28525224c4..dd302702e40 100644 --- a/platform/mbed_mktime.h +++ b/platform/mbed_mktime.h @@ -28,6 +28,11 @@ extern "C" { #endif +/** + * \defgroup platform_mktime mktime functions + * @{ + */ + /** Compute if a year is a leap year or not. * * @param year The year to test it shall be in the range [70:138]. Year 0 is @@ -89,6 +94,8 @@ time_t _rtc_mktime(const struct tm* calendar_time); */ bool _rtc_localtime(time_t timestamp, struct tm* calendar_time); +/** @}*/ + #ifdef __cplusplus } #endif diff --git a/platform/mbed_poll.h b/platform/mbed_poll.h index 635733bb98f..f9c894c21f6 100644 --- a/platform/mbed_poll.h +++ b/platform/mbed_poll.h @@ -27,7 +27,11 @@ namespace mbed { class FileHandle; /** \addtogroup platform */ - +/** @{*/ +/** + * \defgroup platform_poll poll functions + * @{ + */ struct pollfh { FileHandle *fh; @@ -47,6 +51,10 @@ struct pollfh { */ int poll(pollfh fhs[], unsigned nfhs, int timeout); +/**@}*/ + +/**@}*/ + } // namespace mbed #endif //MBED_POLL_H diff --git a/platform/mbed_preprocessor.h b/platform/mbed_preprocessor.h index 5e72d99f873..63312e8b13b 100644 --- a/platform/mbed_preprocessor.h +++ b/platform/mbed_preprocessor.h @@ -1,5 +1,10 @@ /** \addtogroup platform */ /** @{*/ +/** + * \defgroup platform_preprocessor preprocessor macros + * @{ + */ + /* mbed Microcontroller Library * Copyright (c) 2006-2013 ARM Limited * @@ -51,3 +56,4 @@ #endif /** @}*/ +/** @}*/ diff --git a/platform/mbed_retarget.h b/platform/mbed_retarget.h index a12abc219b9..0f3e30b5e5c 100644 --- a/platform/mbed_retarget.h +++ b/platform/mbed_retarget.h @@ -58,13 +58,21 @@ typedef unsigned int gid_t; ///< Group ID #endif +/** \addtogroup platform */ +/** @{*/ +/** + * \defgroup platform_retarget Retarget functions + * @{ + */ /* DIR declarations must also be here */ #if __cplusplus namespace mbed { + class FileHandle; class DirHandle; std::FILE *mbed_fdopen(FileHandle *fh, const char *mode); + } typedef mbed::DirHandle DIR; #else @@ -438,4 +446,8 @@ enum { DT_SOCK, ///< This is a UNIX domain socket. }; +/**@}*/ + +/**@}*/ + #endif /* RETARGET_H */ diff --git a/platform/mbed_rtc_time.h b/platform/mbed_rtc_time.h index 84a3739ec32..ee3e7ec7a1e 100644 --- a/platform/mbed_rtc_time.h +++ b/platform/mbed_rtc_time.h @@ -1,6 +1,10 @@ /** \addtogroup platform */ /** @{*/ +/** + * \defgroup platform_rtc_time rtc_time functions + * @{ + */ /* mbed Microcontroller Library * Copyright (c) 2006-2013 ARM Limited * @@ -90,3 +94,4 @@ void attach_rtc(time_t (*read_rtc)(void), void (*write_rtc)(time_t), void (*init #endif /** @}*/ +/** @}*/ diff --git a/platform/mbed_semihost_api.h b/platform/mbed_semihost_api.h index 9127c5ff006..611cce69c07 100644 --- a/platform/mbed_semihost_api.h +++ b/platform/mbed_semihost_api.h @@ -1,6 +1,4 @@ -/** \addtogroup platform */ -/** @{*/ /* mbed Microcontroller Library * Copyright (c) 2006-2013 ARM Limited * @@ -95,4 +93,4 @@ int semihost_disabledebug(void); #endif -/** @}*/ + diff --git a/platform/mbed_sleep.h b/platform/mbed_sleep.h index 4f635d452ae..23fa5150f42 100644 --- a/platform/mbed_sleep.h +++ b/platform/mbed_sleep.h @@ -1,6 +1,11 @@ /** \addtogroup platform */ /** @{*/ +/** + * \defgroup platform_sleep Sleep functions + * @{ + */ + /* mbed Microcontroller Library * Copyright (c) 2006-2017 ARM Limited * @@ -169,3 +174,4 @@ __INLINE static void deepsleep(void) #endif /** @}*/ +/** @}*/ diff --git a/platform/mbed_stats.h b/platform/mbed_stats.h index 99662af4142..c997baefab2 100644 --- a/platform/mbed_stats.h +++ b/platform/mbed_stats.h @@ -1,6 +1,10 @@ /** \addtogroup platform */ /** @{*/ +/** + * \defgroup platform_stats stats functions + * @{ + */ /* mbed Microcontroller Library * Copyright (c) 2016-2016 ARM Limited * @@ -25,6 +29,9 @@ extern "C" { #endif +/** + * struct mbed_stats_heap_t definition + */ typedef struct { uint32_t current_size; /**< Bytes allocated currently. */ uint32_t max_size; /**< Max bytes allocated at a given time. */ @@ -41,6 +48,9 @@ typedef struct { */ void mbed_stats_heap_get(mbed_stats_heap_t *stats); +/** + * struct mbed_stats_stack_t definition + */ typedef struct { uint32_t thread_id; /**< Identifier for thread that owns the stack or 0 if multiple threads. */ uint32_t max_size; /**< Maximum number of bytes used on the stack. */ @@ -73,3 +83,5 @@ size_t mbed_stats_stack_get_each(mbed_stats_stack_t *stats, size_t count); #endif /** @}*/ + +/** @}*/ diff --git a/platform/mbed_toolchain.h b/platform/mbed_toolchain.h index f5d5e79e611..a911e9c9974 100644 --- a/platform/mbed_toolchain.h +++ b/platform/mbed_toolchain.h @@ -1,6 +1,11 @@ /** \addtogroup platform */ /** @{*/ +/** + * \defgroup platform_toolchain Toolchain functions + * @{ + */ + /* mbed Microcontroller Library * Copyright (c) 2006-2013 ARM Limited * @@ -382,3 +387,4 @@ typedef int FILEHANDLE; #endif /** @}*/ +/** @}*/ diff --git a/platform/mbed_wait_api.h b/platform/mbed_wait_api.h index 91619def4ac..a58509f741a 100644 --- a/platform/mbed_wait_api.h +++ b/platform/mbed_wait_api.h @@ -1,6 +1,11 @@ /** \addtogroup platform */ /** @{*/ +/** + * \defgroup platform_wait_api wait_api functions + * @{ + */ + /* mbed Microcontroller Library * Copyright (c) 2006-2013 ARM Limited * @@ -70,3 +75,4 @@ void wait_us(int us); #endif /** @}*/ +/** @}*/ diff --git a/rtos/EventFlags.h b/rtos/EventFlags.h index 8f0e2b20ed2..80ca65e202e 100644 --- a/rtos/EventFlags.h +++ b/rtos/EventFlags.h @@ -32,7 +32,11 @@ namespace rtos { /** \addtogroup rtos */ /** @{*/ - +/** + * \defgroup rtos_EventFlags EventFlags class + * @{ + */ + /** The EventFlags class is used to signal or wait for an arbitrary event or events. @note EventFlags support 31 flags so the MSB flag is ignored, it is used to return an error code (@a osFlagsError) @@ -94,7 +98,9 @@ class EventFlags : private mbed::NonCopyable { mbed_rtos_storage_event_flags_t _obj_mem; }; +/** @}*/ +/** @}*/ + } #endif -/** @}*/ diff --git a/rtos/Mail.h b/rtos/Mail.h index 602907e34e3..83a3a246569 100644 --- a/rtos/Mail.h +++ b/rtos/Mail.h @@ -38,7 +38,11 @@ using namespace rtos; namespace rtos { /** \addtogroup rtos */ /** @{*/ - +/** + * \defgroup rtos_Mail Mail class + * @{ + */ + /** The Mail class allow to control, send, receive, or wait for mail. A mail is a memory block that is send to a thread or interrupt service routine. @tparam T data type of a single message element. @@ -103,9 +107,12 @@ class Mail : private mbed::NonCopyable > { MemoryPool _pool; }; +/** @}*/ +/** @}*/ + } #endif -/** @}*/ + diff --git a/rtos/MemoryPool.h b/rtos/MemoryPool.h index 361ae6518fa..42bc45dfb5c 100644 --- a/rtos/MemoryPool.h +++ b/rtos/MemoryPool.h @@ -33,7 +33,11 @@ namespace rtos { /** \addtogroup rtos */ /** @{*/ - +/** + * \defgroup rtos_MemoryPool MemoryPool class + * @{ + */ + /** Define and manage fixed-size memory pools of objects of a given type. @tparam T data type of a single object (element). @tparam queue_sz maximum number of objects (elements) in the memory pool. @@ -100,8 +104,10 @@ class MemoryPool : private mbed::NonCopyable > { char _pool_mem[((sizeof(T) + 3) & ~3) * pool_sz]; mbed_rtos_storage_mem_pool_t _obj_mem; }; +/** @}*/ +/** @}*/ } #endif -/** @}*/ + diff --git a/rtos/Mutex.h b/rtos/Mutex.h index 4f1ed8a6aae..1547da19be9 100644 --- a/rtos/Mutex.h +++ b/rtos/Mutex.h @@ -32,7 +32,11 @@ namespace rtos { /** \addtogroup rtos */ /** @{*/ - +/** + * \defgroup rtos_Mutex Mutex class + * @{ + */ + /** The Mutex class is used to synchronize the execution of threads. This is for example used to protect access to a shared resource. @@ -85,8 +89,9 @@ class Mutex : private mbed::NonCopyable { osMutexAttr_t _attr; mbed_rtos_storage_mutex_t _obj_mem; }; - +/** @}*/ +/** @}*/ } #endif -/** @}*/ + diff --git a/rtos/Queue.h b/rtos/Queue.h index 56739522ae9..a80a3a03850 100644 --- a/rtos/Queue.h +++ b/rtos/Queue.h @@ -34,7 +34,11 @@ namespace rtos { /** \addtogroup rtos */ /** @{*/ - +/** + * \defgroup rtos_EventFlags EventFlags class + * @{ + */ + /** The Queue class allow to control, send, receive, or wait for messages. A message can be a integer or pointer value to a certain type T that is send to a thread or interrupt service routine. @@ -119,8 +123,9 @@ class Queue : private mbed::NonCopyable > { char _queue_mem[queue_sz * (sizeof(T*) + sizeof(mbed_rtos_storage_message_t))]; mbed_rtos_storage_msg_queue_t _obj_mem; }; +/** @}*/ +/** @}*/ } #endif -/** @}*/ diff --git a/rtos/RtosTimer.h b/rtos/RtosTimer.h index d96de829e14..ef52eb094cb 100644 --- a/rtos/RtosTimer.h +++ b/rtos/RtosTimer.h @@ -33,7 +33,11 @@ namespace rtos { /** \addtogroup rtos */ /** @{*/ - +/** + * \defgroup rtos_RtosTimer RtosTimer class + * @{ + */ + /** The RtosTimer class allow creating and and controlling of timer functions in the system. A timer function is called when a time period expires whereby both on-shot and periodic timers are possible. A timer can be started, restarted, or stopped. @@ -161,9 +165,11 @@ class RtosTimer : private mbed::NonCopyable { mbed_rtos_storage_timer_t _obj_mem; mbed::Callback _function; }; +/** @}*/ +/** @}*/ } #endif -/** @}*/ + diff --git a/rtos/Semaphore.h b/rtos/Semaphore.h index 80dc928ede4..8a5ce7d1ac4 100644 --- a/rtos/Semaphore.h +++ b/rtos/Semaphore.h @@ -31,6 +31,10 @@ namespace rtos { /** \addtogroup rtos */ /** @{*/ +/** + * \defgroup rtos_Semaphore Semaphore class + * @{ + */ /** The Semaphore class is used to manage and protect access to a set of shared resources. * @@ -74,8 +78,9 @@ class Semaphore : private mbed::NonCopyable { osSemaphoreAttr_t _attr; mbed_rtos_storage_semaphore_t _obj_mem; }; - +/** @}*/ +/** @}*/ } #endif -/** @}*/ + diff --git a/rtos/Thread.h b/rtos/Thread.h index cf92877d7e0..d67ad3acf81 100644 --- a/rtos/Thread.h +++ b/rtos/Thread.h @@ -35,6 +35,10 @@ namespace rtos { /** \addtogroup rtos */ /** @{*/ +/** + * \defgroup rtos_Thread Thread class + * @{ + */ /** The Thread class allow defining, creating, and controlling thread functions in the system. * @@ -370,8 +374,9 @@ class Thread : private mbed::NonCopyable { mbed_rtos_storage_thread_t _obj_mem; bool _finished; }; - +/** @}*/ +/** @}*/ } #endif -/** @}*/ + diff --git a/rtos/rtos_idle.h b/rtos/rtos_idle.h index 5fa9fb776c0..c2894c23e30 100644 --- a/rtos/rtos_idle.h +++ b/rtos/rtos_idle.h @@ -31,7 +31,17 @@ extern "C" { #endif +/** + * \defgroup rtos_Idle Idle hook function + * @{ + */ +/** + @note + Sets the hook function called by idle task + @param fptr Hook function pointer. + */ void rtos_attach_idle_hook(void (*fptr)(void)); +/** @}*/ #ifdef __cplusplus } @@ -40,3 +50,4 @@ void rtos_attach_idle_hook(void (*fptr)(void)); #endif /** @}*/ + From 37214ab69540bd39f3abd3a1b0e53f995e12474c Mon Sep 17 00:00:00 2001 From: Senthil Ramakrishnan Date: Fri, 27 Oct 2017 15:38:18 -0500 Subject: [PATCH 2/3] Fix comments on mbed_assert.h --- platform/mbed_assert.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/platform/mbed_assert.h b/platform/mbed_assert.h index d651f1e8c00..8aecdcc3fa8 100644 --- a/platform/mbed_assert.h +++ b/platform/mbed_assert.h @@ -47,7 +47,7 @@ void mbed_assert_internal(const char *expr, const char *file, int line); * Declare runtime assertions: results in runtime error if condition is false * * @note - * Use of MBED_ASSERT is limited debug builds only. + * Use of MBED_ASSERT is limited to Debug and Develop builds. * * @code * From 1ba418e41e611ebca694be21f8d59da7b1156a0e Mon Sep 17 00:00:00 2001 From: Senthil Ramakrishnan Date: Tue, 31 Oct 2017 16:17:07 -0500 Subject: [PATCH 3/3] Fixed doxygen_options.json --- doxygen_options.json | 1 + 1 file changed, 1 insertion(+) diff --git a/doxygen_options.json b/doxygen_options.json index 15799752629..ea5063e2928 100644 --- a/doxygen_options.json +++ b/doxygen_options.json @@ -1,4 +1,5 @@ { + "PROJECT_NAME": "Mbed OS Reference", "ENABLE_PREPROCESSING": "YES", "MACRO_EXPANSION": "YES", "EXPAND_ONLY_PREDEF": "NO",