コード例 #1
0
 /// <summary>
 /// 获取倒写的16进制BCD码,给每个BCD码增加一个偏移量
 /// </summary>
 /// <param name="hexString">电表编码</param>
 /// <param name="shift">偏移量</param>
 /// <returns>返回电表编码的16进制倒写形式</returns>
 public static string GetReverseHexString_Shift(string hexString, int shift)
 {
     return(HexHelper.GetReverseHexString(hexString, 0, shift));
 }
コード例 #2
0
 /// <summary>
 /// 获取倒写的16进制BCD码,可根据最小长度补0
 /// </summary>
 /// <param name="hexString">电表编码</param>
 /// <param name="minimum">最小长度,应为偶数,假如为0则忽略</param>
 /// <returns>返回电表编码的16进制倒写形式</returns>
 public static string GetReverseHexString(string hexString, int minimum)
 {
     return(HexHelper.GetReverseHexString(hexString, minimum, 0));
 }