We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Struct Definition
const FFI = require('ffi-napi') const REF = require('ref-napi') const StrucType = require('ref-struct-di')(REF) const ALARM_ACCESS_CTL_STATUS_INFO = StrucType({ dwSize: REF.types.int, nDoor: REF.types.int, stuTime: REF.refType(NET_TIME), emStatus: REF.types.int, szSerialNumber: ArrayType(REF.types.byte, Constants.NET_MAX_COMMON_256), bRealUTC: REF.types.bool, RealUTC: REF.refType(NET_TIME_EX) })
The Library API:
const NetSDK = FFI.Library(NetSdkLibPath, { CLIENT_SetDVRMessCallBack: [REF.types.void, ['pointer', 'pointer']] })
Callback API:
const alarmCallback = FFI.Callback(REF.types.void, [ 'pointer'], function ( pStuEvent,) { // pStuEvent is instance of Struct "ALARM_ACCESS_CTL_STATUS_INFO" })
Set Callback: NetSDKLib.NetSDK.CLIENT_SetDVRMessCallBack(alarmCallback, null)
NetSDKLib.NetSDK.CLIENT_SetDVRMessCallBack(alarmCallback, null)
My question: How to convert pointer "pStuEvent " to ALARM_ACCESS_CTL_STATUS_INFO instance?
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Struct Definition
The Library API:
Callback API:
Set Callback:
NetSDKLib.NetSDK.CLIENT_SetDVRMessCallBack(alarmCallback, null)
My question:
How to convert pointer "pStuEvent " to ALARM_ACCESS_CTL_STATUS_INFO instance?
The text was updated successfully, but these errors were encountered: