Hi,
I noticed a difference between programming a simple C or C++ program compared to working with a project tree for example on mplab ide.
The project consists of many source files .c, and headers.h, there is one main.c.
All the c and c++ books teach to prototype and define functions outside the main, then call the function from inside the main and pass values or references or results back and force.
Now, on this hughe os c project, written for a particular µc the main is rather small, and has a lot of precompiler #if, but the real programming is done in those source files, consisting of functions over functions. I didn
t see a single prototype of one.
When I write a new function, no parameters are being passed when I for example call same function from within another function.
Also when I declared a variable on top of a source file, assuming I would create a global variable, it is not working as one, I can
t even read it`s value from within a function on the same source file. Appreciate any help,
John
It looks like you're new here. If you want to get involved, click one of these buttons!