MCPcopy Create free account
hub / github.com/RobTillaart/Arduino / bitClear64

Function bitClear64

libraries/bitHelpers/bitHelpers.cpp:523–530  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

521
522
523void bitClear64(uint64_t & x, uint8_t n)
524{
525 if (n > 47) x &= ~(0x1000000000000 << (n - 48));
526 else if (n > 31) x &= ~(0x100000000 << (n - 32));
527 else if (n > 23) x &= ~(0x1000000 << (n - 24));
528 else if (n > 15) x &= ~(0x10000 << (n - 16));
529 else x &= ~(0x1 << n);
530}
531
532
533void bitToggle64(uint64_t & x, uint8_t n)

Callers 1

bitWrite64Function · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected