This is another example using BASLOAD. Tokenized version is in the runnable PRG file.
This example shows an approach for setting up a kind of "rate monotonic" event scheduler in BASIC. And specifically it is setup to play some music notes in the background while doing other things (from within BASIC, no POKE's needed).
The overall framework could be used to do many other more interesting things.
Try It Now!
Sample outline of rate groups in BASIC
Re: Sample outline of rate groups in BASIC
Here is an updated version of this sample. It was only called TTIME earlier because I had planned to do something else and it just then morphed into this rate-group concept.
This updated version (now called RATEV2.BAS) will require the newer (upcoming) BASLOAD-0.2.3
You can still run the PRG now if you'd like, since it is the "compiled output" (or tokenized) result of BASLOAD.
Functionally there isn't much difference. The main differences are:
- addresses a "time roll over" bug, which could cause a bit of a stutter for a moment after running for a while.
- minor re-arrangement and expanded comments/clarifications on some things
- exercise the "RESTORE <label>" to play a couple different DATA-as-music options
This updated version (now called RATEV2.BAS) will require the newer (upcoming) BASLOAD-0.2.3
You can still run the PRG now if you'd like, since it is the "compiled output" (or tokenized) result of BASLOAD.
Functionally there isn't much difference. The main differences are:
- addresses a "time roll over" bug, which could cause a bit of a stutter for a moment after running for a while.
- minor re-arrangement and expanded comments/clarifications on some things
- exercise the "RESTORE <label>" to play a couple different DATA-as-music options
- Attachments
-
- RATEV2.PRG
- (3.1 KiB) Downloaded 241 times
-
- RATEV2.BAS
- (3.84 KiB) Downloaded 222 times