1 Star 0 Fork 2

Bluejeams/audio_demo

forked from AliOS Things/audio_demo 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
main.c 1.19 KB
一键复制 编辑 原始数据 按行查看 历史
skylarCai 提交于 2021-07-19 17:13 . release version:rel_3.3.0-20210715_1430
/*
* Copyright (C) 2015-2020 Alibaba Group Holding Limited
*/
/**
* @file main.c
*
* This file includes the entry code of link sdk related demo
*
*/
#include <string.h>
#include <stdio.h>
#include <aos/kernel.h>
#include "ulog/ulog.h"
#include "netmgr.h"
#include <uservice/uservice.h>
#include <uservice/eventid.h>
extern int demo_main(int argc, char *argv[]);
static int _ip_got_finished = 0;
static void entry_func(void *data)
{
demo_main(0 , NULL);
}
static void wifi_event_cb(uint32_t event_id, const void *param, void *context)
{
if (event_id != EVENT_NETMGR_DHCP_SUCCESS)
return;
if (_ip_got_finished != 0)
return;
_ip_got_finished = 1;
aos_task_new("link_dmeo", entry_func, NULL, 6 << 10);
}
int application_start(int argc, char *argv[])
{
aos_set_log_level(AOS_LL_DEBUG);
event_service_init(NULL);
netmgr_service_init(NULL);
/*enable network auto reconnect*/
netmgr_set_auto_reconnect(NULL, true);
/*enable auto save wifi config*/
netmgr_wifi_set_auto_save_ap(true);
event_subscribe(EVENT_NETMGR_DHCP_SUCCESS, wifi_event_cb, NULL);
haas_audio_init();
while (1) {
aos_msleep(1000);
};
return 0;
}
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/Bluejeams/audio_demo.git
git@gitee.com:Bluejeams/audio_demo.git
Bluejeams
audio_demo
audio_demo
master

搜索帮助

0d507c66 1850385 C8b1a773 1850385