Exemplo n.º 1
0
        public void Print2File()
        {
            string line = "Frequency = " + Globals.FREQUENCY / 1e9 + "GHz, IFBW = " + Globals.IFBW / 1e3 + "kHz, Z_distance = " + Globals.Z_DISTANCE + "m\n";

            line += "AUT dimension [m]: " + Globals.AUT_DIM_X + ", " + Globals.AUT_DIM_Y + ", " + Globals.AUT_DIM_Z + "\n";
            File.AppendAllText(Globals.FILENAME, line);
            for (int i = 0; i < this.processed_MeasList.Count; i++)
            {
                System_MeasPoint smp = this.processed_MeasList[i];
                line = smp.time + ", " + smp.x + ", " + smp.y + ", " + smp.penAng + ", " + smp.motorAng + ", " + smp.phaseAng + ", " + smp.S21_real + ", " + smp.S21_imag + ", " + Convert.ToInt32(smp.isNormPolar) + "\n";
                File.AppendAllText(Globals.FILENAME, line);
            }
        }
Exemplo n.º 2
0
        private void processMeasuredData()
        {
            this.processed_MeasList = new List <System_MeasPoint>();
            for (int i = 0; i < this.pna_MeasList.Count; i++)
            {
                List <PNA_MeasPoint>     pmpl = this.pna_MeasList[i];
                List <Arduino_MeasPoint> ampl = this.penAng_MeasList[i];
                List <Motor_MeasPoint>   mmpl = this.motorAng_MeasList[i];
                bool isNormPolar = this.isNormPolarList[i];

                for (int j = 0; j < pmpl.Count; j++)
                {
                    PNA_MeasPoint    pmp = pmpl[j];
                    System_MeasPoint smp = this.kinematics(mmpl, ampl, pmp, isNormPolar);
                    if (Math.Abs(smp.penAng) <= Globals.TARGET_ANGLE)
                    {
                        this.processed_MeasList.Add(smp);
                    }
                }
            }
        }