Actually, the issue came up after I wrote a script to set the date via the \"daytime\" service. (ntp is more accurate, but involves more overhead, so I decided daytime was sufficient for me.)
This is the script:
# cat /usr/local/bin/settime
echo \"Time was: `date`\"
if [[ $1 ]]; then
u=$1
else
u=\"time-b.timefreq.bldrdoc.gov\"
fi
echo \"Setting time by $u\"
t=`telnet $u 13`
#echo $?
echo \"$t\"
ss=${t:10:2}${t:13:2}${t:16:2}${t:19:2}20${t:7:2}.${t:22:2}
echo \"Zaurus \'date\' set command ignores seconds\"
echo \"Time set to: `sudo date -u $ss`\"
echo \"Local time : `date`\"
#echo $ss
echo \"Taskbar time may not immediately update.\"
I could write the script to sleep until the seconds were zero, but to accurately deal with carries in the date/time (59-]00), I\'d either have to do a lot of calculation, or -- more simply -- telnet the daytime again. The other problem is that the sleeping could take up to 59 seconds, which would make it problematic to use this script as part of an .rc, especially as the script -- why, I don\'t know -- doesn\'t work if run in the background.
I was hoping to avoid such kludges by finding a way to set the seconds.