改名,接线,danger
This commit is contained in:
parent
f725154a45
commit
66d8e6fdbb
@ -1,3 +1,9 @@
|
||||
### 接线
|
||||
语音助手
|
||||
TX:PD8
|
||||
RX:PD9
|
||||
|
||||
|
||||
# 红外遥控贪吃蛇/显示+上传温度等数据
|
||||
|
||||

|
||||
|
@ -94,6 +94,12 @@ static void serial_thread_entry(void *parameter)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
void serial_send(char *str)
|
||||
{
|
||||
rt_device_write(serial, 0, str, (sizeof(str) - 1));
|
||||
}
|
||||
|
||||
int aiv_init(void)
|
||||
{
|
||||
LOG5("VOICE assistant START");
|
1
applications/assistant.h
Normal file
1
applications/assistant.h
Normal file
@ -0,0 +1 @@
|
||||
void serial_send(char *str);
|
32
applications/status.c
Normal file
32
applications/status.c
Normal file
@ -0,0 +1,32 @@
|
||||
|
||||
#include <rtthread.h>
|
||||
#include <rtdevice.h>
|
||||
#include <drv_gpio.h>
|
||||
#include <assistant.h>
|
||||
#include <sim.h>
|
||||
|
||||
|
||||
#define THREAD_PRIORITY 25
|
||||
#define THREAD_STACK_SIZE 4096
|
||||
#define THREAD_TIMESLICE 5
|
||||
|
||||
#define LOG_TAG "status"
|
||||
#define DBG_LVL DBG_LOG
|
||||
// #define DBG_LVL DBG_INFO
|
||||
|
||||
#define USE_LOG1
|
||||
#define USE_LOG2
|
||||
#define USE_LOG3
|
||||
// #define USE_LOG4
|
||||
#define USE_LOG5
|
||||
// #define USE_LOG6
|
||||
// #define USE_LOG_D
|
||||
#include "logn.h"
|
||||
|
||||
void danger_status(void)
|
||||
{
|
||||
char *str = "aa";
|
||||
serial_send(str);
|
||||
sim_call("17318112360");
|
||||
}
|
||||
MSH_CMD_EXPORT_ALIAS(danger_status, danger, show danger_status);
|
Loading…
x
Reference in New Issue
Block a user