完成了实验。
This commit is contained in:
parent
0ca7b81dee
commit
8d82fbc9ca
|
@ -72,6 +72,44 @@ menu "test app"
|
||||||
endif
|
endif
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
menuconfig USER_TEST_LORASEND
|
||||||
|
select BSP_USING_UART
|
||||||
|
select BSP_USING_GPIO
|
||||||
|
select RESOURCES_PIN
|
||||||
|
select BSP_USING_UART2
|
||||||
|
select BSP_USING_LORA
|
||||||
|
bool "Config test uart(loraE220_send)"
|
||||||
|
default n
|
||||||
|
if USER_TEST_LORASEND
|
||||||
|
if ADD_XIZI_FEATURES
|
||||||
|
config LORA_UART_DEV_DRIVER
|
||||||
|
string "Set uart dev path"
|
||||||
|
default "/dev/uart2_dev2"
|
||||||
|
config LORA_PIN_DEV_DRIVER
|
||||||
|
string "Set pin dev path"
|
||||||
|
default "/dev/pin_dev"
|
||||||
|
endif
|
||||||
|
endif
|
||||||
|
|
||||||
|
menuconfig USER_TEST_LORARECEIVE
|
||||||
|
select BSP_USING_UART
|
||||||
|
select BSP_USING_GPIO
|
||||||
|
select RESOURCES_PIN
|
||||||
|
select BSP_USING_UART2
|
||||||
|
select BSP_USING_LORA
|
||||||
|
bool "Config test uart(loraE220_receive)"
|
||||||
|
default n
|
||||||
|
if USER_TEST_LORARECEIVE
|
||||||
|
if ADD_XIZI_FEATURES
|
||||||
|
config LORA_UART_DEV_DRIVER
|
||||||
|
string "Set uart dev path"
|
||||||
|
default "/dev/uart2_dev2"
|
||||||
|
config LORA_PIN_DEV_DRIVER
|
||||||
|
string "Set pin dev path"
|
||||||
|
default "/dev/pin_dev"
|
||||||
|
endif
|
||||||
|
endif
|
||||||
|
|
||||||
menuconfig USER_TEST_SOCKET
|
menuconfig USER_TEST_SOCKET
|
||||||
select BSP_USING_LWIP
|
select BSP_USING_LWIP
|
||||||
bool "Config test socket(lwip)"
|
bool "Config test socket(lwip)"
|
||||||
|
|
|
@ -109,6 +109,14 @@ ifeq ($(CONFIG_ADD_XIZI_FEATURES),y)
|
||||||
SRC_FILES += test_hash/test_hash.c
|
SRC_FILES += test_hash/test_hash.c
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
ifeq ($(CONFIG_USER_TEST_LORASEND),y)
|
||||||
|
SRC_FILES += test_lora_send.c
|
||||||
|
endif
|
||||||
|
|
||||||
|
ifeq ($(CONFIG_USER_TEST_LORARECEIVE),y)
|
||||||
|
SRC_FILES += test_lora_receive.c
|
||||||
|
endif
|
||||||
|
|
||||||
ifeq ($(CONFIG_USER_TEST_RADIX),y)
|
ifeq ($(CONFIG_USER_TEST_RADIX),y)
|
||||||
SRC_FILES += test_radix_tree/test_radix_tree.c
|
SRC_FILES += test_radix_tree/test_radix_tree.c
|
||||||
endif
|
endif
|
||||||
|
@ -137,10 +145,6 @@ ifeq ($(CONFIG_ADD_XIZI_FEATURES),y)
|
||||||
SRC_FILES +=
|
SRC_FILES +=
|
||||||
endif
|
endif
|
||||||
|
|
||||||
ifeq ($(CONFIG_USER_TEST_LORA_P2P),y)
|
|
||||||
SRC_FILES +=
|
|
||||||
endif
|
|
||||||
|
|
||||||
ifeq ($(CONFIG_USER_TEST_LORAWAN_SINGLEGW),y)
|
ifeq ($(CONFIG_USER_TEST_LORAWAN_SINGLEGW),y)
|
||||||
SRC_FILES +=
|
SRC_FILES +=
|
||||||
endif
|
endif
|
||||||
|
|
|
@ -12,18 +12,21 @@
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
// #include <user_api.h>
|
//#include <user_api.h>
|
||||||
#include <transform.h>
|
#include <transform.h>
|
||||||
|
|
||||||
|
extern void LoraSend();
|
||||||
extern int FrameworkInit();
|
extern int FrameworkInit();
|
||||||
extern void ApplicationOtaTaskInit(void);
|
extern void ApplicationOtaTaskInit(void);
|
||||||
int main(void)
|
int main(void)
|
||||||
{
|
{
|
||||||
printf("Hello, world!");
|
printf("running!");
|
||||||
FrameworkInit();
|
FrameworkInit();
|
||||||
|
LoraSend();
|
||||||
#ifdef APPLICATION_OTA
|
#ifdef APPLICATION_OTA
|
||||||
ApplicationOtaTaskInit();
|
ApplicationOtaTaskInit();
|
||||||
#endif
|
#endif
|
||||||
|
printf("+strat ok");
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
// int cppmain(void);
|
// int cppmain(void);
|
||||||
|
|
Loading…
Reference in New Issue