From 98be5af55812b1a7431da32a587dcd1a4b6dce30 Mon Sep 17 00:00:00 2001 From: Nick Chan Date: Tue, 24 Jan 2023 02:09:05 +0800 Subject: [PATCH] better pongoOS logging --- src/pongo_usb.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/pongo_usb.c b/src/pongo_usb.c index 11e2941..77e8e8f 100644 --- a/src/pongo_usb.c +++ b/src/pongo_usb.c @@ -338,7 +338,11 @@ int issue_pongo_command(usb_device_handle_t handle, char *command) LOG(LOG_ERROR, "Pongo command %s too long (max %d)", command, CMD_LEN_MAX - 2); return EINVAL; } - LOG(LOG_VERBOSE, "Executing PongoOS command: '%s'", command); + if (verbose < 3 || verbose > 4) { + LOG(LOG_VERBOSE, "Executing PongoOS command: '%s'", command); + } else { + printf("%s\n", command); + } snprintf(command_buf, 512, "%s\n", command); len = strlen(command_buf); ret = USBControlTransfer(handle, 0x21, 4, 1, 0, 0, NULL, NULL);