Severe Focus Issue with IPC-HFW5231E-Z12

achalmersman

Pulling my weight
Joined
Jan 26, 2017
Messages
267
Reaction score
116
Location
Delaware USA
Hi. I have 4 of these cams pulling LPR duty and only 1 (the newest) is exhibiting this behavior. It totally looses focus for no apparent reason even / especially in the middle of the day. I am attaching some videos that you can fast forward to see when the camera just BAM goes out of focus. I am wondering if it has to do with switching via the Dahua sunrise utility but I have it configured exactly like the other 3. Any help would be appreciated. I have included 2 video clips inside a zip folder. Just drag the video across the timeline quickly you will be able to easily see the focus change points. Thanks, Andrew
 

Attachments

tangent

IPCT Contributor
Joined
May 12, 2016
Messages
4,342
Reaction score
3,524
It's easy enough to test if the Sunrise/Sunset utility is the issue.

What firmware versions are on the different cameras? There was a bug affecting focus that affected some cameras, can't remember if this was one of them.
 
Last edited:

giel

n3wb
Joined
Nov 25, 2017
Messages
28
Reaction score
13
I just got one that has focus issues, too. Autofocus doesn't actually focus properly when zoomed in more than 80%. Halfway zoomed in no issue. Manual adjusting still gives a clear image. Haven't had it running long enough to see if it loses focus. New firmware (201711) seemed to make it a little better, but not even sure.

My workaround will just be figure out the right focus, have a script check every 10s if the value is still the same and if it isn't, set focus. But I'd rather just have autofocus work properly...
 

achalmersman

Pulling my weight
Joined
Jan 26, 2017
Messages
267
Reaction score
116
Location
Delaware USA
What blows my mind is all the posts about these cameras loosing focus. Why can Dahua write in the firmware an option to dissable autofocus if wanted. I would love to be able to just dissable autofocus and let my sunrise utility service take care of the focus.

Sent from my VS990 using Tapatalk
 

giel

n3wb
Joined
Nov 25, 2017
Messages
28
Reaction score
13
What blows my mind is all the posts about these cameras loosing focus. Why can Dahua write in the firmware an option to dissable autofocus if wanted. I would love to be able to just dissable autofocus and let my sunrise utility service take care of the focus.

Sent from my VS990 using Tapatalk
Agreed. @EMPIRETECANDY, if you happen to talk to a Dahua rep, maybe you could ask for an option to disable autofocus as a quick fix for all the focus issues? If nobody asks it definitely won't happen ;)
 

achalmersman

Pulling my weight
Joined
Jan 26, 2017
Messages
267
Reaction score
116
Location
Delaware USA
It's easy enough to test if the Sunrise/Sunset utility is the issue.

What firmware versions are on the different cameras? There was a bug affecting focus that affected some cameras, can't remember if this was one of them.
It isn't the issue. The issue occurs long after or before the sunset utility changes the focus. I have 3 others of the same model not having this problem. Only difference is this one is zoomed much further out
 

jazzy1

Getting the hang of it
Joined
Mar 23, 2015
Messages
300
Reaction score
38
does this issue happen with Z12e as well??
 

achalmersman

Pulling my weight
Joined
Jan 26, 2017
Messages
267
Reaction score
116
Location
Delaware USA
I think so. This may even be the E im not sure. Its been fixed ever since I set a script go keep it in check. Still completely unacceptable.

Sent from my VS990 using Tapatalk
 

jazzy1

Getting the hang of it
Joined
Mar 23, 2015
Messages
300
Reaction score
38
ya...that's lame that this "hack" is needed to make the damn thing work the way it should in the first place
 

djborden

Getting the hang of it
Joined
Jul 19, 2017
Messages
50
Reaction score
25
I have the same issue with my IPC-HFW5231E-Z12. Ive used the same sunrise and sunset utility along with the focus check and set scripts mentioned above, however when the script commands a focus position, it either over shoots or under shoots half the time, so am wondering if the camera is defective?

Andy suggested I post the question to see of others have the same issue, or if the scripts hit the focus point every time for others?

I am using the camera for LPR and at night it misses focus much of the time making the camera unreliable for its intended purpose.

Is there any firmware hack to disable autofocus? Seems like it would be easy to implement. If not, does anyone know how to get into the camera so I can unplug the focus stepper once focus is where I want it? Again, the camera is for LPR so only needs one focus point.

David
 

achalmersman

Pulling my weight
Joined
Jan 26, 2017
Messages
267
Reaction score
116
Location
Delaware USA
Depending on your zoom setting you may actually need different focus settings day vs night due to some optical phenomena that I cant explain but it's been explained here before. I know on 1 of my cams this is the case. That's why it's only in focus at night. My daytimenl video is all blurry.
I have the same issue with my IPC-HFW5231E-Z12. Ive used the same sunrise and sunset utility along with the focus check and set scripts mentioned above, however when the script commands a focus position, it either over shoots or under shoots half the time, so am wondering if the camera is defective?

Andy suggested I post the question to see of others have the same issue, or if the scripts hit the focus point every time for others?

I am using the camera for LPR and at night it misses focus much of the time making the camera unreliable for its intended purpose.

Is there any firmware hack to disable autofocus? Seems like it would be easy to implement. If not, does anyone know how to get into the camera so I can unplug the focus stepper once focus is where I want it? Again, the camera is for LPR so only needs one focus point.

David
Sent from my SM-G965U using Tapatalk
 

bigredfish

Known around here
Joined
Sep 5, 2016
Messages
17,016
Reaction score
47,472
Location
Floriduh
FYI - I use mine for LPR and as long as I keep it in B&W 24/7 it stays focused at about 120ft.... a shame. I dont seem to have a problem with it losing focus on its own though...

HOA Rear_Tag_main_20180612190131_@3.jpgHOA Rear_Tag_main_20180426213318_@3.jpg
 

djborden

Getting the hang of it
Joined
Jul 19, 2017
Messages
50
Reaction score
25
Depending on your zoom setting you may actually need different focus settings day vs night due to some optical phenomena that I cant explain but it's been explained here before. I know on 1 of my cams this is the case. That's why it's only in focus at night. My daytimenl video is all blurry.

Sent from my SM-G965U using Tapatalk
If the camera would accurately take focus commands, then I suspect I could use scripts to compensate for that.

Has anyone tried using the scripts for commanding focus, and if so, do they always hit their mark? Mine is way off about 50% of the time.
 

Rockford622

Getting the hang of it
Joined
Feb 19, 2016
Messages
188
Reaction score
33
If the camera would accurately take focus commands, then I suspect I could use scripts to compensate for that.

Has anyone tried using the scripts for commanding focus, and if so, do they always hit their mark? Mine is way off about 50% of the time.
I wrote a C# windows service that I based on @bp2008 Sunrise/Sunset program, except I have it so it runs every 10 minutes and checks focus and zoom levels on my -Z12 cameras. Yes, if it needs to adjust focus, sending 1 command will get to where it needs to be. I figured out what the correct focus values are for both day and night and compare the current values with those and adjust as necessary.
 

djborden

Getting the hang of it
Joined
Jul 19, 2017
Messages
50
Reaction score
25
I wrote a C# windows service that I based on @bp2008 Sunrise/Sunset program, except I have it so it runs every 10 minutes and checks focus and zoom levels on my -Z12 cameras. Yes, if it needs to adjust focus, sending 1 command will get to where it needs to be. I figured out what the correct focus values are for both day and night and compare the current values with those and adjust as necessary.
Thanks for the reply... Good to hear yours hits focus every time you command it via the service you wrote.

Any chance there are others that have experience with or willing to test if your camera hits focus every time you use a script or service to manual set a focus position on your Dahua -Z12 camera?

David
 

100 td

Young grasshopper
Joined
May 3, 2017
Messages
33
Reaction score
1
Location
Out and about
For noobs that don't do scripts, what's the chance of pulling the camera apart and disconnecting the auto focus motor, either manually setting it, or running a cable out the back (or tap/split spare POE conductors in a network cable to get it back if available/short run) and the sending a manual power feed to manually set it from a distance and leave it set in one spot? If this could work, this could get over the problem that cameras have with other things in the way, in part of the image that are closer than where you want to focus?
 
Last edited:

Matrix1

Young grasshopper
Joined
Nov 6, 2016
Messages
46
Reaction score
2
What video settings are you using for this cam for LPR purposes?
 

guykuo

Getting comfortable
Joined
Jul 7, 2018
Messages
553
Reaction score
1,379
Location
Sammamish, WA
One bug I have noticed on my Z12 used for LPR is that its focus fails if a day or night script is used twice in a row with the same settings. My work around is to also send an explicit autoFocus command after a delay. My python script to set night mode and readjust focus looks like...

import requests
from requests.auth import HTTPDigestAuth

url = 'http://xxx.xxx.xxx.xxx/cgi-bin/configManager.cgi?action=setConfig&VideoInMode[0].Config[0]=1'
requests.get(url, auth=HTTPDigestAuth('username', 'userpassword'))

url = 'http://xxx.xxx.xxx.xxx/cgi-bin/devVideoInput.cgi?action=adjustFocus&focus=0.9134&zoom=0.5150'
requests.get(url, auth=HTTPDigestAuth('username', 'userpassword'))

import time
time.sleep(1)
url = 'http://xxx.xxx.xxx.xxx/cgi-bin/devVideoInput.cgi?action=autoFocus'
requests.get(url, auth=HTTPDigestAuth('username', 'userpassword'))


-------
BTW the reflective road stud idea is fantastic. My Z12 locks right in at the correct distance immediately after putting a reflective road stud near the area of interest.
 
Top