Search wiring.org.co:

Reference for Wiring version 1.0 Build 0100+ If you have a previous version, use the reference included with your software. If see any errors or have any comments, let us know.

Name |

### bitWrite()

Examples |
    // sets x to 33 (00100001 in binary)
    byte x = 33;
    // writes a 1 to the second bit bit of x, now x is 00100101 (37 in decimal)
    bitWrite(x, 2, 1);
Description | The bitWrite command writes 0 or 1 to de desired bit of a byte variable.
Syntax |
    bitWrite(byteValue, bitIndex, bitValue)
Parameters |

byteValue | byte: the byte variable to write the bit to
bitIndex | int: the bit to write
bitValue | int: the value to write 0 or 1

Returns | None
Usage | Application
Related | bit() bitRead() lowByte() highByte() makeWord()

Updated on July 07, 2011 11:07:55pm PDT