Closed MegaPramuk closed 4 years ago
Currently the filename is the system ticks since boot. To get absolute timestamps or date time I would need to utilize one of the time:* services on the switch and there is a shortage of those.
I might actually have a workaround for that without requesting a time session. FS will tell me when the file was created. I'll just rename it for that.
With that it renames it to the posix timestamp of creation. https://github.com/HookedBehemoth/bitmap-printer/commit/2141b1e99ce59ffb5d86b58ed6ca8226a41321be
I don't see a way to reliably convert that to the proposed datetime string since I don't know the timezone.
And with that https://github.com/HookedBehemoth/bitmap-printer/commit/298aa5d189b759bcafddfa7cd0517d4fc35ca59f we have date strings :tada:
Awesome! That was faster than I had expected. I'm closing this issue then. Cheers!
It would be great if instead of (what I assume to be) epoch time as filenames, a proper timestamp would be better. As of now, the files aren't being properly sorted by name. I propose the format to be
YYYY-MM-DD_hh-mm-ss.ms
(so files won't be overwritten in case of pressing the capture button repeatedly).