[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

FWD: FWD: Re: Ok, anyone started Contiki 4 AII yet?



On Mon, Mar 17, 2003 at 11:25:28PM -0600, Rob Steinmetz wrote:

> David Wilson wrote:
>

> >In comp.sys.apple2 you write:
> >
> >

> >>Back to the original issue. There is no CLK_TCK function in the Apple
> >>Library for cc65.
> >>
> >>

> >
> >
> >

> >>	1)Is the CLK_TCK function necessary?
> >>
> >>

> >
> >CLK_TCK would be 60 on most Apple // systems.
> >
> >
> >

> >>	2)What is it used for?
> >>
> >>

> >
> >It is so you can scale the value of functions that count in ticks.
> >
> >
> >

> >>	3)Is it something which can be generated on a stock Apple ][?
> >>
> >>

> >
> >You would need to add a source of interrupts (eg Mouse II card) and set
> >up an IRQ handler to count VBL pulses.
> >
> >
> >

> >>IIRC the Apple ][ generates its timing in an unusual and Woz way,
> >>without a crystal. Can CLK_TCK be generated in the same way?
> >>
> >>

> >
> >The Apple II does have a crystal - 14.31818 MHz if I recall it correctly. > >It is the CPU clock that is more complicated with its stretched cycle 1 in
> >65.
> >
> >

> Thanks for the information. This did not make it to comp.sys.apple2. Do
> you mind if I post it there?


Sure. I must have hit reply instead of followup.

On my MPF-III (a //e clone) I added a flip flop so that it could generate
IRQ everytime the screen got to VBL - I used it to run a software clock for
ProDOS before I built myself a hardware battery backed clock. The only problem is that the 5.25" driver disables IRQ for long periods so your clock gradually
looses time. Here in  Australia our power is 50Hz rather than 60Hz so that
would change the code required to count ticks slightly.
-- David Wilson School of IT & CS, Uni of Wollongong, Australia