Forum Replies Created
July 10, 2020 at 09:08 in reply to: Undefined reference errors when trying to build with the Instrumenting Profiler #28725
It wasn’t automatically added to the build, I did it manually (had to go to the C:\Users\user\AppData\Local\VisualGDB\EmbeddedEFPs\Profiler) directory to find the file
I did that, but now I’m getting the same errors but related to other functions, and it’s strange because they are defined in that same file
Shouldn’t the InstrumentingProfiler.cpp be added automatically in the first place when I checked the box to enable the Profiling?
Thank you for the answer!April 29, 2020 at 00:09 in reply to: What is the process for enabling features in the nrf52 SDK? #27987
I’m attaching a screenshot. So, this was converted to a stand-alone project, right?
Attachments:You must be logged in to view attached files.April 27, 2020 at 17:01 in reply to: What is the process for enabling features in the nrf52 SDK? #27964
I’m trying to add the SPI slave feature in a NRF52840 device through the visualGDB Embedded Frameworks Window, but the only framework in the list is the “Fast Semihosting and Embedded Profiler”. How can I add make the SDK features appear in this window?
Thank you, that will be very helpful!
I found the problem! I was taking a look at the Debug Settings to try to implement the workaround that you suggested and I realized that our debug setting was set for the NRF2832 (which was the device that we started in our project). But now we are using an NRF2840 (which has two times the flash size than the NRF2832). Some time ago our code wasn’t using more than 50% of the flash so we had no problems. But now we got past this threshold so we need to update the debug settings for the NRF2840.
Thank you so much!
If I disable memory verification, the error goes away but the board is not successfully programmed
This hints that there’s really a problem with the flashing. When I click the “show details” three windows appear: GDB session, Exception details, and JLinkGDBServerCL
I’m attaching here the messages in these three windows because I could not figure out what may be causing the problem. I guess its something related to the size of the binary file generated because when our codebase was smaller the programming worked well. I would like your help in trying to find out what’s causing this. I had to manually merge the 3 files into one file because I cannot attach more than one file in my post. So I added some separators for each session in the form of a header with a long sequence of “=”
The main reason why I want this to work is that this seems to be related to the fact that I cannot run the tests on the code anymore (using Google Tests). When I try to run the tests, it seems that Visual Studio flashes the device in the same way it does when I click in “Program and Start Without Debugging”. But after that, the Testing Suite just hangs and does not run the tests. I tried removing all tests and adding just a dummy test with ASSERT_EQ(true, true) and not even this test runs. So I guess the device is not being programmed correctly, that’s why the Test Suite hangs. And if I go back to an old version of our code (into which the programming with the “Program and Start Without Debugging” option works), the tests run fine.
Attachments:You must be logged in to view attached files.
Just to be clearer: when our code was smaller (elf file around 1.43 Mb) we didnt have this error
- This reply was modified 4 months, 3 weeks ago by Jose Cazarin.
Thank you that worked!
Another question: should the Makefile work out of the box in this way in Linux environments?
I have a Ubuntu VM in my computer running through the WSL. I used all of the commands in the Ubuntu environment (changing them to the respective Linux commands), but I’m getting some errors of files not being found, like:
arm-eabi-g++.exe: fatal error: no input files
arm-eabi-g++.exe: error: /path/to/my/file/my_file.cpp: No such file or directory (the path exists, that’s why this error is weird)
Does it need some kind of tweaking to get the build done on a Linux environment?
Thanks, that would help a lot. I’ll keep in touch.
Getting back to this, what we are trying to do is: we have a .txt file with the inputs of an algorithm. We want to run this algorithm in our device and check if the results are the same. The problem is: this .txt file is too big, if we try to compile it within the embedded code we run out of memory. So we are trying to find a way to, during runtime, transfer the inputs from the PC to the embedded device and still use the GoogleTest framework
We will start looking into it again and try to make the parameterized tests work. But I don’t know if that’s the solution for what we need.December 6, 2019 at 16:06 in reply to: Not compile some files based on current configuration #26767
Thank you, actually I thought about the ifdef solution a while after I posted it here, and it worked. Thank you!
Yes, I can create a test project that works out of the box.
I fixed the compilation errors by adding all the folders inside the C:\Users\user\AppData\Local\VisualGDB\EmbeddedEFPs\Profiler folder, had to tweak them a bit, add some includes, and then it compiled
Then, I saw your last post, rolled back all these changes and just enabled the profiler/semihosting and checked the box that says “this project contains unit tests” and it compiled!
Then, I created a simple test file with some dummy test cases, and it worked!
Just a quick question, is there any way to select which main function is running? Because I need to 2 mains, the one where my application really is and the one to run the tests.
I’m commenting out the real main to be able to run the tests, it’s a band-aid fix but I’m wondering if there’s a better way to do that
Thank you so much for your help so far!
I’ve upgraded to the custom edition of the VisualGDB
What’s the best approach to adding unit tests to an existing project?
What I tried: opening the VisualGDB properties of my current project and checking the box “this project contains unit tests based on” and selecting TinyEmbedded on the “Unit Tests” tab
But when I do this, my project doesn’t compile anymore, it throws an error saying that it can’t find the SysprogsProfilerInterface.h header being included by the SysprogsTestHooks.cpp file
But this file is present in the C:\Users\user\AppData\Local\VisualGDB\EmbeddedEFPs\Profiler folder
I’ve tried to add the path to it manually in the Include Directories but after this the error is
Error undefined reference to `SysprogsProfiler_WriteData’
Looks like something is still missing in the configuration
Right, now I realized that I got the Embedded version, thats why I was having problems. Thanks for you help