fix download bitstream and add json convert for jtag status reg

This commit is contained in:
2025-04-25 17:14:34 +08:00
parent 2b5154062d
commit 42ddd0fcdb
5 changed files with 58 additions and 37 deletions

View File

@@ -36,4 +36,13 @@ public class CommonTest
};
Assert.Equal(Number.ReverseBytes(bytesArray, 4).Value, rev4Bytes);
}
[Fact]
public void ToBitTest()
{
Assert.Equal(Number.ToBit(0xFF, 3).Value, true);
Assert.Equal(Number.ToBit(0x00, 3).Value, false);
Assert.Equal(Number.ToBit(0xAA, 3).Value, true);
Assert.Equal(Number.ToBit(0xAA, 2).Value, false);
}
}