src/ir_NEC.cpp
/**
 * With Send sendNECMSB() you can send your old 32 bit codes.
 * To convert one into the other, you must reverse the byte positions and then reverse all bit positions of each byte.
 * Or write it as one binary string and reverse/mirror it.
 * Example:
 * 0xCB340102 byte reverse -> 02 01 34 CB bit reverse-> 40 80 2C D3.
 * 0xCB340102 is binary 11001011001101000000000100000010.
 * 0x40802CD3 is binary 01000000100000000010110011010011.
 * If you read the first binary sequence backwards (right to left), you get the second sequence.
 */
With Send sendNECMSB() you can send your old 32 bit codes.
To convert one into the other, you must reverse the byte positions and then reverse all bit positions of each byte.
Or write it as one binary string and reverse/mirror it.
With Send sendNECMSB () you can send your old 32 bit codes . To convert one into the other you must reverse the byte positions and then reverse all bit positions of each byte . Or write it as one binary string and reverse / mirror it .
void IRsend::sendNECMSB(uint32_t data, uint8_t nbits, bool repeat) {
    enableIROut(NEC_KHZ);
    if (data == 0xFFFFFFFF || repeat) {
        sendNECRepeat();
        return;
    }
    mark(NEC_HEADER_MARK);
    space(NEC_HEADER_SPACE);
    sendPulseDistanceWidthData(NEC_BIT_MARK, NEC_ONE_SPACE, NEC_BIT_MARK, NEC_ZERO_SPACE, data, nbits, PROTOCOL_IS_MSB_FIRST,
    SEND_STOP_BIT);
}
void IRsend :: sendNECMSB ( uint32_t data , uint8_t nbits , bool repeat ) { enableIROut ( NEC_KHZ ) ; if ( data == 0xFFFFFFFF || repeat ) { sendNECRepeat ( ) ; return ; } mark ( NEC_HEADER_MARK ) ; space ( NEC_HEADER_SPACE ) ; sendPulseDistanceWidthData ( NEC_BIT_MARK , NEC_ONE_SPACE , NEC_BIT_MARK , NEC_ZERO_SPACE , data , nbits , PROTOCOL_IS_MSB_FIRST , SEND_STOP_BIT ) ; }
With Send sendNECMSB() you can send your old 32 bit codes.
With Send sendNECMSB () you can send your old 32 bit codes .
// Set IR carrier frequency
 // Header
 // Old version with MSB first Data + stop bit
