Update LedDeviceTpm2.cpp

Former-commit-id: 8d51eb00044460002e29687468786e3056afd0bb
This commit is contained in:
Gamadril 2014-06-18 13:49:27 +02:00
parent 1d046ab35a
commit 3135b89255

View File

@ -25,8 +25,8 @@ int LedDeviceTpm2::write(const std::vector<ColorRgb> &ledValues)
_ledBuffer.resize(5 + 3*ledValues.size());
_ledBuffer[0] = 0xC9; // block-start byte
_ledBuffer[1] = 0xDA; // DATA frame
_ledBuffer[2] = ((3 * ledValues.size()) >> 8) & 0xFF; // LED count high byte
_ledBuffer[3] = (3 * ledValues.size()) & 0xFF; // LED count low byte
_ledBuffer[2] = ((3 * ledValues.size()) >> 8) & 0xFF; // frame size high byte
_ledBuffer[3] = (3 * ledValues.size()) & 0xFF; // frame size low byte
_ledBuffer.back() = 0x36; // block-end byte
}