01304 827609 info@use-ip.co.uk Find us

Configuring different camera settings for Day and Night?

Denzy

Member
Messages
16
Points
3
Cameras: DS-2CD2387G2H-LIU
NVR: DS-7604NI-K1 / 4P(B)


Is it correct that there is no way to define separate settings for day and night usage?

AUTO switch removes gain control in exposure settings.
Schedule Switch just uses one global gain setting for day and night.

I would have thought the 'SCENE' settings could be assigned to day and night according.

So basically you can just have a global setting for day and night apart from the control of IR/White Light?

Do newer NVRs offer more customisation - this seems like a silly missing feature by Hikvision.
 
Solution
When logged into the cameras directly you should have the below Image Parameters Switch menu which allows you set when camera switches between different image settings, and you can set those different settings for Day/Night by choosing different Scenes (e.g. Normal, Low Illumination, Custom1, etc...).

Screenshot 2023-12-13 at 10.32.50.png
I tend to use the browser with direct camera access for setup, but view on app/browser/and NVR on TV,HDMI.

(side question to that, whats best practice to make sure camera and NVR settings match)

Is there a general guide for how to setup separate day and night settings?
 
Upvote 0
Okay,

Is the camera plugged into the PoE ports on the NVR? If it is, have you accessed the camera settings directly using Virtual Host?
 
Upvote 0
One camera is on the NVR port the other is on network POE switch.

Accessing the camera via Virtual host or it's IP gives same settings.

If you use AUTO Day/Night switch the gain control under exposure is removed. Regardless the gain control for exposure is global day and night.
 
Upvote 0
When logged into the cameras directly you should have the below Image Parameters Switch menu which allows you set when camera switches between different image settings, and you can set those different settings for Day/Night by choosing different Scenes (e.g. Normal, Low Illumination, Custom1, etc...).

Screenshot 2023-12-13 at 10.32.50.png
 
Upvote 1
Solution
When logged into the cameras directly you should have the below Image Parameters Switch menu which allows you set when camera switches between different image settings, and you can set those different settings for Day/Night by choosing different Scenes (e.g. Normal, Low Illumination, Custom1, etc...).

View attachment 10216
Okay I see now. Thanks!
 
Last edited:
Upvote 0
Yes, the Day/Night setting is only for selecting how the camera switches, if set to DAY it will always stay in Day/colour mode, if set to NIGHT it will always stay in Night/B&W/IR mode, AUTO it will switch when the scene is dark/light enough for it to do so, SCHEDULE SWITCH will switch at a set time.

If you want to set different image settings for Day & Night you need to customise 2 different scenes, one for Day and one for Night, and then set the Image Parameters Switch schedule for when you want the camera to switch between those different scene/image settings.
 
Upvote 0
By the way, when you make changes directly logged into cameras, do you need to reboot the NVR to adopt the settings correctly?
 
Upvote 0
I don't believe so when it relates to image settings.

See if the camera settings have been applied when the switch happens this evening and if not then you might have to reboot.
 
Upvote 0
The scenes setup in the Image Parameters Switch is fairly comprehensive now that you can amend the schedule according to month. Unfortunately there can be a large difference between sunrise/sunset at the start/end of the month. Additionally weather conditions make a huge difference. Ideally you could do with setting up 3 scenes. I've not got around to setting this up with schedules yet. I'd look to setup 3 of the modes:

Normal. For daytime well outside of sunrise and sunset times. Mapped to Day. Gain could be set very low along with noise reduction. Fast exposure time
Low Light. For a least an hour after sunrise, before sunset.
Custom 1. Setup for night time

The Custom 1 (night time) setup could prove awkward. At first thought you'd force it to Night mode so that you can control the gain. However if you have security lighting installed, the camera would stay in monochrome when the area gets floodlit which isn't ideal.

I've been messing around with node-red on a Raspberry Pi. There are palettes for Hikvision which allow you to send the xml to the camera (even when connected to NVR PoE ports). I've been switching scenes with a timer (in node-red without the camera scheduler). Going forward I intend to do the switching using illuminance levels so that weather conditions are accounted for. That requires an illuminance/lux sensor in the same light as the camera (I have these already in use on my Hubitat C-8). It's just a case of observing the levels in real time to get an idea of what lux ranges to match to the modes.
 
Last edited:
Upvote 1
I just don't get why AUTO SWITCH doesn't simply have the option to assign 'scenes'.

I would also have liked 'scene' settings to include bitrate adjustment and framerate to let users get the most optimal settings possible.
 
Upvote 0
I just don't get why AUTO SWITCH doesn't simply have the option to assign 'scenes'.

That would be an improvement but still wouldn't be ideal. Depending on the ambient lighting, the auto and sensitivity settings may result in day during the day and day during the night, even though you may need a different scene selected at night.

Ideally, we should be able to select the scene based on the actual scene illumination level. Maybe Hikvision will add this in future firmware or newer cameras? Maybe the illumination sensor in the camera isn't sensitive enough to support this?

I use the image parameters switch to switch between the "Normal" and "Low Illumination" scenes...

Screenshot 2024-02-13 192824.png

But I really need to add at least 1 more scene for those pesky dawn and dusk hours... even if I did... as @JB1970 points out, weather conditions should be accounted for... so the image parameters switch will never be a great solution.

I've been messing around with node-red on a Raspberry Pi. There are palettes for Hikvision which allow you to send the xml to the camera (even when connected to NVR PoE ports). I've been switching scenes with a timer (in node-red without the camera scheduler). Going forward I intend to do the switching using illuminance levels so that weather conditions are accounted for. That requires an illuminance/lux sensor in the same light as the camera (I have these already in use on my Hubitat C-8). It's just a case of observing the levels in real time to get an idea of what lux ranges to match to the modes.

I've started looking at the node-red software JB mentioned here, and it seems like a good solution...

Screenshot 2024-02-13 202915.png


The "Hikvision Ultimate Text" node is straightforward to use, and I've tested it successfully... it's simple because the only parameter required is the text you want to overlay. The node knows the XML that needs to be sent to the camera.

In order to change the camera scene setting, the generic "Hikvision Ultimate XML" node needs to be used... to use this node you need to know/include the XLM to be sent to the camera to change scenes...

JB, when you have a chance, can you provide the XML needed to change scenes?!?!
 
Upvote 0
Ideally, we should be able to select the scene based on the actual scene illumination level. Maybe Hikvision will add this in future firmware or newer cameras? Maybe the illumination sensor in the camera isn't sensitive enough to support this?
I doubt it'll ever happen. Older and now obsolete Hikvision cameras had an illumination sensor/photocell that would be used to switch the mode between day and night when set to auto switch. I remember a firmware release for those older cameras where the operation changed. Hikvision changed the operation of the mode switch to discontinue using that separate sensor and instead use level from the image (newer cameras don't have the photocell). I guess that's where the issue lies; as the sensor receives less light, the camera automatically increase gain and lowers its electronic shutter speed to maintain the overall exposure and so the image level cannot be used to switch mode, as it's constantly being changed.

The main issue you face could be night rather than low light. On a night I have to use auto day/night switching so that a security light will allow the camera to switch back to colour when the security light is triggered. Day/Night when set to Auto disables the option to adjust image gain and that's one of the parameters that yields results from tweaking.

Here is a flow based on time switching between two modes:

Screenshot 2024-02-14 at 08.49.21.png

The big timer node is based around location and offset from sunrise/sunset in that location. At the point of switching from low light to normal, even with a 90 minute offset the camera image may be darker than desirable. Setting an additional mode switch to cover those transitional times will improve that. That said, it is far more desirable to have a darker image free of noise:

Screenshot 2024-02-14 at 08.49.39.png


The switch node provides a separate on/off output to send the switch messages to the camera:

Screenshot 2024-02-14 at 08.49.57.png


Finally the two Hikvision xml nodes are configured:

Screenshot 2024-02-14 at 08.50.32.png
Screenshot 2024-02-14 at 08.50.56.png


As you can see I'm using the NVR IP address with the virtual host port appended to it (camera 6 in my example). The ISAPI path with channel number will always be the same (channels/1)

Here is the xml snippet (as my image truncates it):

<?xml version="1.0" encoding="UTF-8"?>
<MountingScenario version="2.0" xmlns="http://www.hikvision.com/ver20/XMLSchema">
<mode>lowIllumination</mode>
</MountingScenario>
 
Upvote 0
As you can see I'm using the NVR IP address with the virtual host port appended to it (camera 6 in my example). The ISAPI path with channel number will always be the same (channels/1)

I'm making good progress... I was able to change a camera scenario setting using the NVR IP address with a virtual host port appended to it...

I'm stuck on this though... I'm trying to use the NVR address without the virtual host number appended... that works fine with the text node as there is a channel id in that node that can be set to pick a specific camera on the NVR... but, you cannot select the channel id in the XML node...

I tried changing the path parameter in the XML node from "/ISAPI/Image/Channels/1/mountingScenario/" to "/ISAPI/Image/Channels/8/mountingScenario/" to change camera 8 but that did not work... (using "/ISAPI/Image/Channels/1/mountingScenario/" does not change channel 1 either)...

any ideas?
 
Upvote 0
I'm stuck on this though... I'm trying to use the NVR address without the virtual host number appended... that works fine with the text node as there is a channel id in that node that can be set to pick a specific camera on the NVR... but, you cannot select the channel id in the XML node...

I tried changing the path parameter in the XML node from "/ISAPI/Image/Channels/1/mountingScenario/" to "/ISAPI/Image/Channels/8/mountingScenario/" to change camera 8 but that did not work... (using "/ISAPI/Image/Channels/1/mountingScenario/" does not change channel 1 either)...

any ideas?
You're limited between what the nodes provide and what Hikvision provide via their API.

The Virtual Host port number will be needed to make a change to a camera specific setting where the camera is connected to the PoE ports of an NVR. In this case we're changing the 'Scene'. The Scene can only be changed on the camera directly; you cannot switch Scene either on the local NVR UI or the NVR web UI.

All you need to do is to copy and paste the XML node multiple times, 1 per camera. In each you will 'Add new Hikvision-config' and specify the port to suit the camera. The links you create between the nodes used to switch mode can be one to many:


Screenshot 2024-02-15 at 13.06.22.png
 
Upvote 0
In this case we're changing the 'Scene'. The Scene can only be changed on the camera directly; you cannot switch Scene either on the local NVR UI or the NVR web UI.

Unfortunately, that makes a lot of sense... I was starting to suspect that, and you just confirmed it... :(

All you need to do is to copy and paste the XML node multiple times, 1 per camera. In each you will 'Add new Hikvision-config' and specify the port to suit the camera.

So far, it's working but it's a work in progress...

Screenshot 2024-02-15 083131.png


If I hit one of those inject buttons, the 9 camera scenes change and a text overlay like "SCENE: NIGHT" is updated on each...
 
Upvote 0
Back
Top