Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

LMIC-node project adding MCCI LoRaWAN LMIC library@^4.0.0 #15

Closed
mitjad123 opened this issue Jul 16, 2021 · 5 comments
Closed

LMIC-node project adding MCCI LoRaWAN LMIC library@^4.0.0 #15

mitjad123 opened this issue Jul 16, 2021 · 5 comments
Labels
question Further information is requested

Comments

@mitjad123
Copy link

Hi,

I am setting LMIC-node project on my win10 platformIO project targeting heltec wireless stick lite
I tried to add mcci-catena/MCCI LoRaWAN LMIC library@^4.0.0 library and got this error:

PIO Core Call Error: "Error: Invalid 'D:\userX\Documents\PlatformIO\Projects\HelctecWiFiLORAone4all\platformio.ini' (project configuration file): 'No section: 'common''"

My platforio.ini:
; PlatformIO Project Configuration File
;
; Build options: build flags, source filter
; Upload options: custom upload port, speed and extra flags
; Library options: dependencies, extra library storages
; Advanced options: extra scripting
;
; Please visit documentation for the other options and examples
; https://docs.platformio.org/page/projectconf.html

[env:heltec_wireless_stick_lite]
; Heltec Wireless Stick Lite (ESP32).
; No display.
platform = espressif32
board = heltec_wireless_stick_lite
framework = arduino
upload_speed = 921600
monitor_speed = ${common.monitor_speed}
lib_deps =
${common.lib_deps}
${mcci_lmic.lib_deps}
build_flags =
${common.build_flags}
${mcci_lmic.build_flags}
-D BSFILE="boards/bsf_heltec_wireless_stick_lite.h"
-D MONITOR_SPEED=${common.monitor_speed}
-D LMIC_PRINTF_TO=Serial
-D USE_SERIAL
-D USE_LED
; -D USE_DISPLAY ; Requires external I2C OLED display

@mitjad123
Copy link
Author

mitjad123 commented Jul 16, 2021

Aha, it looks like I would have to add MCCI lib before and changed platforio.ini

lib_deps =
mcci-catena/MCCI LoRaWAN LMIC library@^4.0.0

@lnlp
Copy link
Owner

lnlp commented Jul 16, 2021

Apparently you have edited the platformio.ini file included with LMIC-node and have removed essential parts e.g. the [common] and other sections. There is no need to remove anything from platformio.ini. Use the original platformio.ini and the problem should be solved.

Before making any changes first read the included documentation.

If you wan't to slim down platformio.ini for just your board, be careful with what you change or remove and only do this if you understand the consequences.

@lnlp lnlp closed this as completed Jul 16, 2021
@lnlp lnlp added the question Further information is requested label Jul 16, 2021
@lnlp lnlp reopened this Jul 19, 2021
@mitjad123
Copy link
Author

Hi, sorry for being negligent.
You were right. After using the original ini file, it almost worked.
I only had to change:
-D BSFILE="boards/bsf_heltec_wireless_stick_lite.h"
To:
-D BSFILE="../boards/bsf_heltec_wireless_stick_lite.h"

Because otherwise I had an error:
In file included from src\LMIC-node.cpp:53:0:
src\LMIC-node.h:79:46: fatal error: boards/bsf_heltec_wireless_stick_lite.h: No such file or directory
compilation terminated.
*** [.pio\build\heltec_wireless_stick_lite\src\LMIC-node.cpp.o] Error 1
================================================================================== [FAILED] Took 2.84 seconds =============================================================================

Thanks
Best regards

Mitja

@lnlp
Copy link
Owner

lnlp commented Jul 20, 2021

Thanks for your feedback.

Regarding:

I only had to change:
-D BSFILE="boards/bsf_heltec_wireless_stick_lite.h"
To:
-D BSFILE="../boards/bsf_heltec_wireless_stick_lite.h"

That is strange because boards is a subfolder of src, they are not siblings (which the ../ implies).
Maybe you changed something to the folder structure?

@mitjad123
Copy link
Author

Yes, I did (as well as some other stupid things). But it is OK now.
Thanks
Mtija

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants