Slave Control API > BS2_GetOsdpStandardDeviceCapability


[+ 2.9.1] CoreStation40 OSDP 장치의 지원 정보를 가져옵니다.

함수

#include "BS_API.h"
 
int BS2_GetOsdpStandardDeviceCapability(void* context, uint32_t osdpDeviceId, BS2OsdpStandardDeviceCapability* capability);

파라미터

  • [In] context : Context
  • [In] osdpDeviceId : OSDP 장치 식별자
  • [Out] capability : 지원 정보 구조체 포인터

반환값

성공적으로 수행될 경우 BS_SDK_SUCCESS를 반환하고, 에러가 발생할 경우 상응하는 에러 코드를 반환합니다.

함께 보기

샘플코드(C++)

sample_bs2_getosdpstandarddevicecapability.cpp
BS2OsdpStandardDeviceCapability capability = { 0, };
 
BS2_DEVICE_ID id = Utility::selectSlaveID();
int sdkResult = BS2_GetOsdpStandardDeviceCapability(context_, id, &capability);
if (BS_SDK_SUCCESS != sdkResult)
	printf("BS2_GetOsdpStandardDeviceCapability call failed: %d", sdkResult);
 
return sdkResult;

샘플코드(C#)

sample_bs2_getosdpstandarddevicecapability.cs
UInt32 id = Util.GetInputSlaveID();
 
BS2OsdpStandardDeviceCapability capability;
BS2ErrorCode result = (BS2ErrorCode)API.BS2_GetOsdpStandardDeviceCapability(sdkContext, id, out capability);
if (result != BS2ErrorCode.BS_SDK_SUCCESS)
	Console.WriteLine("Got error({0}).", result);
else
	Console.WriteLine("Call success.");
 
return result;