#include #include #include #include #include #include #include "log.h" #include "sys.h" #include "paras.h" #include "cfg.h" #include "fs.h" #include "thread.h" //////////////////////////////////////////////////////////////////// int sys_reboot(void) { int r=0; r = system("reboot"); if(r) { LOGE("sys_reboot failed!\n"); return -1; } return r; } int sys_get_chip_id(int *id) { if(!id) { return -1; } return 0; } static void* poll_thread(void *arg) { thread_handle_t *h=(thread_handle_t*)arg; //wdog_init(); //tmp_create(); while(h->quit==0) { sleep(1); } pthread_exit(NULL); } int sys_init(void) { paras_init(); //thread_start(THREAD_ID_POLL, poll_thread, NULL); return 0; }