Jump to content
IGNORED

IntyBASIC VOICE commands/options


Recommended Posts

I'm starting to go through the second book after going through the first one for the second time to remember what I learned 2 years ago and thought of ways I could use the Intellivoice to try to record samples for my podcast.

 

I remember seeing examples of how to use VOICE but I've not found where there is a full set of commands/options for it.  Is there such a document and is there tutorial/lesson-like examples that I could go through?

 

Thanks.

Link to comment
Share on other sites

You have the following in manual.txt:

 

Allowed phrases are:


    
        PA5, PA4, PA3, PA2, PA1
        MATTEL, ZERO, ONE, TWO, THREE, FOUR, FIVE, SIX, SEVEN, EIGHT, NINE
        TEN, ELEVEN, TWELVE, THIRTEEN, FOURTEEN, FIFTEEN, SIXTEEN, SEVENTEEN
        EIGHTEEN, NINETEEN, TWENTY, THIRTY, FOURTY, FIFTY, SIXTY, SEVENTY
        EIGHTY, NINETY, HUNDRED, THOUSAND, TEEN, TY, PRESS, ENTER, OR, AND
        AA, AE1, AO, AR, AW, AX, AY, BB1, BB2, CH, DD1, DD2, DH1, DH2, EH,
        EL, ER1, ER2, EY, FF, GG1, GG2, GG3, HH1, HH2, IH, IY, JH, KK1,
        KK2, KK3, LL, MM, NG1, NN1, NN2, OR2, OW, OY, PP, RR1, RR2, SH, SS
        TH, TT1, TT2, UH, UW1, UW2, VV, WH, WW, XR2, YR, YY1, YY2, ZH, ZZ

 

There is additional info in the directory jzintv/doc/voice (i.e. where your emulator is installed). Most of that info is intended for assembly language but good parts of it should apply to IntyBASIC too.

Link to comment
Share on other sites

The IntyBASIC manual is replicated in my first book "Programming Games for Intellivision" and it contains all the VOICE commands.

 

Basically you only need to do VOICE INIT at the start of your program.

 

"VOICE PLAY voice_label" when you want to play a voice.

 

And voice_label should look like this:

 

voice_label: VOICE WW, AR, NN1,NN1,IH, NG1, PA4, 0

 

Link to comment
Share on other sites

Thanks to both of you.

 

I thought I saw it in the second book so when I went to look into it again and couldn't find it I was confused.

 

I did find it in the first book. I'll probably print off those pages so I have them as reference.

  • Like 1
Link to comment
Share on other sites

Here's another related question.  Is there a way to change the voice?  Like to a more feminine one as in "Hello Commander. Computer reporting."

 

Or is that from custom samples that's part of the game for access and not part of default?

Link to comment
Share on other sites

2 hours ago, llaffer said:

Here's another related question.  Is there a way to change the voice?  Like to a more feminine one as in "Hello Commander. Computer reporting."

 

Or is that from custom samples that's part of the game for access and not part of default?

The custom samples are a trick of voice chip programming that was only available to Mattel programmers because it required a dedicated minicomputer to generate them.

 

This is one of the reasons that I've included an appendix in my 2nd book about generating digitized voice using only the sound chip on the Intellivision.

 

Edited by nanochess
Link to comment
Share on other sites

On 5/3/2021 at 5:31 PM, nanochess said:

This is one of the reasons that I've included an appendix in my 2nd book about generating digitized voice using only the sound chip on the Intellivision.

 

I tried to use this WAV converter tool.  I created the .bas file from the .wav, typed up wave_helper.asm, then tried to build and run the program to see if it works.  No errors or warnings on the build/compile, but when it starts jzIntv, I see:


Starting jzIntv...

HALT!

PC: $7000   Instr count: 2   Cycles: 13

 

And the display shows a magenta color and nothing happens, though the emulator continues to run until I end it with F1.

 

Thoughts on what I should look for?  Thanks.

Link to comment
Share on other sites

39 minutes ago, llaffer said:

I tried to use this WAV converter tool.  I created the .bas file from the .wav, typed up wave_helper.asm, then tried to build and run the program to see if it works.  No errors or warnings on the build/compile, but when it starts jzIntv, I see:

 


Starting jzIntv...

HALT!

PC: $7000   Instr count: 2   Cycles: 13

 

 

And the display shows a magenta color and nothing happens, though the emulator continues to run until I end it with F1.

 

Thoughts on what I should look for?  Thanks.

The wave files consume great quantities of space on ROM. As the program handles 16-bit 8khz, and two samples are converted into a word, technically the maximum size of a WAV file should be 32K.

 

I suggest using ASM ORG $C100 just before your wave data.

 

 

Link to comment
Share on other sites

Thanks.  The file I'm testing is 4 seconds long so is double that size.  I'll try your command and if it doesn't work I'll see if I can break it up into two smaller pieces played one after another.

 

What does the ASM ORG command do?  I've seen it in the book a few times and you mentioned it was due to memory limitations but I didn't understand how that solved the limitation.

 

EDIT:   Looks like it doesn't like it being split into two data sets, I suppose it's still got all that data in there and it's not enough to fit.  I'll try the tests with a smaller audio.

 

Edited by llaffer
Link to comment
Share on other sites

4 hours ago, llaffer said:

What does the ASM ORG command do?  I've seen it in the book a few times and you mentioned it was due to memory limitations but I didn't understand how that solved the limitation.

 

Give a look to the page 173 of my book Programming Games for Intellivision.

 

Also you can search for "ASM ORG" in the file manual.txt included with the IntyBASIC distribution.

 

Another option is to give a look to the included example program 42K.BAS

Edited by nanochess
Link to comment
Share on other sites

The program now runs without crashing or throwing errors, but I still don't hear anything.  So I'm wondering if I may not have the settings of my audio file correct.  Here's what I did. Please let me know if I have to adjust something.

 

In Audacity, I loaded up my file that is less than 2 seconds in duration and ensure it's a single track.

I changed the Project Rate (Hz) value in the lower-left corner to 8000.

Set Recording Channels to 1 (Mono)

In the menu: File->Export->Export as WAV

Save as type: WAV (Microsoft)

Encoding: Signed 16-bit PCM

 

But I get a file that's twice the size that I'd expet (29,616 bytes vs. 14,808 bytes for a 1.851s audio at 8000 Hz.

 

I've tried other Encoding settings (U-law, A-law, etc.) and that gives an "Exceeded range!" message when it tries to write the second pair of data points.  It says the size is 72984 which also seems larger for a file that is less than 30,000 bytes.

 

When the file processes without error with the Signed 16-bit PCM encoding, the size used is 7402.

 

Which settings do you use when saving your audio to be encoded by this process?

 

Thanks.

 

Link to comment
Share on other sites

The utility uses Signed 16-bit PCM encoding, monoaural.

 

Probably it already is sounding but you need to turn up the volume of your computer to the max.

 

Use the Audacity, Effect-Amplify option to increase the volume of your wave sample.

 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...