Hello John, hello Garth
>My guess would be that there's an interrupt coming at regular intervals. >You're to decrement the counter on each interrupt, and trigger a beep >when it reaches zero.
Okay let's see! The countdown is supposed to go down only once. The Program should end after that.
>Is the interrupt set up for you, or do you have to initialise some >simulated hardware yourself?
We're using an emulator which has the following operation-system-jumps:
ClrScr @ $E000
CrLf @ $E003
WriteChr @ $E006
WriteNib @ $E009
WriteByt @ $E00C
Cursor @ $E012
ReadChr @ $E01E
ReadByt @ $E021
KeyTest @ $E033
Vmodus @ $E015 (switches between Text and Graphics Mode)
Sound @ $E070 (to produce a sound in Hz XREG = Hibyte ,YREG = LOWBYTE)
NoSound @ $E073 (to quit sound)
If you're interested I could mail you the emulator and some progs we've made so far...
>How do you produce the beep? There must be some simulated hardware >to do it. Does writing to a particular location do it, or must you write a >series of zeros and ones at the right frequency?
s.a.
>How is the start time input? Is it entered through a simulated keypad, or >sitting in memory when you start?
via the keyboard of the personal computer
>And are you doing the same course as Pete, a couple of threads >down?
Yes Sir, Pete is my programming-partner
>For decrementing the counter, I'd do something along the lines of
>
>(Some useful Code I hope
)
>
>Pretty simple - read the current value, decrement it. If it is now >negative, set it back to 60 and decrement the next value (so 1:23:00 >goes to 1:22:59)
Sounds very good to me
>Note: there's a deliberate error in that code (and possibly a few >unintentional ones too
so don't try to use it as it is. Work out what's >wrong and fix it.
I'll try
Thank you for your help so far !!!
Dansen