Omnimaga

Calculator Community => Other Calc-Related Projects and Ideas => TI Z80 => Topic started by: utz on August 12, 2013, 06:30:45 am

Title: ZSpeak - Z80 Speech Synthesizer
Post by: utz on August 12, 2013, 06:30:45 am
Hi folx,

Recently I made a speech synthesizer for ZX Spectrum, because I always wanted to make one. So I figured, why not make it available for TI calcs, too.
Alright, here it is. It's nothing special really, just outputs consonant and vowel samples, and sounds crap like all of them. Well, maybe someone will still find it useful. It should work on TI82/83/83+/84+.

There's just the bare bones routine, I don't think it's really worth making an interface for it. But maybe I'll include it in Houston Tracker at some point.

Download (http://irrlichtproject.de/downloads/zspeakti.zip) (asm source + doc + 82/83/8XP examples included)
Title: Re: ZSpeak - Z80 Speech Synthesizer
Post by: Streetwalrus on August 12, 2013, 06:35:50 am
Hmmm I can't understand what it says. <_< But it looks pretty cool. ;)
Title: Re: ZSpeak - Z80 Speech Synthesizer
Post by: AssemblyBandit on August 12, 2013, 06:50:43 pm
Very professional, I'll have to mod it a little to get it to work on the 84+C, would you want a copy?

*I added the 84+C.
Title: Re: ZSpeak - Z80 Speech Synthesizer
Post by: thepenguin77 on August 12, 2013, 07:12:21 pm
This is one of those projects I've always wanted to make but never did.

At first I was very impressed by the size of your sound samples (they are very small) but after listening to the example I feel like you could probably use a bit more data. ;D Did you ever think of trying to use actual sound samples for the letters? This would of course make the file size much bigger, but I think you could probably make a pretty nice sounding bot.
Title: Re: ZSpeak - Z80 Speech Synthesizer
Post by: utz on August 13, 2013, 05:24:23 am
Thanks guys. No doubt the "speech" is fairly unintelligible :P

@AssemblyBandit: Sure! I don't need it myself, but I'll include it with the download.

@thepenguin77: I had longer sample data before but it doesn't help much. I simply need better data ;) I have some ideas for the future though: One would be to use looped formants, which would allow for a significant decrease in size. The other one would be to implement actual formant synthesis using 3-tier pulse interleaving. This has never been done in 1-bit though, and I'll have to read some more theory on that. Not sure if it would actually work at all. Binary output simply isn't suited very well for speech synthesis. Certain letters like b,g,m,n are almost impossible to do.
Btw those are in fact actual sound samples, they're just pulse-width encoded to make playback easier.
Title: Re: ZSpeak - Z80 Speech Synthesizer
Post by: DJ Omnimaga on August 14, 2013, 05:35:47 pm
How do I send the 8xp file to WabbitEmu by the way? When sent using older versions, the file is renamed to ZSPEAK\T and cannot be launched, and with newer WabbitEmu builds, it throws an error upon transfer.

Also I don't understand the syntax in the readme. Do we actually need to change the text inside the ASM source or do we just do something like "HELLO WORLD0":Asm(prgmZSPEAK ?
Title: Re: ZSpeak - Z80 Speech Synthesizer
Post by: utz on August 15, 2013, 04:02:04 am
Hmm, no idea why WabbitEmu can't handle this. I've given up on that emu tbh.
Btw you need DoorsCS or some other Ion compatible shell to run the 8xp version (even though no ROM/Shell routines are used iirc, so it could probably be compiled as stub also).
To use it, you need to change the message string in test.asm and recompile the thing. Sorry ;)
Title: Re: ZSpeak - Z80 Speech Synthesizer
Post by: DJ Omnimaga on August 15, 2013, 04:04:53 am
Yeah the thing however is that WabbitEmu is the most recent offline emulator and the most accurate one so far. JsTIfied is another nice alternative but I am more used to WabbitEmu so I tend to prefer it in general.

And I see, thanks for the info. A program that can actually read from a BASIC string would be nice, though (although this would prevent 82 compatibility) since it would be more user friendly to people who download things on ticalc but have no interest in programming.

Could someone record a WAV/MP3 demo of how it sounds like?
Title: Re: ZSpeak - Z80 Speech Synthesizer
Post by: chickendude on August 15, 2013, 10:32:16 am
What's wrong with TilEm2? Also, i think you can add a different ion header that lets you run it with ion-shells and from the homescreen.
Title: Re: ZSpeak - Z80 Speech Synthesizer
Post by: DJ Omnimaga on August 15, 2013, 02:37:37 pm
I thought sound support wasn't added yet in TilEm? Also I personally prefer WabbitEmu anyway, since it has more screen options (for grayscale in BASIC and Axe programs, in particular)
Title: Re: ZSpeak - Z80 Speech Synthesizer
Post by: CalebHansberry on August 15, 2013, 08:02:30 pm
A speech synthesizer for z80 calcs is an excellent idea; I wish you well.
Title: Re: ZSpeak - Z80 Speech Synthesizer
Post by: chickendude on August 15, 2013, 08:11:53 pm
My version of TilEm2 has sound support, maybe a Windows binary hasn't been built yet?

I'd also like to hear a demo of what the speech actually sounds like :)
Title: Re: ZSpeak - Z80 Speech Synthesizer
Post by: DJ Omnimaga on August 15, 2013, 10:38:45 pm
My version of TilEm2 has sound support, maybe a Windows binary hasn't been built yet?

I'd also like to hear a demo of what the speech actually sounds like :)
YEah that's what I think. IIRC the Windows version was still 1 or 2 versions behind.
Title: Re: ZSpeak - Z80 Speech Synthesizer
Post by: AssemblyBandit on August 16, 2013, 05:58:29 pm
DJ: To use the .8xp in WabbitEmu (I'm using v1.7.2.11 and the TI84+SE ROM) without recompiling it, open it up in a hex editor and where you see the value:ZSPEAK\T just change the '\' to T so it would be ZSPEAKTT. I also added the TI84+C, you might have to rename it from .8cp (TI Connect v4.0.0.218 works for me with .8cp and it recognizes it as a TIDevice file)
Title: Re: ZSpeak - Z80 Speech Synthesizer
Post by: DJ Omnimaga on August 16, 2013, 07:08:01 pm
By hex editor, do you mean like Resource hacker?
Title: Re: ZSpeak - Z80 Speech Synthesizer
Post by: AssemblyBandit on August 16, 2013, 07:54:14 pm
I would use HxD. It's a free hex editor, just open up the .8xp file, select offset 0x42 (It should be the '\') and set it to 0x54 ('T'). Save the file then just drag and drop it in the emulator.

http://mh-nexus.de/en/downloads.php?product=HxD
Title: Re: ZSpeak - Z80 Speech Synthesizer
Post by: DJ Omnimaga on August 17, 2013, 01:22:10 am
I finally got the program to send to the calc (although it only sends to archive), so here's a MP3 demo:
Title: Re: ZSpeak - Z80 Speech Synthesizer
Post by: Keoni29 on August 17, 2013, 02:12:26 pm
What does it say???
Title: Re: ZSpeak - Z80 Speech Synthesizer
Post by: AssemblyBandit on August 17, 2013, 02:25:02 pm
From the phonetic code I THINK: "Welcome to ZSpeak the totally useless and fairly crappy z80 speech synthesizer"
Title: Re: ZSpeak - Z80 Speech Synthesizer
Post by: Keoni29 on August 17, 2013, 02:41:26 pm
Hmm I see. Might have to be a native speaker to hear that.
Title: Re: ZSpeak - Z80 Speech Synthesizer
Post by: TIfanx1999 on August 26, 2013, 11:46:16 pm
Nah, it's pretty hard to understand. It is neat though, nonetheless.
Title: Re: ZSpeak - Z80 Speech Synthesizer
Post by: Sorunome on August 27, 2013, 08:13:46 am
Wha, pretty nice prog idea, it could be pretty useful :D