Skip to content

Commit

Permalink
Add helper to print current thread ID.
Browse files Browse the repository at this point in the history
  • Loading branch information
Max Vilimpoc committed Feb 19, 2017
1 parent 81b74cd commit 4cacde3
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
7 changes: 7 additions & 0 deletions mbed_memory_status.c
Expand Up @@ -242,6 +242,13 @@ void print_all_thread_info(void)

_osThreadEnumFree(enumId);
}

void print_current_thread_id(void)
{
DPL("Current thread: ");
debug_print_pointer(osThreadGetId());
DPL("\r\n");
}
#endif // MBED_CONF_RTOS_PRESENT

#if DEBUG_MEMORY_CONTENTS
Expand Down
1 change: 1 addition & 0 deletions mbed_memory_status.h
Expand Up @@ -28,6 +28,7 @@
extern "C" {
#endif

void print_current_thread_id(void);
void print_all_thread_info(void);
void print_heap_and_isr_stack_info(void);

Expand Down

0 comments on commit 4cacde3

Please sign in to comment.