feat: JtaggetDR可以一次全部获取到

This commit is contained in:
alivender 2025-08-02 16:01:07 +08:00
parent 2f23ffe482
commit f2c7c78b64
2 changed files with 6 additions and 9 deletions

View File

@ -612,13 +612,10 @@ public class Jtag
if (ret.Value) if (ret.Value)
{ {
var array = new UInt32[UInt32Num]; var array = new UInt32[UInt32Num];
for (int i = 0; i < UInt32Num; i++) var retData = await UDPClientPool.ReadAddr4Bytes(ep, 0, JtagAddr.READ_DATA, (int)UInt32Num);
{
var retData = await ReadFIFO(JtagAddr.READ_DATA);
if (!retData.IsSuccessful) if (!retData.IsSuccessful)
return new(new Exception("Read FIFO failed when Load DR")); return new(new Exception("Read FIFO failed when Load DR"));
array[i] = retData.Value; Buffer.BlockCopy(retData.Value, 0, array, 0, (int)UInt32Num * 4);
}
return array; return array;
} }
else else
@ -788,7 +785,7 @@ public class Jtag
{ {
var paser = new BsdlParser.Parser(); var paser = new BsdlParser.Parser();
var portNum = paser.GetBoundaryRegsNum().Value; var portNum = paser.GetBoundaryRegsNum().Value;
logger.Debug($"Get boundar scan registers number: {portNum}"); logger.Debug($"Get boundary scan registers number: {portNum}");
// Clear Data // Clear Data
MsgBus.UDPServer.ClearUDPData(this.address, 0); MsgBus.UDPServer.ClearUDPData(this.address, 0);

View File

@ -8,7 +8,7 @@
<fieldset class="fieldset w-full"> <fieldset class="fieldset w-full">
<legend class="fieldset-legend text-sm">示例比特流文件</legend> <legend class="fieldset-legend text-sm">示例比特流文件</legend>
<div class="space-y-2"> <div class="space-y-2">
<div v-for="bitstream in availableBitstreams" :key="bitstream.id" class="flex items-center justify-between p-2 bg-base-200 rounded"> <div v-for="bitstream in availableBitstreams" :key="bitstream.id" class="flex items-center justify-between p-2 border-2 border-base-300 rounded-lg">
<span class="text-sm">{{ bitstream.name }}</span> <span class="text-sm">{{ bitstream.name }}</span>
<div class="flex gap-2"> <div class="flex gap-2">
<button <button