mirror of
https://gitee.com/Lyon1998/pikapython.git
synced 2025-01-15 17:02:53 +08:00
9a734b227e
* 修改requesrment.txt 的内容,目前没有XR806 的Package * bsp 下增加 XR806 openharmony 下的 pikascript 示例,目前只是一个简单的 hello world 工程
30 lines
527 B
C
30 lines
527 B
C
#include "ohos_init.h"
|
|
#include "kernel/os/os.h"
|
|
#include "pikascript/pikascript-api/pikaScript.h"
|
|
|
|
static OS_Thread_t g_main_thread;
|
|
|
|
/* support pikaScript Shell */
|
|
|
|
static void MainThread(void *arg)
|
|
{
|
|
|
|
PikaObj* pikamain = pikaScriptInit();
|
|
while (1) {
|
|
|
|
}
|
|
|
|
}
|
|
|
|
void HelloTestMain(void)
|
|
{
|
|
printf("pikascript Test Start\n");
|
|
|
|
if (OS_ThreadCreate(&g_main_thread, "MainThread", MainThread, NULL,
|
|
OS_THREAD_PRIO_APP, 4 * 1024) != OS_OK) {
|
|
printf("[ERR] Create MainThread Failed\n");
|
|
}
|
|
}
|
|
|
|
SYS_RUN(HelloTestMain);
|