diff --git a/src/main.c b/src/main.c index cd8255fb..ded4d3ce 100644 --- a/src/main.c +++ b/src/main.c @@ -164,12 +164,20 @@ static bool check_dfu_mode(void) { // Invoked when device is plugged and configured void tud_mount_cb(void) { + #ifdef NEOPIXEL_INVERT_RG + indicator_set(STATE_USB_UNPLUGGED); + #else indicator_set(STATE_USB_PLUGGED); + #endif } // Invoked when device is unplugged void tud_umount_cb(void) { + #ifdef NEOPIXEL_INVERT_RG + indicator_set(STATE_USB_PLUGGED); + #else indicator_set(STATE_USB_UNPLUGGED); + #endif } //--------------------------------------------------------------------+