Skip to content
This SDK only works with devices released within the past 3 years. We regularly optimize and update the SDK to ensure compatibility and performance. We do not guarantee compatibility or provide technical support for devices older than 3 years.

# NET_SDK_DEVICE_DISCOVERY_INFO

### Structure Definition

C++C#

     1
     2
     3
     4
     5
     6
     7
     8
     9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    typedef struct _net_sdk_device_discovery_info
    {
        unsigned int deviceType;
        char productType[32];
        char strIP[16];
        char strNetMask[16];
        char strGateWay[16];
        unsigned char byMac[8];
        unsigned short netPort;
        unsigned short httpPort;
        unsigned int softVer;
        unsigned int softBuildDate;
        unsigned char ucIPMode;
        char dwSecondIP[16];
        char dwSecondMask[16];
        char deviceActivated;
        char pwdLevel;
        char nocName[16];
        char devName[20];
    } NET_SDK_DEVICE_DISCOVERY_INFO;

     1
     2
     3
     4
     5
     6
     7
     8
     9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
    [StructLayout(LayoutKind.Sequential, Pack = 4)]
    public struct NET_SDK_DEVICE_DISCOVERY_INFO
    {
        public UInt32 deviceType;
        [MarshalAs(UnmanagedType.ByValArray, ArraySubType = UnmanagedType.U1, SizeConst = 32)]
        public byte[] productType;
        [MarshalAs(UnmanagedType.ByValArray, ArraySubType = UnmanagedType.U1, SizeConst = 16)]
        public byte[] strIP;
        [MarshalAs(UnmanagedType.ByValArray, ArraySubType = UnmanagedType.U1, SizeConst = 16)]
        public byte[] strNetMask;
        [MarshalAs(UnmanagedType.ByValArray, ArraySubType = UnmanagedType.U1, SizeConst = 16)]
        public byte[] strGateWay;
        [MarshalAs(UnmanagedType.ByValArray, ArraySubType = UnmanagedType.U1, SizeConst = 8)]
        public byte[] byMac;
        public UInt16 netPort;
        public UInt16 httpPort;
        public UInt32 softVer;
        public UInt32 softBuildDate;
        public byte ucIPMode;
        [MarshalAs(UnmanagedType.ByValArray, ArraySubType = UnmanagedType.U1, SizeConst = 16)]
        public byte[] dwSecondIP;
        [MarshalAs(UnmanagedType.ByValArray, ArraySubType = UnmanagedType.U1, SizeConst = 16)]
        public byte[] dwSecondMask;
        public byte deviceActivated;
        public byte pwdLevel;
        [MarshalAs(UnmanagedType.ByValArray, ArraySubType = UnmanagedType.U1, SizeConst = 16)]
        public byte[] nocName;
        [MarshalAs(UnmanagedType.ByValArray, ArraySubType = UnmanagedType.U1, SizeConst = 20)]
        public byte[] devName;
    }

### Function Description

The LAN front end discovers the device structure information.

### Member Description

Member | Type | Remark
--- | --- | ---
deviceType | unsigned int | Device type, refer to `NET_SDK_DEVICE_TYPE`.
productType | char[32] | Product type.
strIP | char[16] | IP address.
strNetMask | char[16] | Subnet mask.
strGateWay | char[16] | Gateway.
byMac | unsigned char[8] | MAC address.
netPort | unsigned short | Network port.
httpPort | unsigned short | Client port.
softVer | unsigned int | Software version number.
softBuildDate | unsigned int | The software compilation date.
ucIPMode | unsigned char | 0: static IP; 1: DHCP.
dwSecondIP | char[16] | The second IP address of a dual-NIC device.
dwSecondMask | char[16] | Second subnet mask of dual network card device.
deviceActivated | char | Device activation status, 1: Not activated, 0: activated
pwdLevel | char | Password strength, 1: weak, 2: medium, 3: strong.
nocName | char[16] | Network card name.
devName | char[20] | If the encoding is UTF8, set the version number to 0x10001.

Error Code