public int ReadGasCard(short com, int baud, ref string kh, ref int ql, ref decimal money, ref short cs, ref Int16 bkcs, ref string yhh)
{
int ret = -1;
try
{
byte[] CardNum = new byte[8];
Int32[] GasNum = new Int32[1];
Int32[] Times = new Int32[1];
Int32[] MeterType = new Int32[1];
ret = StaticReadCard(com, baud, CardNum, GasNum, Times, MeterType);
kh = System.Text.Encoding.Default.GetString(CardNum).Replace("\0", "");
ql = GasNum[0];
cs = (short)Times[0];
int metertype = MeterType[0];
Log.Debug("read card ret=" + ret + "--卡号:" + kh + "---气量:" + ql + "---次数:" + cs + "---表类型:" + metertype);
}
catch (Exception e)
{
Log.Debug("读卡异常:"+e.Message+"---"+e.StackTrace);
}
return ret;
}