Hello, I am trying to set up an el-cheapo attendance system that only calculates how late the person has come with reference to a fixed office time. I don't want to use any database+server thing as that is complex and users are less than 20. I am thinking of a simple approach with cheap and simple biometrics to prevent impersonation. A cheap web cam will click light thumbnails and a timestamp will be generated. Every month a file will be generated after which the photos can be erased automatically. The result file will be a .csv one that can be imported in any Office application.
I am stuck at the point of calculating time difference. There doesn't seem to be a direct command that will calculate time difference in HH:MM format. This link mentions a work around http://www.cyberciti.biz/faq/shell-script-to-get-the-time-difference/ but it first converts time into %s which is the number of seconds since 1970. However every day for the fixed opening time, say 10:00 this figure is not constant. One way out is that every day the %s figure is generated at exactly 10:00 and this is then 'diff'ed with the user's attendance time in %s. This is then divided by 60. Is there a simpler bash command that I may have overlooked that simply takes in 10:17 and 10:00 and says 00:17? -- As a proper list etiquette..... Please trim your replies. Avoid cross posting to other lists. Members do not want to waste time answering same queries that may have been answered on other lists. Replies from other lists, to cross posted mails are not available to our members. Post your replies below the relevant original text, leaving a line space. Do not re-use old messages to write new ones. For new messages, create a new message. Regards, Rony. -- http://mm.glug-bom.org/mailman/listinfo/linuxers

