예제 #1
0
 //reture 介质损耗测试命令生成
 /// <summary>
 /// 介质损耗测试命令生成
 /// </summary>
 /// <param name="jsstation">介质损耗实验位置</param>
 /// <param name="jsstyle">实验模式</param>
 /// <param name="jsvoit">试验电压</param>
 /// <param name="jsfre">实验频率</param>
 /// <param name="Identification">标志位</param>
 /// <returns>返回介质损耗参数数组</returns>
 public byte[] SetPraJs(Parameter.JSstation jsstation, Parameter.JSstyle jsstyle, Parameter.JSVoilt jsvoit,
                        Parameter.JSFrequency jsfre, int Identification)
 {
     byte[] Pra = new byte[7];
     Pra[0] = (byte)0x10;
     Pra[1] = (byte)jsstyle;
     Pra[2] = (byte)jsstation;
     Pra[3] = (byte)jsvoit;
     Pra[4] = (byte)jsfre;
     Pra[5] = (byte)Identification;
     Pra[6] = CheckData(Pra);
     return(Pra);
 }
예제 #2
0
        public static string GetFreQuency(Parameter.JSFrequency jSFrequency)
        {
            if (jSFrequency == Parameter.JSFrequency._45HZ)
            {
                return("45Hz");
            }
            if (jSFrequency == Parameter.JSFrequency._45To_55HZ)
            {
                return("50Hz");
            }
            if (jSFrequency == Parameter.JSFrequency._46HZ)
            {
                return("46Hz");
            }
            if (jSFrequency == Parameter.JSFrequency._47HZ)
            {
                return("47Hz");
            }
            if (jSFrequency == Parameter.JSFrequency._48HZ)
            {
                return("48Hz");
            }
            if (jSFrequency == Parameter.JSFrequency._49HZ)
            {
                return("49Hz");
            }
            if (jSFrequency == Parameter.JSFrequency._49To_51HZ)
            {
                return("50Hz");
            }
            if (jSFrequency == Parameter.JSFrequency._50HZ)
            {
                return("50Hz");
            }
            if (jSFrequency == Parameter.JSFrequency._51HZ)
            {
                return("51Hz");
            }
            if (jSFrequency == Parameter.JSFrequency._52HZ)
            {
                return("52Hz");
            }
            if (jSFrequency == Parameter.JSFrequency._53HZ)
            {
                return("53Hz");
            }
            if (jSFrequency == Parameter.JSFrequency._54HZ)
            {
                return("54Hz");
            }
            if (jSFrequency == Parameter.JSFrequency._55HZ)
            {
                return("55Hz");
            }
            if (jSFrequency == Parameter.JSFrequency._55To_65HZ)
            {
                return("60Hz");
            }
            if (jSFrequency == Parameter.JSFrequency._56HZ)
            {
                return("56Hz");
            }
            if (jSFrequency == Parameter.JSFrequency._57HZ)
            {
                return("57Hz");
            }
            if (jSFrequency == Parameter.JSFrequency._58HZ)
            {
                return("58Hz");
            }
            if (jSFrequency == Parameter.JSFrequency._59HZ)
            {
                return("59Hz");
            }
            if (jSFrequency == Parameter.JSFrequency._59To_61HZ)
            {
                return("60Hz");
            }
            if (jSFrequency == Parameter.JSFrequency._60HZ)
            {
                return("60Hz");
            }
            if (jSFrequency == Parameter.JSFrequency._61HZ)
            {
                return("61Hz");
            }
            if (jSFrequency == Parameter.JSFrequency._62HZ)
            {
                return("62Hz");
            }
            if (jSFrequency == Parameter.JSFrequency._63HZ)
            {
                return("63Hz");
            }
            if (jSFrequency == Parameter.JSFrequency._64HZ)
            {
                return("64Hz");
            }
            if (jSFrequency == Parameter.JSFrequency._65HZ)
            {
                return("65Hz");
            }

            return("55Hz");
        }