Пример #1
0
 /// <summary>
 /// 将字符型mac转换成byte型
 /// </summary>
 /// <param name="macStr"></param>
 /// <returns></returns>
 public static byte[] GetBytesMACFromString(string macStr)
 {
     byte[] MAC = new byte[8];
     for (int i = 0; i < macStr.Length; i += 2)
     {
         MAC[i / 2] = Convert.ToByte(ConvertUtility.Convert16To10(macStr.Substring(i, 2)));
     }
     return(MAC);
 }