From 93fdd5dcdbfc4b4b6c41e0b7836ce754cba7f0a1 Mon Sep 17 00:00:00 2001 From: Joel Bodenmann Date: Mon, 19 Nov 2012 20:26:19 +0100 Subject: doxygen of gtimer --- include/gtimer.h | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'include') diff --git a/include/gtimer.h b/include/gtimer.h index 2946e0ea..55bb209b 100644 --- a/include/gtimer.h +++ b/include/gtimer.h @@ -69,7 +69,9 @@ // A callback function (executed in a thread context) typedef void (*GTimerFunction)(void *param); -// A GTimer structure. +/** + * @brief A GTimer structure + */ typedef struct GTimer_t { GTimerFunction fn; void *param; @@ -78,7 +80,7 @@ typedef struct GTimer_t { uint16_t flags; struct GTimer_t *next; struct GTimer_t *prev; - } GTimer; +} GTimer; /*===========================================================================*/ /* External declarations. */ -- cgit v1.2.3 From 19d45eaeda0730c658f3dd9c1b4acacd400e20b1 Mon Sep 17 00:00:00 2001 From: Joel Bodenmann Date: Mon, 19 Nov 2012 20:39:20 +0100 Subject: GTimer doxygen bugfix --- include/gtimer.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'include') diff --git a/include/gtimer.h b/include/gtimer.h index 55bb209b..9e14d4cb 100644 --- a/include/gtimer.h +++ b/include/gtimer.h @@ -21,7 +21,7 @@ * @file gtimer.h * @brief GTIMER GFX User Timer subsystem header file. * - * @addtogroup GEVENT + * @addtogroup GTIMER * @{ */ #ifndef _GTIMER_H -- cgit v1.2.3 From b0fbfdebbaaf7043dc6dfd093fb38e20a065e44e Mon Sep 17 00:00:00 2001 From: Joel Bodenmann Date: Tue, 20 Nov 2012 12:17:59 +0100 Subject: gtimer doxygen fix --- include/gtimer.h | 76 +------------------------------------------------------- 1 file changed, 1 insertion(+), 75 deletions(-) (limited to 'include') diff --git a/include/gtimer.h b/include/gtimer.h index 9e14d4cb..76c52583 100644 --- a/include/gtimer.h +++ b/include/gtimer.h @@ -90,85 +90,10 @@ typedef struct GTimer_t { extern "C" { #endif -/** - * @brief Initialise a timer. - * - * @param[in] pt pointer to a GTimer structure - * - * @api - */ void gtimerInit(GTimer *pt); - -/** - * @brief Set a timer going or alter its properties if it is already going. - * - * @param[in] pt Pointer to a GTimer structure - * @param[in] fn The callback function - * @param[in] param The parameter to pass to the callback function - * @param[in] periodic Is the timer a periodic timer? FALSE is a once-only timer. - * @param[in] millisec The timer period. The following special values are allowed: - * TIME_IMMEDIATE causes the callback function to be called asap. - * A periodic timer with this value will fire once only. - * TIME_INFINITE never timeout (unless triggered by gtimerJab or gtimerJabI) - * - * @note If the timer is already active its properties are updated with the new parameters. - * The current period will be immediately canceled (without the callback function being - * called) and the timer will be restart with the new timer properties. - * @note The callback function should be careful not to over-run the thread stack. - * Define a new value for the macro GTIME_THREAD_STACK_SIZE if you want to - * change the default size. - * @note The callback function should return as quickly as possible as all - * timer callbacks are performed by a single thread. If a callback function - * takes too long it could affect the timer response for other timers. - * @note A timer callback function is not a replacement for a dedicated thread if the - * function wants to perform computationally expensive stuff. - * @note As the callback function is called on GTIMER's thread, the function must make sure it uses - * appropriate synchronisation controls such as semaphores or mutexes around any data - * structures it shares with other threads such as the main application thread. - * - * @api - */ void gtimerStart(GTimer *pt, GTimerFunction fn, void *param, bool_t periodic, systime_t millisec); - -/** - * @brief Stop a timer (periodic or otherwise) - * - * @param[in] pt Pointer to a GTimer structure - * - * @note If the timer is not active this does nothing. - * - * @api - */ void gtimerStop(GTimer *pt); - -/** - * @brief Jab a timer causing the current period to immediate expire - * @details The callback function will be called as soon as possible. - * - * @pre Use from a normal thread context. - * - * @param[in] pt Pointer to a GTimer structure - * - * @note If the timer is not active this does nothing. - * @note Repeated Jabs before the callback function actually happens are ignored. - * - * @api - */ void gtimerJab(GTimer *pt); - -/** - * @brief Jab a timer causing the current period to immediate expire - * @details The callback function will be called as soon as possible. - * - * @pre Use from an interrupt routine context. - * - * @param[in] pt Pointer to a GTimer structure - * - * @note If the timer is not active this does nothing. - * @note Repeated Jabs before the callback function actually happens are ignored. - * - * @api - */ void gtimerJabI(GTimer *pt); #ifdef __cplusplus @@ -179,3 +104,4 @@ void gtimerJabI(GTimer *pt); #endif /* _GTIMER_H */ /** @} */ + -- cgit v1.2.3 From 92ed50dbf0a4bad1ef11d8892e13f0e2aa31a119 Mon Sep 17 00:00:00 2001 From: Joel Bodenmann Date: Tue, 20 Nov 2012 23:12:09 +0100 Subject: gwin doxygen --- include/gwin.h | 45 +++++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 43 insertions(+), 2 deletions(-) (limited to 'include') diff --git a/include/gwin.h b/include/gwin.h index b1c644a6..24eba20c 100644 --- a/include/gwin.h +++ b/include/gwin.h @@ -171,14 +171,55 @@ extern "C" { GHandle gwinCreateWindow(GWindowObject *gw, coord_t x, coord_t y, coord_t width, coord_t height); void gwinDestroyWindow(GHandle gh); -/* Status Functions */ +/** + * @brief Get the X coordinate of the window + * @details Returns the X coordinate of the origin of the window. + * The coordinate is relative to the physical screen zero point. + * + * @param[in] gh The window + */ #define gwinGetScreenX(gh) ((gh)->x) + +/** + * @brief Get the Y coordinate of the window + * @details Returns the Y coordinate of the origin of the window. + * The coordinate is relative to the physical screen zero point. + * + * @param[in] gh The window + */ #define gwinGetScreenY(gh) ((gh)->y) + +/** + * @brief Get the width of the window + * + * @param[in] gh The window + */ #define gwinGetWidth(gh) ((gh)->width) + +/** + * @brief Get the height of the window + * + * @param[in] gh The window + */ #define gwinGetHeight(gh) ((gh)->height) -/* Set up for drawing */ +/** + * @brief Set foreground color + * @details Set the color which will be used to draw + * + * @param[in] gh The window + * @param[in] clr The color to be set + */ #define gwinSetColor(gh, clr) (gh)->color = (clr) + +/** + * @brief Set background color + * @details Set the color which will be used as background + * @note gwinClear() must be called to set the background color + * + * @param[in] gh The window + * @param[in] bgclr The background color + */ #define gwinSetBgColor(gh, bgclr) (gh)->bgcolor = (bgclr) /* Set up for text */ -- cgit v1.2.3