Can't figure out problems with code, Multiple definitions and Exit Code 2

I’ve been working on a GUI code for my robot and I finally decided to merge it with my drive code.
I decided to kill 2 birds with 1 stone and organize things into separate .ccp/.h files to make it easier to look at.

My problem is that I keep getting tons of “first defined here” and “multiple definition of ‘xxxx’” for a lot of the things in my code. I am also getting “make process closed with exit code : 2”

I have been searching for a solution for about an hour and a half, and I can’t figure it out.

Code Project File

Any help would be much appreciated, Thanks!

Could you post screenshots of your code and the error message? It would be a lot easier to debug if we can see it without downloading.

I’m going to have to split it up into a few posts, I made an account to ask this question so I can only post 1 picture at a time.

image

image

Here
v5code-project-9457Z_Program_v0.1.0_rev1.zip (56.3 KB)
This builds.

Don’t use header guards in .cpp files.
Don’t recursively include headers.
Take a look at the changes I made, I have no idea if the code runs, but at least it builds.

“make process closed with exit code : 2" just means you had other errors and the build system could not complete the build.

4 Likes

Thank you,
The code downloads and runs on my robot, It seems to be fixed and the GUI functions as well as It did before, I just need to tweak things so the drive code will run.

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.