Search found 42 matches

by JSHANG
2025年 Jan 13日 10:06
Forum: TuyaOS-联网单品开发
Topic: T1模组,SDK为T1-AHL_TuyaOS-3.8.6怎么让模块进入休眠模式还有设置唤醒源
Replies: 9
Views: 1192

Re: T1模组,SDK为T1-AHL_TuyaOS-3.8.6怎么让模块进入休眠模式还有设置唤醒源

  1. 是裸模组测的吗?
  2. 其它的gpio都断开,只留vcc, gnd, 和唤醒引脚后,再观察一下功耗试试
by JSHANG
2025年 Jan 9日 13:59
Forum: TuyaOS-联网单品开发
Topic: T1-CHL_TuyaOS-3.8.31包含sys_ctrl.h文件编译提示错误
Replies: 3
Views: 370

Re: T1-CHL_TuyaOS-3.8.31包含sys_ctrl.h文件编译提示错误

不要在你的应用代码直接调用底层的函数,这样会有头文件引用问题。 获取唤醒源,我们有在适配层有封装,tkl_wakeup.c里面接口tkl_wakeup_source_type_get: /** @brief wake up source get * @param[out] param: wake up source get, * @return OPRT_OK on success. Others on error, please refer to tuya_error_code.h */ OPERATE_RET tkl_wakeup_source_type_get(TUYA_WAKEUP_S...
by JSHANG
2024年 Nov 28日 15:02
Forum: TuyaOS-联网单品开发
Topic: T1模组,SDK为T1-AHL_TuyaOS-3.8.6怎么让模块进入休眠模式还有设置唤醒源
Replies: 9
Views: 1192

Re: T1模组,SDK为T1-AHL_TuyaOS-3.8.6怎么让模块进入休眠模式还有设置唤醒源

ps_cfg.gpio_edge_map |= (1 << gpio_num); /* 下降沿唤醒对应位置1, 默认上升沿唤醒不用设置 */

by JSHANG
2024年 Nov 28日 13:36
Forum: TuyaOS-联网单品开发
Topic: T1模组,SDK为T1-AHL_TuyaOS-3.8.6怎么让模块进入休眠模式还有设置唤醒源
Replies: 9
Views: 1192

Re: T1模组,SDK为T1-AHL_TuyaOS-3.8.6怎么让模块进入休眠模式还有设置唤醒源

设置多个唤醒参考如下: OPERATE_RET tkl_wakeup_source_set_x(void) { PS_DEEP_CTRL_PARAM ps_cfg; memset(&ps_cfg, 0, sizeof(ps_cfg)); /* Set wakeup by timer */ ps_cfg.wake_up_way |= PS_DEEP_WAKEUP_RTC; ps_cfg.lpo_32k_src = LPO_SELECT_ROSC; ps_cfg.sleep_time = 60000; /* 设置休眠时间 */ /* Set wakeup by gpio */ ps_cfg...
by JSHANG
2024年 Nov 27日 16:59
Forum: TuyaOS-联网单品开发
Topic: T1模组,SDK为T1-AHL_TuyaOS-3.8.6怎么让模块进入休眠模式还有设置唤醒源
Replies: 9
Views: 1192

Re: T1模组,SDK为T1-AHL_TuyaOS-3.8.6怎么让模块进入休眠模式还有设置唤醒源

当前版本不支持同时设置多个唤醒源;唤醒后,可以通过tkl_wakeup_source_get获取被那个gpio唤醒的

by JSHANG
2024年 Nov 26日 11:56
Forum: TuyaOS-联网单品开发
Topic: T1模组,SDK为T1-AHL_TuyaOS-3.8.6怎么让模块进入休眠模式还有设置唤醒源
Replies: 9
Views: 1192

Re: T1模组,SDK为T1-AHL_TuyaOS-3.8.6怎么让模块进入休眠模式还有设置唤醒源

T1模组设置休眠的接口实现参考如下文件: tuyaos/tuyaos_adapter/include/wakeup/include/tkl_wakeup.h tuyaos/tuyaos_adapter/src/driver/tkl_wakeup.c 支持GPIO和Timer唤醒: TUYA_WAKEUP_SOURCE_BASE_CFG_T cfg; cfg.source = BIT(TUYA_WAKEUP_SOURCE_GPIO); cfg.wakeup_para.gpio_param.gpio_num = TUYA_GPIO_NUM_0; cfg.wakeup_param.gpio_para...
by JSHANG
2024年 Nov 8日 14:11
Forum: TuyaOS
Topic: ESP32C3
Replies: 4
Views: 931

Re: ESP32C3

  1. Which module of C3 used for you?
  2. Could you show me the compile and startup message?
  3. Please try to program attachment bin file "tuyaos_demo_quickstart_QIO_1.0.1.bin", check is it can work or not.
by JSHANG
2024年 Nov 7日 20:52
Forum: TuyaOS
Topic: ESP32C3
Replies: 4
Views: 931

Re: ESP32C3

Hi Hashim, It looks like the partition table incorrect, the partition table of Tuya's as follows(vendor\esp32\tuyaos\partitions.csv): Name, Type, SubType, Offset, Size nvs, data, nvs, 0x9000, 0x4000 otadata, data, ota, 0xd000, 0x2000 phy_init, data, phy, 0xf000, 0x1000 ota_0,0, ota_0, 0x10000, 0x180...
by JSHANG
2024年 Sep 29日 19:46
Forum: TuyaOS-工具讨论
Topic: ESP32C3 编译找不到python环境
Replies: 9
Views: 4417

Re: ESP32C3 编译找不到python环境

确认你是4M flash的话,image_gen.py里面# OFFSET_END = 0x3dffff 这个打开,
OFFSET_END = 0x190000 这个注掉