Choose a larger buffer.
This commit is contained in:
@@ -174,7 +174,7 @@ class WebUsbSerialPort {
|
|||||||
async _readLoop() {
|
async _readLoop() {
|
||||||
while (this.isConnected) {
|
while (this.isConnected) {
|
||||||
try {
|
try {
|
||||||
const result = await this.device.transferIn(this.endpointIn, 64);
|
const result = await this.device.transferIn(this.endpointIn, 16384);
|
||||||
if (result.data && this.onReceive) {
|
if (result.data && this.onReceive) {
|
||||||
this.onReceive(result.data);
|
this.onReceive(result.data);
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user