Commit 5e4fa917 authored by martin hou's avatar martin hou

fix: 延长文件传输等待超时时长

parent 4a8ad7a0
...@@ -292,7 +292,7 @@ function Jensen(log, conn) { ...@@ -292,7 +292,7 @@ function Jensen(log, conn) {
current = 'cmd-' + cmd.command + '-' + cmd.index; current = 'cmd-' + cmd.command + '-' + cmd.index;
Logger.debug('jensen', 'sendNext', pid + '-command: ' + cmd.command + ', data bytes: ' + data.byteLength); Logger.debug('jensen', 'sendNext', pid + '-command: ' + cmd.command + ', data bytes: ' + data.byteLength);
self.timewait = cmd.command == TRANSFER_FILE || cmd.command == GET_FILE_BLOCK ? 1000 : 10; self.timewait = cmd.command == TRANSFER_FILE || cmd.command == GET_FILE_BLOCK ? 5000 : 10;
console.log(pid + 'Send', data); console.log(pid + 'Send', data);
await device.transferOut(1, data).catch((e) => crash('sendNext', e)); await device.transferOut(1, data).catch((e) => crash('sendNext', e));
if (cmd.onprogress) cmd.onprogress(1, 1); if (cmd.onprogress) cmd.onprogress(1, 1);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment