protected override void OnAppearing()
        {
            base.OnAppearing();
            Debug.LogToFileMethod();

            if (accelerometerProvider != null)
            {
                accelerometerProvider.SetListener(this);

                labelForceDetectLimit.Text = "ForceDetectLimit: " + sliderForceDetectLimit.Value;
                accelerometerProvider.SetForceDetectLimit((float)sliderForceDetectLimit.Value);

                sliderForceDetectLimit.ValueChanged += (object sender, ValueChangedEventArgs e) =>
                {
                    labelForceDetectLimit.Text = "ForceDetectLimit: " + e.NewValue;
                    accelerometerProvider.SetForceDetectLimit((float)sliderForceDetectLimit.Value);
                };

                labelTimeDetectLimit.Text = "TimeDetectLimit: " + sliderTimeDetectLimit.Value;
                accelerometerProvider.SetTimeDetectLimit((long)sliderTimeDetectLimit.Value);

                sliderTimeDetectLimit.ValueChanged += (object sender, ValueChangedEventArgs e) =>
                {
                    labelTimeDetectLimit.Text = "TimeDetectLimit: " + e.NewValue;
                    accelerometerProvider.SetTimeDetectLimit((long)sliderTimeDetectLimit.Value);
                };

                labelTimeUpdateInterval.Text = "UpdateInterval: " + sliderTimeUpdateInterval.Value;
                accelerometerProvider.SetTimeUpdateInterval((long)sliderTimeUpdateInterval.Value);

                sliderTimeUpdateInterval.ValueChanged += (object sender, ValueChangedEventArgs e) =>
                {
                    labelTimeUpdateInterval.Text = "UpdateInterval: " + e.NewValue;
                    accelerometerProvider.SetTimeUpdateInterval((long)sliderTimeUpdateInterval.Value);
                };

                labelLaunchDetected.Text = "";
            }
        }
Esempio n. 2
0
 public void SetTimeUpdateInterval(long interval) // IDeviceAcceleromter
 {
     accelerometerProvider.SetTimeUpdateInterval(interval);
 }