I’m working on porting Arduino library used for LoraWan module from NiceRF (lora1276)
I did the work based on the empty library and looking at other Arduino libraries, you can find it on this repo
what I know is the library build without errors. this is the last few lines of the output
AR /data/fwbuild-volumes/2.14.0/apps/Lora1276/esp32/build_contexts/build_ctx_817468552/build/objs/moslib/libmoslib.a
make[1]: Leaving directory '/data/fwbuild-volumes/2.14.0/apps/Lora1276/esp32/build_contexts/build_ctx_817468552/build/objs/moslib'
make: Leaving directory '/app'
Lib saved to build/lib.a
what I tried to do next is just include the link for my library in another application mos.yml file
libs:
# Base System Libarary
#Arduino Lib
- origin: https://github.com/mongoose-os-libs/arduino-compat
- origin: https://github.com/mongoose-os-libs/arduino-onewire
- origin: https://github.com/mongoose-os-libs/arduino-spi
#CCTRONIC Lib
- origin: https://github.com/lidraikh/arduino-lora1276
I did not include anything in the main.c file, when I build for esp32 I get this error:
.../esp32/build_contexts/build_ctx_828592047/build/objs/mosapp/libmosapp.a(mgos_deps_init.o):(.rodata.descrs+0x44): undefined reference to `mgos_arduino_lora1276_init'
collect2: error: ld returned 1 exit status
at this point I’m not sure what is the problem, any guidance is appreciated.
Leo