Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Video Timestamp Issue #2

Open
dusky519 opened this issue Aug 4, 2016 · 1 comment
Open

Video Timestamp Issue #2

dusky519 opened this issue Aug 4, 2016 · 1 comment

Comments

@dusky519
Copy link

dusky519 commented Aug 4, 2016

The readable timestamp conversion fails on some video entries. Tested with an S6 android 5.1.1. The timestamps for videos are stored the same as the image entries. There are no extra zeros at the end of the time stamp. Instead of dividing by 1000 to eliminate the extra numbers, why not take a substring of the variable "timestring". This way the "if" statement is removed completely. (No need to check for difference between video and pictures)

suggested code would be

timestring = datetime.datetime.utcfromtimestamp(int(timestamp[0:10])).strftime("%Y-%m-%dT%H-%M-%S)

replace if statement with that code. Tested and works great!

@cheeky4n6monkey
Copy link
Owner

cheeky4n6monkey commented Aug 5, 2016

Hi dusky519,

Thankyou for sharing your S6 testing observations / sample code for "imgcache-parse.py" (assuming its the UTF16LE Timestamp version).
While your solution looks good to me, it would also require redoing all my recent validation testing with multiple test devices and then test it with some S6 data. Unfortunately, I don't have the time to do this at the moment.
Instead, I will post your Github comments in the comments section of my blog post [ http://cheeky4n6monkey.blogspot.com/2016/07/a-timestamp-seeking-monkey-dives-into.html ] so others can make this change to the code should they need to.
I will also keep this issue open to document your suggestion.

Thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants