Tuesday, 15 January 2013

arduino - Best way to make a project with multiple files -



arduino - Best way to make a project with multiple files -

i developing arduino based scheme enlarge on time. @ moment has humidity , temperature read functionality. door control, sound recording , gsm web client back upwards added. want these included libraries , used in main part. i'm thinking of 1 ino file includes other modules , calls functions. question best , clean way it?

i recommend sticking libraries , library directories examples. library each component interfaced with. help in many ways. such debugging , reuse.

c:\users\myself\google drive\arduino\libraries\componentx\componentx.h c:\users\myself\google drive\arduino\libraries\componentx\componentx.cpp c:\users\myself\google drive\arduino\libraries\componenty\componenty.h c:\users\myself\google drive\arduino\libraries\componenty\componenty.cpp etc...

this keeps modular , compartmentalized.

notice have changed arduino's ide preferences google drive. (cloud backup , portability)

then rather 1 big ino file in sketch folder

c:\users\myself\google drive\arduino\somethingbig\somethingbig.ino

implement ino files in

c:\users\mflaga\google drive\arduino\libraries\component\examples.

directories. makes quick publish components on github or google drive share between systems.

then can have sketch file ties components main project.

c:\users\myself\google drive\arduino\somethingtoplevel\somethingtoplevel.ino

arduino arduino-ide

No comments:

Post a Comment