我试图修改SDK中的UART示例,以便我能够每200 msc接收日期。这是我所做的:
#include <#include "arch_system.h" #include " user_user_setup .h" #include "uart_common.h" #include "uart_utils.h" #include "gpio.h" #include "app_easy_timer.h" #include "app_easy_timer.h" #include "rwip_config.h" #include "gap.h" static void receive_timer_cb();timer_hnd receive_timer_used;Int main(void) {system_init();//设置UART2引脚和配置uart_peripher_init (UART2);//执行UART2 receive blocking example receive_timer_used = app_easy_timer(200,receive_timer_cb); printf_string(UART2, "\n\n\n\r* UART examples finished successfully *\n\r"); } static void receive_timer_cb() { uart_receive_blocking_example(UART2); receive_timer_used = app_easy_timer(200, receive_timer_cb); }
However, when I try to compile this piece of code, I get the following error:
.\..\..\..\..\..\sdk\platform\core_modules\rwip\api\rwip_config.h(464): error: #20: identifier "BLE_NB_PROFILES" is undefined TASK_PRF_MAX = (TASK_RFU_5 + BLE_NB_PROFILES), ..\src\main.c(40): warning: #1295-D: Deprecated declaration receive_timer_cb - give arg types static void receive_timer_cb();
Other examples in the SDK use the same method to define and use a timer, but there is not such a problem while compiling. That being said, would you please give me some instructions about this error and how to remove it?
Kind regards,
Niek