add class jtag status reg
This commit is contained in:
@@ -152,6 +152,15 @@ namespace Common
|
||||
return (srcBits & mask) == dstBits;
|
||||
}
|
||||
|
||||
public static Result<bool> ToBit(UInt32 srcBits, int location)
|
||||
{
|
||||
if (location < 0)
|
||||
return new(new ArgumentException(
|
||||
"Location can't be negetive", nameof(location)));
|
||||
|
||||
return (srcBits & (1 << location)) == 1;
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 字符串转二进制字节数组
|
||||
|
||||
Reference in New Issue
Block a user