Configure Radar Intrusion Alarm

The radar PTZ camera detects people, vehicle, or other objects which enter and loiter in a predefined virtual region to trigger intrusion alarm, and some certain actions can be taken when the alarm is triggered.

  • Make sure you have called NET_DVR_Init to initialize the development environment.

  • Make sure you have called NET_DVR_Login_V40 to log in to the device.

Figure 1 API Calling Flow of Configuring Radar Intrusion Alarm

  1. Call NET_DVR_STDXMLConfig to transmit /ISAPI/System/capabilities or /ISAPI/Smart/capabilities by GET method for getting device or smart capability to check.

    The device capability (XML_DeviceCap) or smart capability (XML_SmartCap) is returned by lpOutputParam.

  2. Check whether the device supports radar intrusion detection.
    • It supports and continue the following steps when the nodes <isSupporFieldDetection> and <isSupportRadarFieldDetection> is returned in the XML_DeviceCap and their values are "true".

      \
    • It supports and continue the following steps when the node <isSupportFieldDetection> is returned in the XML_SmartCap and its value is "true".

    • It does not support and end this task when neither the XML_DeviceCap nor the XML_SmartCap contains node <isSupporFieldDetection.

  3. Optional: Call NET_DVR_STDXMLConfig to transmit /ISAPI/Smart/RadarChannels/<ID>/radarFieldDetection/capabilities?format=json by GET method for getting configuration capability of radar intrusion detection.

    The configuration capability is returned in the message JSON_RadarFieldDetectionCap by lpOutputParam.

  4. Call NET_DVR_STDXMLConfig to transmit /ISAPI/Smart/RadarChannels/<ID>/radarFieldDetection?format=json by PUT method and set lpInputParam to JSON_RadarFieldDetection for setting radar intrusion detection parameters of a channel.
  5. Call NET_DVR_STDXMLConfig to transmit /ISAPI/Smart/RadarChannels/<ID>/radarFieldDetection/regions/<regionID>?format=json or /ISAPI/Smart/RadarChannels/<ID>/radarFieldDetection/regions?format=json by PUT method and set lpInputParam to JSON_RegionInfo or JSON_RegionListrespectively, for setting parameters of one or all detection region(s).
  6. Optional: Call NET_DVR_STDXMLConfig to transmit /ISAPI/Event/channels/<ID>/capabilities or /ISAPI/Event/channels/capabilities by GET method for getting event capability of one or all channel(s).

    The event capability is returned in the message XML_ChannelEventCap by lpOutputParam.

  7. Call NET_DVR_STDXMLConfig to transmit /ISAPI/Event/schedules/radarFieldDetections/<ID> or /ISAPI/Event/schedules/radarFieldDetections by PUT method, set <ID> in the single configuration URI to "radarFieldDetection-<channelID>" (e.g., /ISAPI/Event/schedules/radarFieldDetections/radarFieldDetection-101), and set lpInputParam to XML_RadarFieldDetectionScheduleList or XML_Schedule respectively, for setting arming schedules of one or all channel(s).
  8. Optional: Call NET_DVR_STDXMLConfig to transmit /ISAPI/Event/triggersCap by GET method for getting linkage capability of radar intrusion alarm.

    The linkage capability is returned in the message XML_EventTriggersCap by lpOutputParam.

  9. Call NET_DVR_STDXMLConfig to transmit /ISAPI/Event/triggers/<eventType>-<channelID> by PUT method, set <ID> in the URI to "radarFieldDetection-<channelID>" (e.g., /ISAPI/Event/triggers/radarFieldDetection-101), and set lpInputParam to XML_EventTrigger for setting linkage action of a radar intrusion alarm.
    Note:

    To receive alarm in the platform, the linkage action must be set to "center" (upload to center).

  10. Optional: Set lCommand to "COMM_ALARM_RULE" (command No.: 0x1102) and set wEventTypeEx to "ENUM_VCA_EVENT_INTRUSION" for receiving radar intrusion alarm in arming mode (see Receive Alarm/Event in Arming Mode) or listening mode (see Receive Alarm/Event in Listening Mode) when alarm is triggered.

    The radar intrusion alarm details are returned in the structure NET_VCA_RULE_ALARM.

Call NET_DVR_Logout and NET_DVR_Cleanup to log out and release resources.