|
EE445M RTOS
Taken at the University of Texas Spring 2015
|

Go to the source code of this file.
Data Structures | |
| struct | clocktime |
Macros | |
| #define | TK_MAX_PRINTBUFFER_LEN 20 |
| #define | TK_PRINT_MODE_HOURS_MINUTES 0 |
| #define | TK_PRINT_MODE_HOURS_MINUTES_SECONDS 1 |
| #define | TK_PRINT_MODE_HOURS_MINUTES_SECONDS_MS 2 |
| #define | TK_TIME_VALID 0 |
| #define | TK_TIME_INVALID_HOURS 1 |
| #define | TK_TIME_INVALID_MINUTES 2 |
| #define | TK_TIME_INVALID_SECONDS 3 |
| #define | TK_TIME_INVALID_MS 4 |
| #define | TK_NUM_HOURS 24 |
| #define | TK_NUM_MINUTES 60 |
| #define | TK_NUM_SECONDS 60 |
| #define | TK_NUM_MS 1000 |
Typedefs | |
| typedef struct clocktime | clocktime |
Functions | |
| clocktime * | TKCreateTimeHandle (char mode) |
| clocktime * | TKDuplicateTimeHandle (clocktime *th) |
| void | TKDestroy (clocktime *tm) |
| char * | TKToString (clocktime *tm) |
| void | TKIncrementHours (clocktime *tm, short hours) |
| void | TKIncrementMinutes (clocktime *tm, short minutes) |
| void | TKIncrementSeconds (clocktime *tm, short seconds) |
| void | TKIncrementMS (clocktime *tm, short ms) |
| short | TKValidateTime (clocktime *tm) |
| void | TKCleanupTime (clocktime *tm) |
| #define TK_NUM_HOURS 24 |
Definition at line 16 of file timekit.h.
Referenced by TKIncrementHours(), and TKValidateTime().
| #define TK_NUM_MINUTES 60 |
Definition at line 17 of file timekit.h.
Referenced by TKIncrementMinutes(), and TKValidateTime().
| #define TK_NUM_MS 1000 |
Definition at line 19 of file timekit.h.
Referenced by TKIncrementMS(), and TKValidateTime().
| #define TK_NUM_SECONDS 60 |
Definition at line 18 of file timekit.h.
Referenced by TKIncrementSeconds(), and TKValidateTime().
| #define TK_PRINT_MODE_HOURS_MINUTES 0 |
Definition at line 6 of file timekit.h.
Referenced by TKToString().
| #define TK_PRINT_MODE_HOURS_MINUTES_SECONDS 1 |
Definition at line 7 of file timekit.h.
Referenced by TKToString().
| #define TK_PRINT_MODE_HOURS_MINUTES_SECONDS_MS 2 |
Definition at line 8 of file timekit.h.
Referenced by demonstrateClock(), main(), and TKToString().
| #define TK_TIME_INVALID_HOURS 1 |
Definition at line 11 of file timekit.h.
Referenced by TKCleanupTime(), and TKValidateTime().
| #define TK_TIME_INVALID_MINUTES 2 |
Definition at line 12 of file timekit.h.
Referenced by TKCleanupTime(), and TKValidateTime().
| #define TK_TIME_INVALID_MS 4 |
Definition at line 14 of file timekit.h.
Referenced by TKCleanupTime(), and TKValidateTime().
| #define TK_TIME_INVALID_SECONDS 3 |
Definition at line 13 of file timekit.h.
Referenced by TKCleanupTime(), and TKValidateTime().
| #define TK_TIME_VALID 0 |
Definition at line 10 of file timekit.h.
Referenced by main(), TKCleanupTime(), and TKValidateTime().
| void TKCleanupTime | ( | clocktime * | tm | ) |
Definition at line 147 of file timekit.c.
References clocktime::hours, clocktime::minutes, clocktime::ms, clocktime::seconds, TK_TIME_INVALID_HOURS, TK_TIME_INVALID_MINUTES, TK_TIME_INVALID_MS, TK_TIME_INVALID_SECONDS, TK_TIME_VALID, and TKValidateTime().

| clocktime* TKCreateTimeHandle | ( | char | mode | ) |
Definition at line 14 of file timekit.c.
References clocktime::hours, clocktime::minutes, clocktime::mode, clocktime::ms, and clocktime::seconds.
Referenced by demonstrateClock().

| void TKDestroy | ( | clocktime * | tm | ) |
Definition at line 24 of file timekit.c.
Referenced by demonstrateClock().

Definition at line 170 of file timekit.c.
References clocktime::hours, clocktime::minutes, clocktime::mode, clocktime::ms, and clocktime::seconds.
| void TKIncrementHours | ( | clocktime * | tm, |
| short | hours | ||
| ) |
Definition at line 55 of file timekit.c.
References clocktime::hours, and TK_NUM_HOURS.
Referenced by demonstrateClock(), main(), and TKIncrementMinutes().

| void TKIncrementMinutes | ( | clocktime * | tm, |
| short | minutes | ||
| ) |
Definition at line 69 of file timekit.c.
References clocktime::minutes, TK_NUM_MINUTES, and TKIncrementHours().
Referenced by demonstrateClock(), main(), and TKIncrementSeconds().


| void TKIncrementMS | ( | clocktime * | tm, |
| short | ms | ||
| ) |
Definition at line 109 of file timekit.c.
References clocktime::ms, TK_NUM_MS, and TKIncrementSeconds().
Referenced by main(), and pseudointerrupt().


| void TKIncrementSeconds | ( | clocktime * | tm, |
| short | seconds | ||
| ) |
Definition at line 89 of file timekit.c.
References clocktime::seconds, TK_NUM_SECONDS, and TKIncrementMinutes().
Referenced by main(), and TKIncrementMS().


| char* TKToString | ( | clocktime * | tm | ) |
Definition at line 31 of file timekit.c.
References clocktime::hours, clocktime::minutes, clocktime::mode, clocktime::ms, clocktime::printBuffer, clocktime::seconds, TK_PRINT_MODE_HOURS_MINUTES, TK_PRINT_MODE_HOURS_MINUTES_SECONDS, and TK_PRINT_MODE_HOURS_MINUTES_SECONDS_MS.
Referenced by main().

| short TKValidateTime | ( | clocktime * | tm | ) |
Definition at line 131 of file timekit.c.
References clocktime::hours, clocktime::minutes, clocktime::mode, clocktime::ms, clocktime::seconds, TK_NUM_HOURS, TK_NUM_MINUTES, TK_NUM_MS, TK_NUM_SECONDS, TK_TIME_INVALID_HOURS, TK_TIME_INVALID_MINUTES, TK_TIME_INVALID_MS, TK_TIME_INVALID_SECONDS, and TK_TIME_VALID.
Referenced by main(), and TKCleanupTime().
