core/embed: Set VCP write timeout to 0.

pull/1096/head
Andrew Kozlik 4 years ago committed by Andrew Kozlik
parent 698b632acb
commit 4005f4832f

@ -33,8 +33,9 @@ int mp_hal_stdin_rx_chr(void) {
void mp_hal_stdout_tx_strn(const char *str, size_t len) {
if (vcp_iface_num >= 0) {
int r =
usb_vcp_write_blocking(vcp_iface_num, (const uint8_t *)str, len, 500);
// The write timeout is set to 0, because otherwise when the VCP receive
// buffer on the host gets full, the timeout will block device operation.
int r = usb_vcp_write_blocking(vcp_iface_num, (const uint8_t *)str, len, 0);
(void)r;
}
}

Loading…
Cancel
Save