Card.HuaQing.CheckGasCard C# (CSharp) Метод

CheckGasCard() публичный Метод

public CheckGasCard ( Int16 com, Int32 baud ) : int
com System.Int16
baud System.Int32
Результат int
       public  int CheckGasCard(

             Int16 com,          //串口号,从0开始
             Int32 baud          //波特率
             ){
                 int icdev = ic_init(com, baud);
               //读0x54位置 作为判卡依据

                 byte[] useridhex = new byte[20];
                 byte[] useridasc = new byte[20];
                 string kh= "";
                 Log.Debug("Icdev is " + icdev);
                 Int16 str = srd_4442(icdev, 0xA1, 7, useridhex);
                 Log.Debug("Checkend and ret is  " + str);
                 int ret = -1;
                 if (str == 0)
                 {
                     str = hex_asc(useridhex, useridasc, 16);
                    kh = Encoding.ASCII.GetString(useridasc, 0, 14);        //读出卡号 (用户编号)14位  ok
                    Log.Debug("kh is " + kh);
                 }
                 if (kh.Substring(0, 6).Equals("010001")) {
                     ret = 0;
                 }
                 ic_exit(icdev);
                 return ret;
       }
        public int ReadGasCard(short com, int baud, ref string kh, ref int ql, ref decimal money, ref short cs, ref short bkcs,ref string dm)