2024-03-02: The wiki ran out of disk space, so things were not working. This has been resolved by adding another 5GB of quota ;-) Thanks to Tim Lindner for reporting the issues. 2020-05-17: If a page gives you an error about some revision not being found, just EDIT the page and the old page should appear in the editor. If it does, just SAVE that and the page should be restored. OS-9 Al (talk) 12:22, 17 May 2020 (CDT)

All in one (Rainbow 1981-09)

From CoCopedia - The Tandy/Radio Shack Color Computer Wiki
Jump to navigation Jump to search
Looking for CoCo help? If you are trying to do something with your old Color Computer, read this quick reference. Want to contribute to this wiki? Be sure to read this first. This CoCo wiki project was started on October 29, 2004. --OS-9 Al

See Recent Changes. | About this site. | Join the E-Mail List or Facebook Group. | Contact me with updates/questions.

This page was last updated on 05/2/2019. Total Pages: 730. Total Files: 993.

Home / Publications / Rainbow / Rainbow 1981 / Rainbow 1981-09 - All in one (Rainbow 1981-09)

More than one program on tape and both of them long?

You want to combine them but really don't want to re-type either?

Oh well, maybe there's something else you can do. After all, it was hard enough writing both of those programs in the first place without having to re-type one of them all over again.

You can combine both programs!
Here's how
First of all, the combined

total of the programs --- plus 300 bytes --- should be less than the memory limit of your computer. If things meet that condition, you CLOAD your first program as usual.

A note here. it is best to have both programs on tape. IF this routine crash, you have not lost anything that way if you write a program and then want to append something else to it, CSAVE the new program first. This procedure will save you a lot of grief just in case.

  • Once you have a program in memory, type PRINT PEEK(25),PEEK (26). The COLOR Computer will give you two numbers. Write these down.
  • Next, type PEEK(28). You will get one number.
  • If that number is 0 (zero) then type POKE 25,Peek(27)-1:POKE 26,254.
  • If that number is 1 then type POKE 23,PEEK(27):POKE 26,255.
  • If that number is more than 1, type POKE 23,PEEK(27):POKE 26,PEEK(28)-2
  • If you try to LIST your program in memory at this stage, you won't get anything. Except for the "PRINT MEM", your computer acts like there is no program in memory.
  • Now, CLOAD the second program.
  • Finally, POKE the two numbers you wrote down at the start into addresses 25 and 26. Both programs will now be resident in the computer at the same time.

One thing. The line numbers will NOT be changed. In other words, line 10 in program #1 will show up as line 10 ... and line 10 in program #2 will ALSO show up as line 10.

For this reason, it is sometimes best to CLOAD the second program first, assigning it high line numbers with RENUM. Then, CSAVE that program, clear memory, and load the first program with the original line numbers intact. After you. go through this procedure, you can RENUM the whole thing (if you have Extended Color Basic) and all the GOTOs, GOSUBs and their lines will be changed correctly. Otherwise, those assignments can be messed up by the RENUM command.

You can CLOAD as many programs onto one tape as you like using this operation. The only constraint is having enough memory to hold everything.

One use of this can be if you, have a whole lot of short programs -- like the graphics examples in the Tandy documentation -- and want to have them in just one program to you don't have to CLOAD back and forth. Just write a short menu after loading a bunch of these programs in and you will have a, graphics display program with a number of options.

We've done this, and its a nice answer to the question from people who ask, "what's this thing do, anyway?"


See this article as it appeared in the magazine, page 17