[Coco] Set clock in basic09

George Ramsower georgera at gvtc.com
Tue Dec 2 20:50:53 EST 2014


On 12/2/2014 9:19 AM, Robert Gault wrote:
> George Ramsower wrote:
>>  I don't know how to use "Setclk" from a basic program.
>>   Is this clear as mud?
>>
>
> The SmartWatch (c) is a Dallas DS1215 or DS1216 mounted in a 16-pin 
> socket which you typically place in the disk controller and then mount 
> the disk ROM in the SmartWatch socket.
> If that is what you have, I can send you two commands for OS-9 that 
> one reads the watch at selected intervals and two sets the clock. It 
> makes more sense to use clock2_soft and then read the watch at say 5 
> minute intervals than to constantly read the watch. The overhead is 
> significantly reduced.
>
> Robert
>
  Okay, I am using "Setclk" and "Getclk".
  Also, the getclk is used in a background task. The source code is in 
another coco with a hard drive but right now, that system is broken so, 
I can't look up what I did many years ago. On the 'puter I intend to 
use, the routine to set the coco's clock(OS9) is running as a background 
task with a priority of 10, which makes it as a last resort but it keeps 
the coco on time, using the Smartwatch.
  I remember I fooled around with a basic routine to set that smartwatch 
but never got it working. It's been so long, I don't remember what I 
have tried without success.
  Basically, the smartwatch was gaining or losing time(don't remember 
which right now). I intended to set a background task to set the 
smartwatch at specific intervals to keep the system accurate enough 
where I would only need to check it maybe once a week.
  Years ago, I built a board for that coco that has 4, eight bit inputs 
and 4,eight bit output latches for various uses and now I want to 
monitor my old mechanical clocks so I won't have to do this by hand as I 
do now. I'm lazy.
  I am going to set that smartwatch now and check it tomorrow to see 
what it is doing.
  Clock is set now and I looked to see what is running in the background 
to run "Getclk". It's a Basic09 program and the source is in the broken 
'puter. Darnit!!

George R.



More information about the Coco mailing list