Hello,
I was trying to run TFLM custom code on Thingy:53 device and while building I have faced these warnings.
1. Could you please help me to understand Why I am facing these warning?
2. How can I Remove solve these problems?
Regards,
Divya
Hello,
I was trying to run TFLM custom code on Thingy:53 device and while building I have faced these warnings.
1. Could you please help me to understand Why I am facing these warning?
2. How can I Remove solve these problems?
Regards,
Divya
Hi Divya,
1. This is telling you that asserts are enabled. If you look through the code files in nRF Connect SDK you will find __ASSERT is used several places. This is used to give a runtime error based on a check. You can read more about this here: Software Errors Triggered in Source Code.
2. You can disable asserts by setting the following in prj.conf: CONFIG_ASSERT=n
Best regards,
Marte
Hi Divya,
1. This is telling you that asserts are enabled. If you look through the code files in nRF Connect SDK you will find __ASSERT is used several places. This is used to give a runtime error based on a check. You can read more about this here: Software Errors Triggered in Source Code.
2. You can disable asserts by setting the following in prj.conf: CONFIG_ASSERT=n
Best regards,
Marte
Hello Marte,
Thank you so much for the response. I hope you have noticed that I have updated the question with more warnings while building the code. Could you please help me to solve those issues too!!
Hi Divya,
As you can see in the warning text, you are trying to set configurations related to logging (CONFIG_LOG_DEFAULT_LEVEL and CONFIG_LOG_MODE_MINIMAL) while logging is disabled:
Check these unsatisfied dependencies: (LOG || LOG) (=n)
If you go to the links referenced in the warnings you can also see that the configurations depend on CONFIG_LOG being set, see for example CONFIG_LOG_DEFAULT_LEVEL.
If you want to use logging you must set CONFIG_LOG=y in prj.conf. If you do not want to use logging then you can remove these two configurations instead.
Best regards,
Marte
Thanks Marte for your message.
I need to ask that I have added some header files and source file in section of "src" my custom project but when I opened the project in VSC I can not find those files.
I can only see those files in Explorer section. Do you know how can I see my all files?
Regards,
Divya
Hi Divya,
You need to add the files to the project. For the header files you add the directory the files are in with zephyr_library_include_directories, and for the source files you add the files themselves to target_sources, for example:
target_sources(app PRIVATE src/main.c src/<custom_file> ) zephyr_library_include_directories(src)
Where you change <custom_file> to the filename of your source file.
After you do a pristine build after adding this you should see the files in the nRF Connect extension in VS Code.
Best regards,
Marte
Thanks for the quick reply.
Actually I want to add a.cc file in the src folder and then want to call inside the main.c file.
But it is showing an error that : No Sorce given to the target: app cmake in line 418. So, what should I do to include a .cc file inside main.c file.
Does calling a C++ file inside a C is really support by Thingy?
If not then is there any possibilty to build and Flash Thingy with a C++ file like main.cc in place of main.c?
Regards,
Divya