示例#1
0
        public static void testLocationAPI(string deviceId, double longtitude, double latitude, double elevation)
        {
            string amqpsAddress = sendAmqpsAddress;
            string entityPath = sendEntityPath;

            Gateway gateway = new Gateway(amqpsAddress, entityPath);

            gateway.Location(deviceId, longtitude, latitude, elevation);

            gateway.Close();
        }
示例#2
0
        public static void testMeasurementAPI(string deviceId, string measurementId, double value)
        {
            string amqpsAddress = sendAmqpsAddress;
            string entityPath = sendEntityPath;

            Gateway gateway = new Gateway(amqpsAddress, entityPath);

            gateway.Measurement(deviceId, measurementId, value);

            gateway.Close();
        }
示例#3
0
        public static void testAlertAPI(string deviceId, string alertLevel, string alertMessage)
        {
            string amqpsAddress = sendAmqpsAddress;
            string entityPath = sendEntityPath;

            Gateway gateway = new Gateway(amqpsAddress, entityPath);

            gateway.Alert(deviceId, alertLevel, alertMessage);
            //gateway.Measurement(deviceId, "cpu.utils", 23.5);
            //gateway.Location(deviceId, 176.223223f, 54.234323f, 1.0012323f);

            gateway.Close();
        }