CapacitiveSensor icon indicating copy to clipboard operation
CapacitiveSensor copied to clipboard

Removed Floating point math

Open ShuzzDE opened this issue 7 years ago • 4 comments

I modified the portions of the code using float math. Rewriting it to use (unsigned) longs instead makes the resulting binary around 500 Bytes smaller. While this may not seem much on most Arduinos, it really does make a difference when compiling for things like e.g. a DigiSpark or directly for other ATtiny controllers.

Code was tested on Arduino Uno and Digispark. No problems found.

ShuzzDE avatar Jun 13 '17 10:06 ShuzzDE