Beispiel #1
0
        public void PerformScan_DoublePointArray()
        {
            Thread thread = new Thread(() =>
            {
                Thread.Sleep(1000);
                Random random = new Random((int)DateTime.Now.Ticks);
                for (int j = 0; j < 10; j++)
                {
                    List <double> xValues = new List <double>();
                    List <double> yValues = new List <double>();
                    for (int i = 0; i < 200; i++)
                    {
                        //Thread.Sleep(20);
                        int start = Math.Abs(i - 100);
                        int index = i * 10;
                        xValues.Add(index);
                        yValues.Add(random.Next(start, 100 + start));
                    }
                    DoublePoint_Arrays_CallBack?.Invoke(xValues.ToArray(), yValues.ToArray());
                }
                ScanCompelete_CallBack?.Invoke();
            })
            {
                IsBackground = true
            };

            thread.Start();
        }
Beispiel #2
0
        public void PerformScan_DoublePoint()
        {
            Thread thread = new Thread(() =>
            {
                Thread.Sleep(1000);
                Random random = new Random((int)DateTime.Now.Ticks);
                for (int i = 0; i < 200; i++)
                {
                    Thread.Sleep(20);
                    int start = Math.Abs(i - 100);
                    int index = i * 10;
                    DoublePoint_CallBack?.Invoke(index, random.Next(start, 100 + start));
                }
                ScanCompelete_CallBack?.Invoke();
            })
            {
                IsBackground = true
            };

            thread.Start();
        }