add lib/CMSIS_5 v5.7 locally

This commit is contained in:
hathach
2021-03-02 11:02:16 +07:00
parent 7afaae7ffc
commit 42ff88bdaf
103 changed files with 81252 additions and 0 deletions

View File

@@ -0,0 +1,27 @@
#include "cmsis_os2.h" // CMSIS RTOS header file
/*----------------------------------------------------------------------------
* Thread 1 'Thread_Name': Sample thread
*---------------------------------------------------------------------------*/
osThreadId_t tid_Thread; // thread id
void Thread (void *argument); // thread function
int Init_Thread (void) {
tid_Thread = osThreadNew(Thread, NULL, NULL);
if (tid_Thread == NULL) {
return(-1);
}
return(0);
}
void Thread (void *argument) {
while (1) {
; // Insert thread code here...
osThreadYield(); // suspend thread
}
}