Ejemplo n.º 1
0
 /// <summary>
 /// This used to get the values form the device id
 /// </summary>
 /// <param name="deviceID"></param>
 public List <BACnetClass.parameter_class> ScanForParameters(int deviceID)
 {
     parameterListValue.Clear();//Resetting the values
     parameterListValue = BACnetClass.ReadParameterUsigBacnetID(deviceID);
     // parameterListValue = BACnetClass.ReadParameterUsingBacnetIDForTemperatureAndHumidityBoth(deviceID);
     return(parameterListValue);
 }
Ejemplo n.º 2
0
        //Now here we are going to get the connected device value

        ////--Lets build the function we need to do the task
        //public class ca{
        //    public  string deviceName { get; set; }
        //    public string deviceInstance { get; set; }
        //    public string ConnectedPort { get; set; }
        //}

        /// <summary>
        /// This function is used to scan bacnet devices  connected
        /// </summary>
        /// <returns>returns the list of devices</returns>
        public List <BacNode> ScanForDevice()
        {
            //List<BacNode> DevicesList = new List<BacNode>();

            try
            {
                BACnetClass.StartActivity();
                //Console.WriteLine("Started");

                Thread.Sleep(3000); // Wait a fiew time for WhoIs responses (managed in handler_OnIam)
            }
            catch { }

            return(BACnetClass.DevicesList);
        }