diff --git a/Ubiquitous/RT-Thread_Fusion_XiUOS/app_match_rt-thread/sx1278/Kconfig b/Ubiquitous/RT-Thread_Fusion_XiUOS/app_match_rt-thread/sx1278/Kconfig new file mode 100644 index 000000000..adbeee018 --- /dev/null +++ b/Ubiquitous/RT-Thread_Fusion_XiUOS/app_match_rt-thread/sx1278/Kconfig @@ -0,0 +1,38 @@ + +menuconfig DRV_USING_SX1278 + bool "sx1278 driver" + default n + help + note: + lora connection + +if DRV_USING_SX1278 + config SX1278_SPI_DEVICE_NAME + string "SX1278 Lora Device Spi Name" + default "spi20" + config SX1278_DEVICE_NAME + string "SX1278 Lora Device Name" + default "spi2_lora" + config SX1278_DEVICE_RST_PIN + int + default 1 + config SX1278_DEVICE_DIO0_PIN + int + default 1 + config SX1278_DEVICE_DIO1_PIN + int + default 1 + config SX1278_DEVICE_DIO2_PIN + int + default 1 + config SX1278_DEVICE_DIO3_PIN + int + default 1 + config SX1278_DEVICE_DIO4_PIN + int + default 1 + config SX1278_DEVICE_DIO5_PIN + int + default 1 +endif + diff --git a/Ubiquitous/RT-Thread_Fusion_XiUOS/app_match_rt-thread/sx1278/SConscript b/Ubiquitous/RT-Thread_Fusion_XiUOS/app_match_rt-thread/sx1278/SConscript new file mode 100644 index 000000000..439998036 --- /dev/null +++ b/Ubiquitous/RT-Thread_Fusion_XiUOS/app_match_rt-thread/sx1278/SConscript @@ -0,0 +1,7 @@ +Import('RTT_ROOT') +from building import * + +cwd = GetCurrentDir() +objs = SConscript(os.path.join(cwd, 'sx1278_source', 'SConscript')) + +Return('objs') diff --git a/Ubiquitous/RT-Thread_Fusion_XiUOS/app_match_rt-thread/sx1278/sx1278_source/SConscript b/Ubiquitous/RT-Thread_Fusion_XiUOS/app_match_rt-thread/sx1278/sx1278_source/SConscript new file mode 100644 index 000000000..614ddae45 --- /dev/null +++ b/Ubiquitous/RT-Thread_Fusion_XiUOS/app_match_rt-thread/sx1278/sx1278_source/SConscript @@ -0,0 +1,19 @@ +import os +from building import * +Import('RTT_ROOT') +Import('rtconfig') +cwd = GetCurrentDir() +DEPENDS = ["DRV_USING_SX1278"] + +SOURCES = [] +if GetDepend(['DRV_USING_SX1278']): + SOURCES += ['drv_sx1278.c'] + SOURCES += Glob('src/radio/sx1276*.c') + SOURCES += Glob('src/radio/radio.c') + SOURCES += Glob('port/*.c') + +path = [cwd + '/inc'] +path += ['src/radio'] +objs = DefineGroup('sx1278', src = SOURCES, depend = DEPENDS,CPPPATH = path) + +Return("objs") \ No newline at end of file