Node package for automating Dahua ™️ camera initialization
This package provides an automatic way to initialize Dahua ™️ cameras via Puppeteer.
Usage
Installation
npm i dahua_initilizer
Usage
const dahuaInitializer =
dahuaInitializer
Option parameter
screenshots: default false
path: default ''
(if !screenshots the field is ignored)
headless: default true
camera_config parameter
The camera_config field is a json object of the following form:
Camera initialization usually has various configuration screens:
ip defaults to 192.168.1.108 and port to 80.
Screen object is an array of actions:
action: Will be performed sequentially. (Note! Before any forwarding to the next dialog complete all your actions.)
- click: Simulate a mouse click event on the element
- fill: This action expects text field. (Note! Generally, input element need to be clicked before filling.)
- keypress: This action expects key field. At the present we only support Enter. (See Puppeteer docs. If you want to extend it 😉)
- delay: This action expects time field. Some fields need some time after the action is performed, for example the time synchronization. (time in ms).
### Example Complete example of camera_config for camera model: