示例#1
0
 private void Security_Demo_CP_Shown(object sender, EventArgs e)
 {
     WDS_MainProg.frameWin();
     base.Location = WDS_MainProg.frameWin().getNextChildPosition();
     List<ViewDataReceiver.ColumnDescriptor> verA = new List<ViewDataReceiver.ColumnDescriptor> {
         new ViewDataReceiver.ColumnDescriptor("CTRL", 0x4c, ViewDataReceiver.DisplayFormat.Hex8, 3, 0),
         new ViewDataReceiver.ColumnDescriptor("CID", 0x4c, ViewDataReceiver.DisplayFormat.Hex8, 4, 0),
         new ViewDataReceiver.ColumnDescriptor("SID", 0x4c, ViewDataReceiver.DisplayFormat.Hex8, 5, 0),
         new ViewDataReceiver.ColumnDescriptor("DID", 0x4c, ViewDataReceiver.DisplayFormat.Hex8, 6, 0),
         new ViewDataReceiver.ColumnDescriptor("Length", 0x4c, ViewDataReceiver.DisplayFormat.Dec8, 7, 0)
     };
     List<ViewDataReceiver.ColumnDescriptor> list2 = new List<ViewDataReceiver.ColumnDescriptor> {
         new ViewDataReceiver.ColumnDescriptor("Packet Type", 150, ViewDataReceiver.DisplayFormat.PacketType, 8, 0),
         new ViewDataReceiver.ColumnDescriptor("HW Type", 130, ViewDataReceiver.DisplayFormat.HwType, 11, 0),
         new ViewDataReceiver.ColumnDescriptor("App Type", 0x69, ViewDataReceiver.DisplayFormat.AppType, 12, 0)
     };
     List<ViewDataReceiver.ColumnDescriptor> verB = new List<ViewDataReceiver.ColumnDescriptor> {
         new ViewDataReceiver.ColumnDescriptor("Packet Type", 280, ViewDataReceiver.DisplayFormat.PacketType, 8, 0),
         new ViewDataReceiver.ColumnDescriptor("Button", 0x69, ViewDataReceiver.DisplayFormat.Button, 14, 0)
     };
     List<ViewDataReceiver.ColumnDescriptor> list4 = new List<ViewDataReceiver.ColumnDescriptor> {
         new ViewDataReceiver.ColumnDescriptor("RSSI", 0x60, ViewDataReceiver.DisplayFormat.RSSI, 2, 0),
         new ViewDataReceiver.ColumnDescriptor("TEMP", 0x60, ViewDataReceiver.DisplayFormat.Temp, 11, 0),
         new ViewDataReceiver.ColumnDescriptor("Battery", 0x60,ViewDataReceiver.DisplayFormat.Battery, 13, 0),
         new ViewDataReceiver.ColumnDescriptor("Humidity", 0x60, ViewDataReceiver.DisplayFormat.Percent, 10, 0)
     };
     List<ViewDataReceiver.ColumnDescriptor> list5 = new List<ViewDataReceiver.ColumnDescriptor> {
         new ViewDataReceiver.ColumnDescriptor("RSSI", 0x60, ViewDataReceiver.DisplayFormat.RSSI, 2, 0),
         new ViewDataReceiver.ColumnDescriptor("TEMP", 0x60, ViewDataReceiver.DisplayFormat.Temp, 11, 0),
         new ViewDataReceiver.ColumnDescriptor("Battery", 0x60, ViewDataReceiver.DisplayFormat.Battery, 13, 0),
         new ViewDataReceiver.ColumnDescriptor("POT", 0x60, ViewDataReceiver.DisplayFormat.Hex16, 9, 0)
     };
     ViewDataReceiver.ControlGridDescriptor fstGrid = new ViewDataReceiver.ControlGridDescriptor(verA, null, 0, 130, 0, false);
     ViewDataReceiver.ControlGridDescriptor secGrid = new ViewDataReceiver.ControlGridDescriptor(list2, verB, 8, 0x44, 3, true);
     ViewDataReceiver.ControlGridDescriptor thrGrid = new ViewDataReceiver.ControlGridDescriptor(list4, list5, 9, 0x33, 0xff, true);
     viewDataReceiver1.initView(fstGrid, secGrid, thrGrid, 0x10);
     viewRssi1.startTrend();
 }
示例#2
0
 private void Harvesting_Demo_CP_Shown(object sender, EventArgs e)
 {
     WDS_MainProg.frameWin();
     base.Location = WDS_MainProg.frameWin().getNextChildPosition();
     List<ViewDataReceiver.ColumnDescriptor> verA = new List<ViewDataReceiver.ColumnDescriptor> {
         new ViewDataReceiver.ColumnDescriptor("CTRL", 0x4c, ViewDataReceiver.DisplayFormat.Hex8, 3, 0),
         new ViewDataReceiver.ColumnDescriptor("CID", 0x4c, ViewDataReceiver.DisplayFormat.Hex8, 4, 0),
         new ViewDataReceiver.ColumnDescriptor("SID", 0x4c, ViewDataReceiver.DisplayFormat.Hex8, 5, 0),
         new ViewDataReceiver.ColumnDescriptor("DID", 0x4c, ViewDataReceiver.DisplayFormat.Hex8, 6, 0),
         new ViewDataReceiver.ColumnDescriptor("Length", 0x4c, ViewDataReceiver.DisplayFormat.Dec8, 7, 0)
     };
     List<ViewDataReceiver.ColumnDescriptor> list2 = new List<ViewDataReceiver.ColumnDescriptor> {
         new ViewDataReceiver.ColumnDescriptor("Packet Type", 150, ViewDataReceiver.DisplayFormat.PacketType, 8, 0),
         new ViewDataReceiver.ColumnDescriptor("RSSI", 0x60, ViewDataReceiver.DisplayFormat.RSSI, 2, 0)
     };
     List<ViewDataReceiver.ColumnDescriptor> list3 = new List<ViewDataReceiver.ColumnDescriptor> {
         new ViewDataReceiver.ColumnDescriptor("VBAT", 0x60, ViewDataReceiver.DisplayFormat.Percent, 9, 0),
         new ViewDataReceiver.ColumnDescriptor("TEMP", 0x60, ViewDataReceiver.DisplayFormat.Temp_S16_dC, 10, 0),
         new ViewDataReceiver.ColumnDescriptor("LIGHT_LEVEL", 0x60, ViewDataReceiver.DisplayFormat.NotAvailable, 0, 0)
     };
     List<ViewDataReceiver.ColumnDescriptor> verB = new List<ViewDataReceiver.ColumnDescriptor> {
         new ViewDataReceiver.ColumnDescriptor("VBAT", 0x60, ViewDataReceiver.DisplayFormat.NotAvailable, 0, 0),
         new ViewDataReceiver.ColumnDescriptor("TEMP", 0x60, ViewDataReceiver.DisplayFormat.NotAvailable, 0, 0),
         new ViewDataReceiver.ColumnDescriptor("LIGHT_LEVEL", 0x60, ViewDataReceiver.DisplayFormat.LightLevel_Lux, 9, 0)
     };
     ViewDataReceiver.ControlGridDescriptor fstGrid = new ViewDataReceiver.ControlGridDescriptor(verA, null, 0, 130, 0, false);
     ViewDataReceiver.ControlGridDescriptor secGrid = new ViewDataReceiver.ControlGridDescriptor(list2, null, 0, 130, 0, false);
     ViewDataReceiver.ControlGridDescriptor thrGrid = new ViewDataReceiver.ControlGridDescriptor(list3, verB, 8, 7, 8, true);
     viewDataReceiver1.initView(fstGrid, secGrid, thrGrid, 0x10);
     viewRssi1.startTrend();
     send_EnDis(1);
 }
示例#3
0
        private void RF_To_USB_Network_Demo_CP_Shown(object sender, EventArgs e)
        {
            WDS_MainProg.frameWin();
            base.Location = WDS_MainProg.frameWin().getNextChildPosition();
            List<ViewDataReceiver.ColumnDescriptor> verA = new List<ViewDataReceiver.ColumnDescriptor> {
                new ViewDataReceiver.ColumnDescriptor("CTRL", 0x4c, ViewDataReceiver.DisplayFormat.Hex8, 3, 0),
                new ViewDataReceiver.ColumnDescriptor("CID", 0x4c, ViewDataReceiver.DisplayFormat.Hex8, 4, 0),
                new ViewDataReceiver.ColumnDescriptor("SID", 0x4c, ViewDataReceiver.DisplayFormat.Hex8, 5, 0),
                new ViewDataReceiver.ColumnDescriptor("DID", 0x4c, ViewDataReceiver.DisplayFormat.Hex8, 6, 0),
                new ViewDataReceiver.ColumnDescriptor("Length", 0x4c, ViewDataReceiver.DisplayFormat.Dec8, 7, 0)
            };
            List<ViewDataReceiver.ColumnDescriptor> list2 = new List<ViewDataReceiver.ColumnDescriptor> {
                new ViewDataReceiver.ColumnDescriptor("Packet Type", 150, ViewDataReceiver.DisplayFormat.PacketType, 8, 0),
                new ViewDataReceiver.ColumnDescriptor("RSSI", 0x60, ViewDataReceiver.DisplayFormat.RSSI, 2, 0)
            };
            List<ViewDataReceiver.ColumnDescriptor> list3 = new List<ViewDataReceiver.ColumnDescriptor> {
                new ViewDataReceiver.ColumnDescriptor("POT", 0x60, ViewDataReceiver.DisplayFormat.Hex16, 9, 0),
                new ViewDataReceiver.ColumnDescriptor("TEMP", 0x60, ViewDataReceiver.DisplayFormat.Temp_S16_dC, 11, 0),
                new ViewDataReceiver.ColumnDescriptor("VBAT", 0x60, ViewDataReceiver.DisplayFormat.Battery_U16_mV, 13, 0)
            };

            ViewDataReceiver.ControlGridDescriptor fstGrid = new ViewDataReceiver.ControlGridDescriptor(verA, null, 0, 130, 0, false);
            ViewDataReceiver.ControlGridDescriptor secGrid = new ViewDataReceiver.ControlGridDescriptor(list2, null, 0, 130, 0, false);
            ViewDataReceiver.ControlGridDescriptor thrGrid = new ViewDataReceiver.ControlGridDescriptor(list3, null, 0, 130, 0, false);

            viewDataReceiver1.initView(fstGrid, secGrid, thrGrid, 0x10);
            viewRssi1.startTrend();
            send_EnDis(1);
        }
示例#4
0
文件: RKE_Demo_CP.cs 项目: x893/WDS
 private void RKE_Demo_CP_Shown(object sender, EventArgs e)
 {
     WDS_MainProg.frameWin();
     base.Location = WDS_MainProg.frameWin().getNextChildPosition();
     List<ViewDataReceiver.ColumnDescriptor> verA = new List<ViewDataReceiver.ColumnDescriptor> {
         new ViewDataReceiver.ColumnDescriptor("CTRL", 0x4c, ViewDataReceiver.DisplayFormat.Hex8, 3, 0),
         new ViewDataReceiver.ColumnDescriptor("CID", 0x4c, ViewDataReceiver.DisplayFormat.Hex8, 4, 0),
         new ViewDataReceiver.ColumnDescriptor("SID", 0x4c, ViewDataReceiver.DisplayFormat.Hex8, 5, 0),
         new ViewDataReceiver.ColumnDescriptor("DID", 0x4c, ViewDataReceiver.DisplayFormat.Hex8, 6, 0),
         new ViewDataReceiver.ColumnDescriptor("Length", 0x4e, ViewDataReceiver.DisplayFormat.Dec8, 7, 0)
     };
     List<ViewDataReceiver.ColumnDescriptor> list2 = new List<ViewDataReceiver.ColumnDescriptor> {
         new ViewDataReceiver.ColumnDescriptor("Packet Type", 180, ViewDataReceiver.DisplayFormat.PacketType, 8, 0),
         new ViewDataReceiver.ColumnDescriptor("HW Type", 100, ViewDataReceiver.DisplayFormat.HwType, 9, 0),
         new ViewDataReceiver.ColumnDescriptor("App Type", 0x69, ViewDataReceiver.DisplayFormat.AppType, 10, 0)
     };
     List<ViewDataReceiver.ColumnDescriptor> verB = new List<ViewDataReceiver.ColumnDescriptor> {
         new ViewDataReceiver.ColumnDescriptor("Packet Type", 280, ViewDataReceiver.DisplayFormat.PacketType, 8, 0),
         new ViewDataReceiver.ColumnDescriptor("Button", 0x69, ViewDataReceiver.DisplayFormat.Button, 14, 0)
     };
     List<ViewDataReceiver.ColumnDescriptor> list4 = new List<ViewDataReceiver.ColumnDescriptor> {
         new ViewDataReceiver.ColumnDescriptor("Address", 60, ViewDataReceiver.DisplayFormat.Hex32, 12, 0),
         new ViewDataReceiver.ColumnDescriptor("SyncCnt", 60, ViewDataReceiver.DisplayFormat.Hex32, 0x10, 0),
         new ViewDataReceiver.ColumnDescriptor("AES", 40, ViewDataReceiver.DisplayFormat.AES, 11, 0),
         new ViewDataReceiver.ColumnDescriptor("AES-128 Key", 0xe1, ViewDataReceiver.DisplayFormat.ASCIIAESKey, 2, 0x10)
     };
     List<ViewDataReceiver.ColumnDescriptor> list5 = new List<ViewDataReceiver.ColumnDescriptor> {
         new ViewDataReceiver.ColumnDescriptor("Address", 60, ViewDataReceiver.DisplayFormat.Hex32, 10, 0),
         new ViewDataReceiver.ColumnDescriptor("SyncCnt", 60, ViewDataReceiver.DisplayFormat.Hex32, 0x12, 0),
         new ViewDataReceiver.ColumnDescriptor("AES", 40, ViewDataReceiver.DisplayFormat.AES, 9, 0),
         new ViewDataReceiver.ColumnDescriptor("AES-128 Key", 0xe1, ViewDataReceiver.DisplayFormat.ASCIIAESKey, 2, 0x10)
     };
     ViewDataReceiver.ControlGridDescriptor fstGrid = new ViewDataReceiver.ControlGridDescriptor(verA, null, 0, 130, 0, false);
     ViewDataReceiver.ControlGridDescriptor secGrid = new ViewDataReceiver.ControlGridDescriptor(list2, verB, 8, 0x47, 4, true);
     ViewDataReceiver.ControlGridDescriptor thrGrid = new ViewDataReceiver.ControlGridDescriptor(list4, list5, 8, 0x47, 4, false);
     viewDataReceiver1.initView(fstGrid, secGrid, thrGrid, 0x10);
 }