void SetLEDs (bool led1, bool led2, bool led3, bool led4); // ------------------------------------------------------------------------------------ void wiimote::SetLEDs (bool led1, bool led2, bool led3, bool led4) { _ASSERT(IsConnected()); if(!IsConnected()) return; BYTE led_bits; led_bits = (led1 ? 0x8 : 0x0) | (led2 ? 0x4 : 0x0) | (led3 ? 0x2 : 0x0) | (led4 ? 0x1 : 0x0); _ASSERT(led_bits <= 0x0f); led_bits &= 0xf; BYTE buff [REPORT_LENGTH] = {0}; buff[0] = OUT_LEDs; buff[1] = (led_bits<<4) | GetRumbleBit(); WriteReport(buff); Internal.LED.Bits = led_bits; } TRIG_L = 0x0002, PLUS = 0x0004, HOME = 0x0008, MINUS = 0x0010, TRIG_R = 0x0020, DOWN = 0x0040, RIGHT = 0x0080, UP = 0x0100, LEFT = 0x0200, _ZR = 0x0400, _X = 0x0800, _A = 0x1000, _Y = 0x2000, _B = 0x4000, _ZL = 0x8000,