diff --git a/Meade.net.Telescope/Telescope.cs b/Meade.net.Telescope/Telescope.cs index 32ee3b6..2e698dd 100644 --- a/Meade.net.Telescope/Telescope.cs +++ b/Meade.net.Telescope/Telescope.cs @@ -74,20 +74,20 @@ namespace ASCOM.Meade.net /// public Telescope() { - tl = new TraceLogger("", "Meade.net.Telescope"); - ReadProfile(); // Read device configuration from the ASCOM Profile store - - tl.LogMessage("Telescope", "Starting initialisation"); - - IsConnected = false; // Initialise connected to false + //todo move this out to IOC _utilities = new Util(); //Initialise util object _utilitiesExtra = new Util(); //Initialise util object _astroUtilities = new AstroUtils(); // Initialise astro utilities object _sharedResourcesWrapper = new SharedResourcesWrapper(); - - //TODO: Implement your additional construction here _astroMaths = new AstroMaths(); + tl = new TraceLogger("", "Meade.net.Telescope"); + tl.LogMessage("Telescope", "Starting initialisation"); + + ReadProfile(); // Read device configuration from the ASCOM Profile store + + IsConnected = false; // Initialise connected to false + tl.LogMessage("Telescope", "Completed initialisation"); } diff --git a/Meade.net.focuser/Focuser.cs b/Meade.net.focuser/Focuser.cs index a0bd42d..73ebca4 100644 --- a/Meade.net.focuser/Focuser.cs +++ b/Meade.net.focuser/Focuser.cs @@ -1,14 +1,8 @@ #define Focuser using System; -using System.Collections.Generic; using System.Diagnostics; -using System.Text; using System.Runtime.InteropServices; - -using ASCOM; -using ASCOM.Astrometry; -using ASCOM.Astrometry.AstroUtils; using ASCOM.Utilities; using ASCOM.DeviceInterface; using System.Globalization; @@ -71,15 +65,16 @@ namespace ASCOM.Meade.net /// public Focuser() { - tl = new TraceLogger("", "Meade.net.focusser"); - ReadProfile(); // Read device configuration from the ASCOM Profile store - - tl.LogMessage("Focuser", "Starting initialisation"); - - IsConnected = false; // Initialise connected to false + //todo move this out to IOC _utilities = new Util(); //Initialise util object _sharedResourcesWrapper = new SharedResourcesWrapper(); + tl = new TraceLogger("", "Meade.net.focusser"); + + tl.LogMessage("Focuser", "Starting initialisation"); + ReadProfile(); // Read device configuration from the ASCOM Profile store + IsConnected = false; // Initialise connected to false + tl.LogMessage("Focuser", "Completed initialisation"); }