Re: Text to Speech

206 views
Skip to first unread message
Message has been deleted

Charley Jones

unread,
Aug 5, 2024, 4:25:50 PMAug 5
to John Galt, Altair-Duino
Great Job!

Sent from my iPhone 15pm!
Charley Jones, PMP

On Aug 5, 2024, at 11:20 AM, John Galt <furba...@gmail.com> wrote:

I've been writing a Text to speech program for the SP0256 for the Altair I/O Bus card.
I basically finished most of it and it works. it does not use a dictionary look up.


I used the:

Naval Research Laboratory text-to-phoneme algorithm, described by Elovitz et al. (1976).

for the rules set.

I wrote it all in MBASIC 5.21

I find it odd that there is only one modern PERL version of the Naval rules.
there are tons of Phoneme to Text programs that take the already converted text to phoneme and then just output to the synth but no direct text to speech.

the program is a absolute monster and i had to basically make overlays for each letter because the rules are so extensive.

i have some more work to do in reading and converting a text file to speech.

right now you can enter a word or sentence up to the basic input limit more like 250 characters and it will convert it then automatically play it back. the most recent text to speech is stored in a temp file to make it easy to copy and paste into a program you want to add speech too. it makes no sense to try to make an application with speech conversion on the fly as the memory requirements far exceed 64kb. 

basically i made a CTS256-al2 emulator which is designed to work with the SP0256

there is an online convertor by greg kennedy and that uses a perl script he made.
https://greg-kennedy.com/sp0256-tts/

my version will work on the Altair under Cp/M with full 64kb memory and compiled basic.  you will also want a harddrive. It will work off a 330kb floppy, takes up about 150KB but if your converting big files you may run out of disk space, also it is much slower as it has to load all the overlays from floppy.

more work to be done. its very alpha and I'm sure has bugs in it.

the readsay application will read phoneme text file and output to the synth.

for now i can run sentences off the parser and put them in a larger file for
readsay to output.



--
You received this message because you are subscribed to the Google Groups "Altair-Duino" group.
To unsubscribe from this group and stop receiving emails from it, send an email to altair-duino...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/altair-duino/bf4917ab-e57e-43ec-892e-0b32c4bfbf75n%40googlegroups.com.

Tom Lake

unread,
Aug 5, 2024, 6:48:54 PMAug 5
to Altair-Duino
Here's a program for the TRS-80 which speaks any text you type on the TRS-80 Voice Synthesizer. Of course, our synthesizer is different, but this will at least give a good example of
converting text to phonemes.


VOICE2.BAS
Message has been deleted
Message has been deleted
Message has been deleted

Michel Bernard

unread,
Aug 14, 2024, 7:57:35 AMAug 14
to John Galt, Altair-Duino
To who may be interested: I just committed a Z-80 port of the CTS256A-AL2.

Binaries included as well as the extractes CTS rules in RULES.TXT …


Michel Bernard

Sent from my iPhone

Le 6 août 2024 à 04:27, John Galt <furba...@gmail.com> a écrit :

I updated modules I, E, L.

There are a lot of transcription mistakes in the Naval manual. i found some new information and made some changes.
words like Fiddle and Georgia now sound better.


--
You received this message because you are subscribed to the Google Groups "Altair-Duino" group.
To unsubscribe from this group and stop receiving emails from it, send an email to altair-duino...@googlegroups.com.

Walt Perko

unread,
Aug 14, 2024, 10:33:30 AMAug 14
to Altair-Duino

Hi,

 Speech and Singing on an Altair computer: 

 The Saga of WATT & HU ... Altair 8800c v. Altair-Duino Pro     https://youtu.be/0qPOyqm0jUQ

 Talking 'n Singing 'n Musical Stepper Motors from an Altair 8800 Computer  20211225

https://www.youtube.com/watch?v=BDaBaBL1mws&ab_channel=WaltPerko


.
Message has been deleted

Charley Jones

unread,
Aug 25, 2024, 3:22:21 AMAug 25
to John Galt, Altair-Duino
Nice work, I used to play with a speech chip on Atari 800. With a name like Charley Jones, I had to learn phonemes quickly.

Sent from my iPhone 15pm!
Charley Jones, PMP

On Aug 24, 2024, at 1:38 PM, John Galt <furba...@gmail.com> wrote:

Walt a little heads up..

I'm playing around with the speakjet your demo code had issues with phonics dropping out.
in researching it i found the issue.

the smaller Speakjet board going around a few years ago with the Serial connection do not support CTS. CTS is the hardware handshake.
the
code you have to check the Status bit when talking to the speakjet therefore does nothing.
this is why long phonic strings start to skip and break down.
the speakjet as an internal 64 character buffer, this quickly overruns when your converting even small words.

since there is no hardware handshake you have to program in your own delay routines.

thankfully Speakjet includes the Milliseconds each speech piece requires example the robot noises are 80ms as noted int the manual

what you do for the output routine is make a For Next loop where you count from 0 to the MS delay required
for i=0 to 80: next 80 would cover the 80ms needed.
this method will slow the Speakjet down preventing sound overlap and keeping the buffer from overflowing.
this would be the job of the status bit (CTS) but pin 15 on the speakjet is CTS and it is not used in many of the speakjet simple pcbs that came out a few years ago.
there are more elaborate Speakjet pcbs with the TTS processor and full serial support these support CTS and your IF THEN routine would work.

you can see this in action for yourself. run short lines of phonics and listen to how the speakjet handles them

then send a monster long string of phonics and listen as soon as you hit 64 characters with the buffer not fast enough to clear out then all the speech starts to skip and breakdown until the buffer cleans and it can catch up
until it overflows again.. CTS would handle this but its not existant in the format being used.


i'm working on a Text to speech on the fly for the Speakjet now that the Sp0256 is basically done. hope to post a large update soon to my github.

Walt Perko

unread,
Aug 25, 2024, 10:59:00 AMAug 25
to Altair-Duino

Hi,

 I don’t have any problem with using my little SpeechBoxes on my Altair 8800c or my IMSAI-JAIR computers … and in my robots or on the Altair-Duino Pro computers. 

 https://www.youtube.com/watch?v=BDaBaBL1mws&ab_channel=WaltPerko

 I set the speech data into data statements at the end of the main BASIC program.  The program reads one DATA line at a time and sends it to the SpeakJet … I have good long speeches and singing etc. 

 https://youtu.be/0qPOyqm0jUQ

 I tried all sorts of hand-shaking with the chip, but found that timing gets screwed up using hardware control so eventually, I learned to just make DATA 20,64,… then a -1 at the end of each data statement that lets the program know to go back into the sending data loop.  


.
On Saturday, August 24, 2024 at 1:38:24 PM UTC-7 John Galt wrote:
Walt a little heads up..

I'm playing around with the speakjet your demo code had issues with phonics dropping out.
in researching it i found the issue.

the smaller Speakjet board going around a few years ago with the Serial connection do not support CTS. CTS is the hardware handshake.
the
code you have to check the Status bit when talking to the speakjet therefore does nothing.
this is why long phonic strings start to skip and break down.
the speakjet as an internal 64 character buffer, this quickly overruns when your converting even small words.

since there is no hardware handshake you have to program in your own delay routines.

thankfully Speakjet includes the Milliseconds each speech piece requires example the robot noises are 80ms as noted int the manual

what you do for the output routine is make a For Next loop where you count from 0 to the MS delay required
for i=0 to 80: next 80 would cover the 80ms needed.
this method will slow the Speakjet down preventing sound overlap and keeping the buffer from overflowing.
this would be the job of the status bit (CTS) but pin 15 on the speakjet is CTS and it is not used in many of the speakjet simple pcbs that came out a few years ago.
there are more elaborate Speakjet pcbs with the TTS processor and full serial support these support CTS and your IF THEN routine would work.

you can see this in action for yourself. run short lines of phonics and listen to how the speakjet handles them

then send a monster long string of phonics and listen as soon as you hit 64 characters with the buffer not fast enough to clear out then all the speech starts to skip and breakdown until the buffer cleans and it can catch up
until it overflows again.. CTS would handle this but its not existant in the format being used.


i'm working on a Text to speech on the fly for the Speakjet now that the Sp0256 is basically done. hope to post a large update soon to my github.

On Wednesday, August 14, 2024 at 10:33:30 AM UTC-4 r4r...@gmail.com wrote:
Message has been deleted

Walt Perko

unread,
Aug 25, 2024, 1:17:37 PMAug 25
to Altair-Duino
Hi, 

You probably have an older version of the program ... I had to adjust the DATA statements to prevent the overflow of data into the chips.  

Here's one of my robots singing a song ... I moved the data to my Altair 8800c so it can sing the song too, but didn't make any videos since there's nothing to see on the Altair 8800c computer.  

"I Gotta Get Me Some"  


.

On Sunday, August 25, 2024 at 9:51:12 AM UTC-7 John Galt wrote:
When you run your basic programs, when it starts trying to sing the second line the buffer fills and it starts skipping phonics and sometimes half the line drops out then comes back in as buffer clears.

this is due to there being no possible hardware flow control with the device. for short sentences you will not notice it occurring which is why it is easy not to notice it.
as you usually build a sentence you listening to one word at a time then stringing them as you go. in that case it works find the buffer is large enough.
but when you bomb multiple sentences that is really when you start to notice words jumble up or half a word seems to disappear etc.

data 20 and 64 just set the volume  020 Volume, X to 64 from default of 96 what happens is these are instant command and might give time for the buffer to clear a few characters.

you don't want to do a reset 31 or 255 or  end of phrase as that can reset the speakjet and it will announce ready in the middle of a sentence.

you need a delay between each phonic to compensate, but it can't be linear because the timing is different between all sounds page 16 in the manual.
what you do is assign the MS delay to each sound effect and then when you play that sound have it count a loop up to that ms you can also put in a multipler to tweak the length as interpreted basic and compiled basic will have different timing.
just a tip to make the speech sound better.

this is also a reason people keep using too many Pauses because the words jumble without the hardware flow control on the serial port.

i noticed all this as i have been running the SP0256-AL2 and the speakjet together at the same time.
at first i just thought the speakjet ran faster then the SP0256 but then i understood it was the lack of CTS causing the speed and drop out issue.

food for thought.

i'm half way through my Speakjet text to speech converter.
Message has been deleted

Walt Perko

unread,
Aug 25, 2024, 7:11:36 PMAug 25
to Altair-Duino
Hi, 

I don't know what you mean about being muddled up in the middle ??? When I run the YouTube video on my Windows 10 computer, it sounds just right.  The camera is about 6 feet away from the little robot singing so the audio isn't as nice as in person.  

It sounds better on my Altair 8800c computer going through my stereo.  


.

On Sunday, August 25, 2024 at 4:00:33 PM UTC-7 John Galt wrote:
The video it is muddling up in the middle.

What are the complete words being said? Just the words no singing added.
Message has been deleted

Walt Perko

unread,
Aug 25, 2024, 9:52:41 PMAug 25
to Altair-Duino
Hi, 

"I Gotta Get Me Some"

It‚s been a looooong time since I got me some
It‚s been a looooong time I ain‚t had none
It‚s been a looooong time I‚m gonna buy me some
Of that Lithium, Lithium, Lithium battery fun.


Copyrighted by Walt Perko 1997-2024  
My IPI #401318902
.
On Sunday, August 25, 2024 at 6:46:12 PM UTC-7 John Galt wrote:
What were the words you wanted it to say?
Write out the lyrics I want to run them through my sp0256 and speakjet programs.
Message has been deleted
Message has been deleted

Walt Perko

unread,
Sep 5, 2024, 10:03:55 PMSep 5
to Altair-Duino
Hi, 

When I used to play with the SP-0256-AL2 chips I created a couple of MS WORD documents to make it easier to expand the dictionary.  


.

On Thursday, September 5, 2024 at 4:50:27 PM UTC-7 John Galt wrote:
update posted for the SP0256-AL2 Text to speech program.

included a 330KB disk image so you can write the disk to a floppy if you want.
otherwise all files included in Library archive for easy Xmodem transfer.

SpeakJet version is coming along will be posted soon.

On Sunday, August 25, 2024 at 11:46:37 PM UTC-4 John Galt wrote:

Good stress test.
SP0Words.doc

Walt Perko

unread,
Sep 5, 2024, 10:12:51 PMSep 5
to Altair-Duino
Hi, 

I forgot to add the little program for the Altair-Duino Pro but which could be used on many other similar computers with minimal Port address changes. 

I have lots of Speech and Singing programs posted on my website:  http://www.brainless.org/Altair/Repository.html#section8  


.
SPOALTAR.BAS.txt
Reply all
Reply to author
Forward
Message has been deleted
Message has been deleted
0 new messages