So my project was getting a bit too big to manage and I want to start breaking it out into separate .cpp files. I create a .ccp file for a function and that works fine. My question though is I still have a function in the .ico that gets called from a function in my external .cpp file. How do i link it?
You create a header file with the function prototypes you need (function declarations). The location of the implementation (function definition) doesn't matter, as long as it's available to the linker.
Am i better off creating a .h file all the main.ino functions that will be called externally like you would in ANSI C and include it in both the main.ino and otherstuff.h?
IE: a main.h
#ifndef MAIN_H
#define MAIN_H
int functionb();
#endif