コード例 #1
0
        private void SetAP(object sender, Windows.UI.Xaml.RoutedEventArgs e)
        {
            string AP_X = XPoint.Text;
            string AP_Y = YPoint.Text;
            string AP_Z = ZPoint.Text;


            crossbase.setData("AP-X", AP_X);
            crossbase.setData("AP-Y", AP_Y);
            crossbase.setData("AP-Z", AP_Z);
            successed();
        }
コード例 #2
0
        public async Task BackgroundCalulating()
        {
            while (true)
            {
                Dictionary <int, Dictionary <string, int> > dataDict = await Average();

                double rssi = calculateRSSI(dataDict[1], dataDict[2]);
                if (rssi < int.Parse(crossbase.getData("min_distance")))
                {
                    crossbase.setData("id-1-vibrate", "true");
                    crossbase.setData("id-2-vibrate", "true");
                }

                LengthBox.Text = (rssi * 10).ToString();
            }
        }