date/time format

Support and queries relating to all previous versions of ZoneMinder
Locked
User avatar
tony
Posts: 29
Joined: Mon Dec 29, 2003 8:30 pm

date/time format

Post by tony »

Is there a date/time format variable for tenths of a second?

ie %y = year

Thanks

Tony
User avatar
cordel
Posts: 5210
Joined: Fri Mar 05, 2004 4:47 pm
Location: /USA/Washington/Seattle

Post by cordel »

The best I can do is give you a link to the resources.
http://datetime.perl.org/?Resources

I'll be going through it just because you raised my curiosity. First one to post the answer wins ;)

Cheers,
Corey
User avatar
cordel
Posts: 5210
Joined: Fri Mar 05, 2004 4:47 pm
Location: /USA/Washington/Seattle

Post by cordel »

The info I found here suggests that it is possible.

Regards,
Corey
User avatar
tony
Posts: 29
Joined: Mon Dec 29, 2003 8:30 pm

Post by tony »

looking here:
http://www.gsp.com/cgi-bin/man.cgi?sect ... te::Format
doesn't seem to show a variable for fractions of a second, and I'm not sure what it is on the link you gave that shows it is possible?

Thanks

Tony
User avatar
cordel
Posts: 5210
Joined: Fri Mar 05, 2004 4:47 pm
Location: /USA/Washington/Seattle

Post by cordel »

Opp's
Had my font to small. I thought I seen hh:mm:ss:tt but NOT :roll: I just was not close enough to my screen.
Guess I lose :lol:

Cheers,
Corey
User avatar
zoneminder
Site Admin
Posts: 5215
Joined: Wed Jul 09, 2003 2:07 pm
Location: Bristol, UK
Contact:

Post by zoneminder »

There is no format specifier for this, as the time that is passed into the date functions (and the time in perl, Linux in general) only has 1 second precision. ZM uses some tricks internally to be more precise but it's all a bit of a hack. I may be able to fake fractional seconds but it's not as trivial as just putting in a different format spec I'm afraid.
Phil
User avatar
tony
Posts: 29
Joined: Mon Dec 29, 2003 8:30 pm

Post by tony »

Thanks, someone was asking if zm could be used to find the speed of a vehicle as it passed the camera, I thought of counting the frames but the frame speed seems to build up to the target speed over a short time so the other way i thought of was to count the tenths of a second over a set distance.

Tony
jameswilson
Posts: 5111
Joined: Wed Jun 08, 2005 8:07 pm
Location: Midlands UK

Post by jameswilson »

i think the only way to do this is to have a special motion detector with 2 points that calculates the speed of the target. It would need to be a big targhet mind, ie a zoomed in view. But im afraid i dont know how i just suggested it a few months back.
James Wilson

Disclaimer: The above is pure theory and may work on a good day with the wind behind it. etc etc.
http://www.securitywarehouse.co.uk
User avatar
zoneminder
Site Admin
Posts: 5215
Joined: Wed Jul 09, 2003 2:07 pm
Location: Bristol, UK
Contact:

Post by zoneminder »

The frames are saved in the database with a precision of .01 second, though I'm not sure how this would stand up in legal terms. To view these values just click on one of the frames totals in the events list.
Phil
Locked