wrbrower Posted October 29, 2007 Share Posted October 29, 2007 Hello all, I have a SAPI 5 speech engine (Neo Speech) that has a software bug. I start my home automation software (HomeSeer) and Neo Speech works fine. Inside of HomeSeer is a plugin that needs to also use that Neo Speech voice. If I toggle the voice under the Windows Control Panel, like from VW Kate 16k to MS Sam and then back to VW Kate 16k, everything works fine. HomeSeer can trigger scripts, including Auto IT scripts. Does anyone know how I can toggle the Windows default voice using AutoIT? The voice names are: VW Kate 8k VW Kate 16k Microsoft Mike Thanks in advance, Regards, Bill Link to comment Share on other sites More sharing options...
zfisherdrums Posted October 29, 2007 Share Posted October 29, 2007 (edited) Hello Bill, I haven't tested this, but I believe you could have a script update the following registry key: HKCU\SOFTWARE\Microsoft\Speech\Voices\DefaultTokenId To set LH Michael, set the value to: HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Speech\Voices\Tokens\LHMICHAEL To set LH Michelle, set the value to: HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Speech\Voices\Tokens\LHMICHELLE I don't know what the others would be, but you could open RegEdit or RegMon to determine their values. Hope this helps. Zach... Edited October 29, 2007 by zfisherdrums Identify .NET controls by their design time namesLazyReader© could have read all this for you. Unit Testing for AutoItFolder WatcherWord Doc ComparisonThis here blog... Link to comment Share on other sites More sharing options...
wrbrower Posted October 29, 2007 Author Share Posted October 29, 2007 Thanks ZFD: It appears changing that key does not actually trigger the change in Windows. It accepts the value but does not go into effect. It was worth a shot, thanks for your time. Bill Link to comment Share on other sites More sharing options...
zfisherdrums Posted October 29, 2007 Share Posted October 29, 2007 I'm sorry to hear that. If you're okay with it, may I see the script you are testing with? Perhaps we can assist you further. I'll understand if you do not wish to share it/drop it. Zach... Identify .NET controls by their design time namesLazyReader© could have read all this for you. Unit Testing for AutoItFolder WatcherWord Doc ComparisonThis here blog... Link to comment Share on other sites More sharing options...
LurchMan Posted April 10, 2010 Share Posted April 10, 2010 This should do the trick: _TalkOBJ("Hello world.") Func _TalkOBJ($s_text) Local $o_speech $o_speech = ObjCreate("SAPI.SpVoice") $o_speech.Voice = $o_speech.GetVoices("name=Microsoft Mike").Item(0) ;Change name here $o_speech.Speak ($s_text) $o_speech = "" EndFunc Dating a girl is just like writing software. Everything's going to work just fine in the testing lab (dating), but as soon as you have contract with a customer (marriage), then your program (life) is going to be facing new situations you never expected. You'll be forced to patch the code (admit you're wrong) and then the code (wife) will just end up all bloated and unmaintainable in the end. Link to comment Share on other sites More sharing options...
AdmiralAlkex Posted April 10, 2010 Share Posted April 10, 2010 This thread is epic! I mean, what's the chance that the two users from a three year old thread have only a three hour difference on the "Last Active" time when they finally receive their answer? Nice move Lurch Last Active: Mar 30 2010 06:16 PM Last Active: Mar 30 2010 03:05 PM .Some of my scripts: ShiftER, Codec-Control, Resolution switcher for HTC ShiftSome of my UDFs: SDL UDF, SetDefaultDllDirectories, Converting GDI+ Bitmap/Image to SDL Surface Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now