krontech/chronos-multi-cam-control

Resolve file naming issue. Date is printed as M/DD/YYYY. The Slashes are being recognized as create new Directory

Closed this issue · 3 comments

request += ', "filename": "vid_' + date + '_' + hour + '-' + minute + '-' + second + '_' + camSerial[i] + '"';

Doesn't find this issue with USB and NFS (SD Card?). May only happen in Windows naming system. Will check for that.

image

This is how CinemaDNG files are saved.

"date" is generated by host system (the one that main.html is running on). On Linux, it is "YYYY-MM-DD" while it is "MM/DD/YYYY" on Windows. And "/" is Interpreted as "creating a new folder", so I divided "date" and re-format it, so there is no "/".