Example #1
0
        private void buttonGoCoord_Click(object sender, EventArgs e)
        {
            if (!wisetele.Tracking)
            {
                Status("Telescope is NOT tracking!", 1000, Severity.Error);
                return;
            }

            try
            {
                wisetele.SlewToCoordinatesAsync(new Angle(textBoxRA.Text).Hours, new Angle(textBoxDec.Text).Degrees);
            } catch (Exception ex)
            {
                Status(ex.Message, 2000, Severity.Error);
            }
        }
Example #2
0
        public void SlewToCoordinatesAsync(double RightAscension, double Declination)
        {
            if (wisetele.ShuttingDown)
            {
                throw new InvalidOperationException("Wise40 is shutting down");
            }

            try
            {
                _driverInitiatedSlew = true;
                wisetele.SlewToCoordinatesAsync(RightAscension, Declination);
            }
            catch
            {
                _driverInitiatedSlew = false;
                throw;
            }
            _driverInitiatedSlew = false;
        }