hamedal-sdk
v2.2.3
Published
Hamedal's Software Development Kit (SDK) used to interact with the camera by third-party applications
Downloads
3
Maintainers
Readme
HamedalSDK
Example
var Hamedal = require('hamedal-sdk')
var cameras = Hamedal.falcon.devices();
if (cameras.length == 0){
console.log('unable');
}
console.log(cameras);
cameraInfo = cameras[0];
falcon = new Hamedal.falcon.FalconCamera(cameraInfo);
falcon.isAIModeEnabled().then(value => {
console.log("The status of the camera mode: ", value ? "enabled" : "disabled");
}).catch(reason => {
console.log(reason);
});
falcon.disableAIMode().then(value => {
console.log("Disable the ai mode of the camera: ", value);
}).catch(reason => {
console.log(reason);
});
falcon.enableAIMode().then(value => {
console.log("Enable the ai mode of the camera: ", value);
}).catch(reason => {
console.log(reason);
});
falcon.getBodyCount().then(value => {
console.log("the people count of the camera: ", value);
}).catch(reason => {
console.log(reason);
});
falcon.close();
##API ###List all Hamedal devices
var Hamedal = require('hamedal-sdk');
var cameras = Hamedal.falcon.devices();
if (cameras.length == 0){
console.log('unable');
}
console.log(cameras);
###Get ai-mode status
falcon.isAIModeEnabled().then(value => {
console.log("The status of the camera mode: ", value ? "enabled" : "disabled");
}).catch(reason => {
console.log(reason);
});
###Set ai-mode enabled OR disabled
falcon.enableAIMode().then(value => {
console.log("Enable the ai mode of the camera: ", value);
}).catch(reason => {
console.log(reason);
});
falcon.disableAIMode().then(value => {
console.log("Disable the ai mode of the camera: ", value);
}).catch(reason => {
console.log(reason);
});
###Get people body count
falcon.getBodyCount().then(value => {
console.log("the people count of the camera: ", value);
}).catch(reason => {
console.log(reason);
});
###Colse the device
falcon.close();