Hi there,
So im trying to configurate the VL53l0x API, there were multiple errors but i found a tutorial and it helped me so far with getting rid of them. But I'm stuck, I've done everything and I have one final error "fatal error: vl53l0x_api.c: No such file or directory". I have no idea how to solve it, i've added every possible source to the IDE and yet it doesnt work.
Have anyone had this kind of issue before?
I can see /.../Drivers and /.../Debug/Drivers/Api/Core/src mentioned but not /.../Drivers/Api/Core/src where the file is residing. My crystal ball is on maintenance, can't say what your IDE is and how to configure it properly.
I've tried it already, maybe im doing something wrong...
You are including this file. Do you have the path among the included directories?
Edit No, you don't.
Are You asking for this one? I'm sorry im kinda new to this.
Yes. You are using #include directive, so the file should be listed among include directories.
In the 1s.png screenshot you can see compiler commands, there are include options of the form -I../Core/Inc and so on. These are include directories, and you are missing the one which contains your file.
I think i've got it, but um... compiler now warns about 260 errors. It says that the functions are used multiple times, don't really get it, it's and api from the producer of the sensors.
Not sure if the screenshot can be read, it says "Users/mikol/STM32CubeIDE/workspace_1.14.1/uubibiujb/Debug/../Drivers/Api/core/src/vl53l0x_api_strings.c:383: multiple definition of `VL53L0X_get_sequence_steps_info'; ./Api_src/vl53l0x_api_strings.o:C:/Users/mikol/STM32CubeIDE/workspace_1.14.1/uubibiujb/Drivers/Api/core/src/vl53l0x_api_strings.c:383: first defined here" like 260 times. ;/
Why do you #include this file into main.c? I guess you should add it to the project source files, so that it will be compiled separately.
There is probably a file named vl53l0x_api.h which you are supposed to include?
So i've changed the "#include "vl53l0x_api.c" to "#include "vl53l0x_api.h" as you said and it gives 0 errors! Seems like it's finally working. I dont know why it was "#include "vl53l0x_api.c" in the first place, the guide said that it should be...
Thanks a lot man, you are the best!