michaelcheng1991 / Golf-Training-Aid-

Using sensors to create a golfer-friendly teaching device
0 stars 0 forks source link

Arduino Library #29

Open michaelcheng1991 opened 8 years ago

michaelcheng1991 commented 8 years ago

Difference between .ccp and .h

The .cpp file is the compilation unit : it's the real source code file that will be compiled (in C++).

The .h (header) files are files that will be virtually copy/pasted in the .cpp files where the #include precompiler instruction appears. Once the headers code is inserted in the .cpp code, the compilation of the .cpp can start.


The C++ build system (compiler) knows no difference, so it's all one of conventions.

The convention is that .h files are declarations, and .cpp files are definitions.

That's why .h files are #included -- we include the declarations.

michaelcheng1991 commented 8 years ago

This is a good site for nRF24 https://maniacbug.wordpress.com/2011/11/02/getting-started-rf24/

nodes are just individual units,

Problem[unsolved]: receiving end does not receive full message Try : http://shanes.net/another-nrf24l01-sketch-string-sendreceive/ this use a special character in transmitting side to indicate the beginning Solve? http://shanes.net/another-nrf24l01-sketch-string-sendreceive/ this uses bool done = false , done = radio.read(msg,1)

Problem[unsolved]: storing array with float number, it seems the float takes 4 bytes, doing so will exceed SPAM //probably not this because i am only storing 27, 27*4= 108 bytes