develop/ktcc: Post-SVN tidy
- Move source code from `trunk` into program root directory. - Update build files and include paths. - Note: Line endings standardised from `CRLF` > `LF`, so best to view diffs with whitespace changes hidden.
This commit is contained in:
12
programs/develop/ktcc/lib/libshell/shell_get_pid.c
Normal file
12
programs/develop/ktcc/lib/libshell/shell_get_pid.c
Normal file
@@ -0,0 +1,12 @@
|
||||
#include <shell_api.h>
|
||||
#include <string.h>
|
||||
|
||||
unsigned shell_get_pid()
|
||||
{
|
||||
unsigned pid;
|
||||
__shell_init();
|
||||
*__shell_shm = SHELL_PID;
|
||||
__SHELL_WAIT();
|
||||
memcpy(&pid, __shell_shm+1, sizeof(unsigned));
|
||||
return pid;
|
||||
}
|
Reference in New Issue
Block a user