资源简介

修改DemoActivity配置,亲测可用

资源截图

代码片段和文件信息

package com.test.demo;
import com.hikvision.netsdk.*;
public class AlarmTest {
private static AlarmCallBack_V30 AlarmCbf = null;
    private static void processAlarmData(int lCommand NET_DVR_ALARMER Alarmer NET_DVR_base_ALARM AlarmInfo)
    {
     String sIP = new String(Alarmer.sDeviceIP);
     System.out.println(“recv alarm from:“ + sIP);
     if(lCommand == HCNetSDK.COMM_ALARM_V30)
     {
     NET_DVR_ALARMINFO_V30 strAlarmInfo = (NET_DVR_ALARMINFO_V30)AlarmInfo;
         System.out.println(“recv alarm V30:“ + strAlarmInfo.dwAlarmType);
     }
    }
public static void Test_SetupAlarm(int iUserID)
{
  if(AlarmCbf == null)
{
AlarmCbf = new AlarmCallBack_V30()
{
public void fMSGCallBack( int lCommand NET_DVR_ALARMER Alarmer NET_DVR_base_ALARM AlarmInfo)
{
   processAlarmData(lCommand Alarmer AlarmInfo);   
}
};


  HCNetSDK.getInstance().NET_DVR_SetDVRMessageCallBack_V30(AlarmCbf);

int iAlarmHandle = HCNetSDK.getInstance().NET_DVR_SetupAlarmChan_V30(iUserID);
  if (-1 == iAlarmHandle)
{
System.out.println(“NET_DVR_SetupAlarmChan_V30 failed!“ + HCNetSDK.getInstance().NET_DVR_GetLastError());
}
  else
  {
  System.out.println(“NET_DVR_SetupAlarmChan_V30 succeed!“);              
  }
try {
Thread.sleep(10*1000);
} catch (InterruptedException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
if(!HCNetSDK.getInstance().NET_DVR_CloseAlarmChan_V30(iAlarmHandle))
{
System.out.println(“NET_DVR_CloseAlarmChan_V30 failed! error:“ + HCNetSDK.getInstance().NET_DVR_GetLastError());
}
  else
  {
  System.out.println(“NET_DVR_CloseAlarmChan_V30 succeed!“);              
  }


}
}

 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----
     目录           0  2016-07-21 11:05  Android_V5.1.5.5_build20151228_CN\
     目录           0  2016-07-21 11:05  Android_V5.1.5.5_build20151228_CN\Doc\
     文件     1244552  2014-02-13 10:54  Android_V5.1.5.5_build20151228_CN\Doc\Hikvision Android播放库编程指南V7.1.pdf
     文件     1344763  2015-07-24 11:31  Android_V5.1.5.5_build20151228_CN\Doc\设备网络SDK编程指南(Android).pdf
     目录           0  2016-07-21 11:05  Android_V5.1.5.5_build20151228_CN\SimpleDemo\
     文件         872  2015-12-25 09:44  Android_V5.1.5.5_build20151228_CN\SimpleDemo\.classpath
     文件         846  2015-12-25 09:44  Android_V5.1.5.5_build20151228_CN\SimpleDemo\.project
     目录           0  2016-07-21 11:05  Android_V5.1.5.5_build20151228_CN\SimpleDemo\.settings\
     文件          88  2015-12-25 09:44  Android_V5.1.5.5_build20151228_CN\SimpleDemo\.settings\org.eclipse.core.resources.prefs
     文件         629  2015-12-25 09:44  Android_V5.1.5.5_build20151228_CN\SimpleDemo\.settings\org.eclipse.jdt.core.prefs
     文件         106  2015-12-25 09:44  Android_V5.1.5.5_build20151228_CN\SimpleDemo\.settings\org.eclipse.ltk.core.refactoring.prefs
     文件        1026  2015-12-25 09:44  Android_V5.1.5.5_build20151228_CN\SimpleDemo\AndroidManifest.xml
     文件       19480  2015-12-25 09:44  Android_V5.1.5.5_build20151228_CN\SimpleDemo\AudioEngineSDK.jar
     文件      107809  2015-12-25 09:44  Android_V5.1.5.5_build20151228_CN\SimpleDemo\HCNetSDK.jar
     文件       18422  2015-12-25 09:44  Android_V5.1.5.5_build20151228_CN\SimpleDemo\PlayerSDK.jar
     目录           0  2016-07-21 11:05  Android_V5.1.5.5_build20151228_CN\SimpleDemo\assets\
     目录           0  2016-07-21 11:05  Android_V5.1.5.5_build20151228_CN\SimpleDemo\bin\
     目录           0  2016-07-21 11:05  Android_V5.1.5.5_build20151228_CN\SimpleDemo\bin\classes\
     文件          35  2015-12-25 09:44  Android_V5.1.5.5_build20151228_CN\SimpleDemo\default.properties
     目录           0  2016-07-21 11:05  Android_V5.1.5.5_build20151228_CN\SimpleDemo\gen\
     目录           0  2016-07-21 11:05  Android_V5.1.5.5_build20151228_CN\SimpleDemo\libs\
     目录           0  2016-07-21 11:05  Android_V5.1.5.5_build20151228_CN\SimpleDemo\libs\armeabi\
     文件      546432  2015-12-25 09:44  Android_V5.1.5.5_build20151228_CN\SimpleDemo\libs\armeabi\libAudioEngine.so
     文件       12464  2015-12-25 09:44  Android_V5.1.5.5_build20151228_CN\SimpleDemo\libs\armeabi\libCpuFeatures.so
     文件      177568  2015-12-28 10:34  Android_V5.1.5.5_build20151228_CN\SimpleDemo\libs\armeabi\libHCAlarm.so
     文件      981244  2015-12-28 10:33  Android_V5.1.5.5_build20151228_CN\SimpleDemo\libs\armeabi\libHCCore.so
     文件      603848  2015-12-28 10:34  Android_V5.1.5.5_build20151228_CN\SimpleDemo\libs\armeabi\libHCCoreDevCfg.so
     文件      341444  2015-12-28 10:34  Android_V5.1.5.5_build20151228_CN\SimpleDemo\libs\armeabi\libHCDisplay.so
     文件      845416  2015-12-28 10:35  Android_V5.1.5.5_build20151228_CN\SimpleDemo\libs\armeabi\libHCGeneralCfgMgr.so
     文件      644680  2015-12-28 10:35  Android_V5.1.5.5_build20151228_CN\SimpleDemo\libs\armeabi\libHCIndustry.so
     文件      218548  2015-12-28 10:36  Android_V5.1.5.5_build20151228_CN\SimpleDemo\libs\armeabi\libHCPlayBack.so
............此处省略37个文件信息

评论

共有 条评论