I was today year’s old when I realized the CoCo’s high-resolution color values actually make sense.
Let me just get this right out in the open…
“I feel dumb I never realized the PMODE colors in the manual were correct.”
– Allen
You all probably knew this. If I did, I forgot I knew it. And I really don’t think I ever knew it. Because dumb.
My first CoCo was a grey TRS-80 Color Computer that I got around 1984. Today we call it a “CoCo 1” but back then it was the only CoCo.
The CoCo had eight colors (nine if you count black) that it could display:
The colors are listed as:
- 0 – Black
- 1- Green
- 2 – Yellow
- 3 – Blue
- 4 – Red
- 5 – Buff (I always called it white)
- 6 – Cyan
- 7 – Magenta
- 8 – Orange
When you use the high resolution graphics (PMODEs), you have a choice of a higher high-resolution with 2 colors, or lower high-resolution with 4 colors. Each of these modes has two color sets, which select which 4 or 2 colors you can use on the screen. Here is how the Extended Color BASIC manual describe the PMODEs:
There are some high resolution graphics commands that let you specify a color — such as the COLOR, CIRCLE and DRAW — let you specify a color value to use. I found it odd that the color value was listed as “0-8” — as if you could use nine colors on a high resolution screen. You can’t! Only four, or two.
But the manual listed nine colors, anyway:
The first dumb thing I never realized until today was those high-resolution color numbers are the same as the ones for the text screen, as used by text commands CLS and SET. As I previously wrote about, I also did not realize that the colors available on the high resolution screens were actually the same as the ones on the text screen. I’d never seen them at the same time, and they always “looked different” to me.
But why did Microsoft let you specify color values 0-8 for a screen that can only have four colors? When I started playing with the CoCo again as a grown-up, I assumed Extended Color BASIC must have been ported from a system with more colors and they just left it as-is.
But the manual was weird about it. For example, it would tell you use use colors 5, 6, 7 and 8!
“If you want to try changing the dots’ colors, use buff (5), cyan (6), or magenta (7). Then change the color back to orange (8) before proceeding…”
– Extended Color BASIC manual, page 86
But I knew back then that this was just silly. If you used colors 1, 2, 3 and 4 in one mode, you could also use colors 1, 2, 3 and 4 in the other color set. You’d get the four unique colors in each mode, just different colors based on the mode. (Or you could use 0, 1, 2 and 3 just shifting the order over.)
The important part of the manual was listing which four colors you got when you used SCREEN to specify the color set to use:
SCREEN 1,0 gave you the green/yellow/blue/red colors on a green screen with green border, and SCREEN 1,1 gave you the buff/cyan/magenta/orange colors on a buff screen with a buff border.
Then, there were the higher high-resolution modes that only had two colors. The manual mentioned them (and the four color modes) later:
I guess they were introducing things slowly as you progressed through the chapters.
In a 2-color mode, SCREEN 1,0 gives you a green border with black background and you can draw in green. SCREEN 1,1 gives you a black screen with a white background and you can draw in white.
And my mind was blown when I realized that, though you could use 1-4 on any 4-color screen, or 1-2 on any 2-color screen, and get different colors, the way the manual tried to teach us was basically: “In this mode, use colors A to B. In that mode, use colors C to D” and so on.
Behold! PMODE 3,1:SCREEN 1,0 5-color mode showing what it draws for all 9 colors (0-8):
If you use the color chart, you can see you should be using colors 1-4:
- 1- Green
- 2 – Yellow
- 3 – Blue
- 4 – Red
If you go to PMODE 3,1:SCREEN 1,1 you get these colors:
And here is why the manual told you to use colors 5-8:
- 5 – Buff
- 6 – Cyan
- 7 – Magenta
- 8 – Orange
And in the 2-color mode, if you went PMODE 4,1:SCREEN 1,0 you would get the same two colors repeated over and over:
And that corresponds to using colors 0 and 1 in the chart:
- 0 – Black
- 1- Green
And PMODE 4,1:SCREEN 1,1 looks like this:
Here, you would want to use colors 0 and 5:
- 0 – Black
- 5 – Buff
I don’t know if ANY of us ever programmed using the numbers like that — mostly because the manual really did not make it clear which colors were part of which mode. You’d need a fancier chart that showed what you could do, like:
PMODE | SCREEN | 0 Black | 1 Green | 2 Yellow | 3 Blue | 4 Red | 5 Buff | 6 Cyan | 7 Magenta | 8 Orange |
0 or 2 | 0 | X | X | |||||||
0 or 2 | 1 | X | X | |||||||
1 or 3 | 0 | X | X | X | X | |||||
1 or 3 | 1 | X | X | X | X |
I would have needed to keep this chart nearby for reference until I memorized it.
What color values did you learn to use when you learned Extended Color BASIC? Leave a comment and let me know.
Until next time…
Bonus Code
Here’s my sample program.
0 'COLORS.BAS
10 PMODE 3,1:PCLS:SCREEN 1,0
20 GOSUB 500
30 PMODE 3,1:PCLS:SCREEN 1,1
40 GOSUB 500
50 PMODE 4,1:PCLS:SCREEN 1,0
60 GOSUB 500
70 PMODE 4,1:PCLS:SCREEN 1,1
80 GOSUB 500
499 END
500 ' SHOW COLORS
505 DRAW"BM10,3 D8R8U8NL8 BR20 ND8 BR28 R8D4L8D4R8 BR20 R8U4NL8U4NL8 BR20 D4R8NU4D4 BR20 R8U4L8U4R8 BR20 NR8D8R8U4NL8BU4 BR20 R8D8 BR20 R8U8L8D4R8"
510 FOR C=0 TO 8
520 COLOR C
530 LINE (C*28,16)-(C*28+27,191),PSET,BF
540 NEXT
550 IF INKEY$="" THEN 550
560 RETURN