
*rOut |= rBit // set receive pin HIGH - turns on pullup set receive pin HIGH briefly to charge up fully

While ( !(*rIn & rBit) & (total CS_Timeout_Millis) *rReg |= rBit // set pin to OUTPUT - pin is now LOW AND OUTPUT *rOut &= ~rBit // set receivePin Register low to make sure pullups are off *rReg &= ~rBit // set receivePin to input *sOut &= ~sBit // set Send Pin Register low The CapacitiveSensor library takes care of everything so that we don’t have to write code like this: language:c We can write the code from scratch, or we can stand on the shoulders of great people who are smarter than we are.Ĭapacitive touch sensing is a very popular interface.


For example, capacitive sensing takes difficult timing and pulsing of digital pins. Arduino users have written lots of exciting add-ons for Arduino. Arduino libraries take a complex task and boil it down to simple to use functions.
