Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!usc!apple!voder!pyramid!ctnews!mitisft!dold From: dold@mitisft.Convergent.COM (Clarence Dold) Newsgroups: comp.sys.3b1 Subject: Re: nbs_time Message-ID: <2094@mitisft.Convergent.COM> Date: 18 May 91 19:10:09 GMT References: <4111@jethro.Corp.Sun.COM> Organization: Convergent Technologies, San Jose, CA Lines: 25 in article <4111@jethro.Corp.Sun.COM>, gak@gakbox.Corp.Sun.COM (Richard Stueven) says: ... some source code ... > * NAME: nbs_time - set system clock to National Bureau of Standards Time. ... > tm = localtime(&cur_time); /* convert time to local time */ ... > (void)syslocal(SYSL_WRTRTC, &rtc); /* write to RTC */ To make this run on the Convergent 'S/Series' CTIX, change localtime() to gmtime(), and WRTRC to WRTC. I also point my SIGALARM at disc_nbs, but that is trivial. The check_tz routine needs to be different, although if $TZ is set, it doesn't matter. I also have a routine to write the RTC on the Convergent SPC / Unisys U6000 (low end), which I might post soon as part of my net-synchronization routine for non-ntp sites. -- --- Clarence A Dold - dold@tsmiti.Convergent.COM ...pyramid!ctnews!tsmiti!dold