Classic Computer Magazine Archive ANTIC VOL. 2, NO. 8 / NOVEMBER 1983


Software voice without screen blanking


This article, along with sample program listings, will show you how to use S.A.M. with the lights on and how to display text in Graphics Modes 6 or 22.

Software Automatic Mouth (S.A.M.) is a product of Don't Ask Software. S.A.M. uses ATARI's sound capability to create speech through software only. You can put speech into your own programs for $59.95. You can also purchase programs that have S.A.M. built into them.

I was one of the first to purchase S.A.M., and I used him in a commercial product called PokerSAM. Since PokerSAM has been on the market, I have had many people tell me that they enjoyed the strange personality of their poker playing opponent. The vocal commentary is what makes the game fun. But many also commented disparagingly about the blanking of the screen when S.A.M. speaks. Although it didn't bother me, it does bother some people.

I discussed this problem with Bob Freedman and Randy Simon of Don't Ask, and found out why it was necessary to disable interrupts and blank the screen. S.A.M. tends to growl when the screen is on because he does not like to be interrupted. The ATARI computer's sophisticated display and interrupt system causes the machine cycles to be stolen from the 6502 microprocessor and S.A.M. wants the 6502 all to himself.

When the folks at Don't Ask contacted me about writing a spelling game using S.A.M., I thought it was a great idea. After all, how could you ask someone to spell a word without using speech! You certainly can't put a word on the screen and then ask someone to spell it. S.A.M. is perfect for the job, or almost perfect; there was still that problem of the blank screen during speech.

By the time you read this article, Chatterbee (the spelling game) will have proved that S.A.M. does not have to turn out the lights when he speaks. I'm sure that many S.A.M. users will want to learn how to do this in their own programs. My thanks to the folks at Don't Ask for their permission to publish this technique, and to Bob Freedman for the contribution of his Mode 6 display subroutine.

To make S.A.M. speak with the lights on we must give him a few POKEs in the side so that he won't growl, make maximum use of Player/Missile graphics, and limit our display list to low and medium resolution mode lines. The following POKEs tell S.A.M. to leave the lights on:

POKE 8550,234:POKE 8551,234:POKE 8552,234

To experiment with S.A.M's speed, POKE values between 40 and 100 into location 8208. To experiment with S.A.M's pitch, POKE values between 30 and 90 into location 8209.

In Chatterbee I also played with what is known as S.A.M's waveform. I POKEd 14 into location 8554, 13 into location 8559, and 10 into location 8564. You will find a little trial and error with these locations can create some very interesting results. You can make S.A.M. sound like anything from a growling monster to E.T.

To those S.A.M. owners who would like to learn more about using S.A.M., I highly recommend Educational Software's Tricky Tutorial #12.

Player/Missile graphics don't seem to bother S.A.M. at all, so use them as much as possible for your graphics and animation.

Your playfield display must avoid any text mode lines or text windows. You should keep your display list as short as possible. To display text, draw letters on the screen as shown in the BASIC DRAWTEXT program.

The reason you cannot use text modes is that the Operating System has to do a great deal more work during the creation of the display if text is to be displayed. For every character space, the OS must fetch eight bytes of information, whether or not a character is visible. Similarly, if you use high-resolution or four-color graphics mode, the display takes many more machine cycles to create. Even though you aren't aware of the extra time involved, S.A.M. requires every cycle he can get, and is slowed down to a growl if he doesn't get his way.

DRAWTEXT will check to see if you booted with a S.A.M. diskette. If so, he will announce each upper-case letter that you type. If you don't have S.A.M. in RAM, the program will only display letters.

Let us know if you come up with any interesting applications for S.A.M. or improvements in display methods or voice quality.

Jerry White is Technical Consultant and regular contributor to ANTIC. His progrnms are available from several software companies, notably Adventure International and Educational Software.

Listing1:DRAWTEXT.BAS Download

Listing2:DRAWTEXT.ASM Download / View