mu3: hotfix for calling mu3_io_led_set_colors

This commit is contained in:
Dniel97 2024-05-16 08:10:05 +02:00
parent 3bfb046afc
commit d8b3d41809
Signed by untrusted user: Dniel97
GPG Key ID: 6180B3C768FB2E08
3 changed files with 7 additions and 4 deletions

View File

@ -170,7 +170,7 @@ HRESULT chuni_dll_init(const struct chuni_dll_config *cfg, HINSTANCE self)
"\"%s\". Please contact your IO DLL's developer for "
"further assistance.\n",
sym->sym);
dprintf("imported %d symbols\n",bind_count);
dprintf("imported %d symbols\n", bind_count);
goto end;
}
} else {

View File

@ -166,7 +166,7 @@ static HRESULT mu3_io4_write_gpio(uint8_t* payload, size_t len)
lights_data & MU3_IO_LED_R3_B ? 0xFF : 0x00,
};
mu3_io_led_set_colors(1, rgb_out);
mu3_dll.led_set_leds(1, rgb_out);
return S_OK;
}

View File

@ -117,7 +117,6 @@ void mu3_io_get_gamebtns(uint8_t *left, uint8_t *right);
void mu3_io_get_lever(int16_t *pos);
/* Initialize LED emulation. This function will be called before any
other mu3_io_led_*() function calls.
@ -148,7 +147,11 @@ HRESULT mu3_io_led_init(void);
Board 1 has 6 LEDs:
[0]-[5]: 3 left and 3 right controller buttons
Each rgb value is comprised of 3 bytes in R,G,B order
Each rgb value is comprised of 3 bytes in R,G,B order. The tricky part is
that the board 0 is called from mu3 and the board 1 is called from amdaemon.
So the library must be able to handle both calls, using shared memory f.e.
This is up to the developer to decide how to handle this, recommended way is
to use the amdaemon process as the main one and the mu3 call as a sub one.
Minimum API version: 0x0101 */