feat: readwithwait函数增加了新参数;camera有更多分辨率选择。
This commit is contained in:
@@ -99,7 +99,7 @@ public class RemoteUpdater
|
||||
const int FLASH_SECTOR_LENGTH = 4 * 1024;
|
||||
|
||||
readonly int timeout = 2000;
|
||||
readonly int timeoutForWait = 60 * 1000;
|
||||
readonly int timeoutForWait = 20 * 1000;
|
||||
|
||||
readonly int port;
|
||||
readonly string address;
|
||||
@@ -152,7 +152,7 @@ public class RemoteUpdater
|
||||
{
|
||||
var ret = await UDPClientPool.ReadAddrWithWait(
|
||||
this.ep, 0, RemoteUpdaterAddr.WriteSign,
|
||||
0x00_00_00_01, 0x00_00_00_01, this.timeoutForWait);
|
||||
0x00_00_00_01, 0x00_00_00_01, 100, this.timeoutForWait);
|
||||
if (!ret.IsSuccessful) return new(ret.Error);
|
||||
if (!ret.Value) return new(new Exception(
|
||||
$"Flash clear failed after {this.timeoutForWait} milliseconds"));
|
||||
@@ -167,7 +167,7 @@ public class RemoteUpdater
|
||||
{
|
||||
var ret = await UDPClientPool.ReadAddrWithWait(
|
||||
this.ep, 0, RemoteUpdaterAddr.WriteSign,
|
||||
0x00_00_01_00, 0x00_00_01_00, this.timeoutForWait);
|
||||
0x00_00_01_00, 0x00_00_01_00, 100, this.timeoutForWait);
|
||||
if (!ret.IsSuccessful) return new(ret.Error);
|
||||
return ret.Value;
|
||||
}
|
||||
@@ -332,7 +332,7 @@ public class RemoteUpdater
|
||||
{
|
||||
var ret = await UDPClientPool.ReadAddrWithWait(
|
||||
this.ep, 0, RemoteUpdaterAddr.ReadSign,
|
||||
0x00_00_01_00, 0x00_00_01_00, this.timeoutForWait);
|
||||
0x00_00_01_00, 0x00_00_01_00, 10, this.timeoutForWait);
|
||||
if (!ret.IsSuccessful) return new(ret.Error);
|
||||
if (!ret.Value) return new(new Exception(
|
||||
$"Read bitstream failed after {this.timeoutForWait} milliseconds"));
|
||||
|
||||
Reference in New Issue
Block a user