• 1
  • 13
  • 14
  • 15(current)
  • 16
  • 17
  • 30
Xbmc not working for blind users.
Yeah, its definitely slow, LOL.
By the way, if you know how to get on IRC I'm always in channel #ruuk on freenode.

Also, the version that uses the memory fix for ATV2/Raspberry Pi isn't on my repository yet. Should have it up within the hour.
Information 
Added a new version to my repository: 0.0.37.

Get it or the repository from the Downloads Page.

Changes:
  • Added support for playSFX without caching (xbmc git: 5579740e9881717c65518b81a9a2b4d9526c3307)
    - Enable in Settings::Advanced (temporary setting until relevant change is in an XBMC release)
  • Added the ability to output wavs to a tmpfs (/run/shm or /dev/shm with fallback to /tmp)
  • Added speaking for typing in the numeric and IP address inputs
  • Added backend for eckythump's HTTP speech wav server

eckythump: Added the backend. Voice and speed selection work. Made a few changes to make everything work more smoothly.
(2014-04-15, 23:57)ruuk Wrote: Just FYI, I installed Strawberry Perl and that was all I needed to run the script.
I'm running XP in a virtual machine and Cygwin was a bit larger than I wanted Smile

I thought and was hoping that'd be the case. That's awesome. That should make it fairly trivial for someone who's done it before to package up some kind of installer for the daemon.

If you feel inclined to, I'd be very happy to see the daemon rewritten in Python. I reused, recycled and repurposed some old perl just to get something up and running quickly, but if I had've done it from scratch, I definitely would've used Python for it.

Settings...

The speed range should be 0 to 10. The httphost setting, as you can see I currently have that as a single var in URL format with a trailing /. It might be better to change that to just the host/IP and add a httpport setting so we can then construct the URL ourselves with 'http://%s:%s/' % (httphost,httpport) to remove any chance of people leaving off the trailing / when editing that setting.

Thanks again for all your work bringing this together. I'm looking forward to 0.0.38 and beyond.

Edited to add:

Ooh, I hadn't seen your last post when I submitted mine above. I shall go and take a look-see at 0.0.37 now, cheers.
--- UPDATE ---

So I updated to the latest release and have it working, hooray!

I did need to jump through a few hoops to get it going, though, mostly due to the fact that my backend doesn't work out-of-the-box and needs to be configured.

When I first booted with the new version, my default engine was still set to 'ttsd' from my own previous testing using hard-coded values specifically tailored for my network at home. When the new version started, it then was trying to use 127.0.0.1 and that caused things to really break, to the point that xbmc would completely crash and restart.

The last line in the xbmc log file when it died was:

11:53:36 T:2809132112 NOTICE: service.xbmc.tts: ERROR: SJHttsdTTSBackend: wav.write - <urlopen error [Errno 111] Connection refused>

I edited that error output to include self.httphost just to confirm where it was trying to connect, and then rolled back to the old version, changed to espeak, then upgrade again, changed back to ttsd and configured it properly. After that it was happy.

If we trap that exception better, how easy would it be to fall back to the highest priority backend that's available?

I don't know enough about xbmc to know why that's making it barf so spectacularly, but hopefully it's easily fixed.

The only other issue I noticed, and this is very minor, is that when I changed voices, it didn't switch when I went OK. It did take affect when I rebooted, though. I didn't try any other things to see if I could get it to take.

Thanks for getting it into the base so quickly. Hopefully I'm not the only one who'll be able to make use of it.
@@
(2014-04-16, 07:57)VIJO Wrote: Hey Ruuk, If possible, How about adding a toggle to the keymap to enable/disable TTS. Say F12 or something like that. You know for the rare occasion my poor sighted friends want to use it without me knowing what they are doing, lol.

I've had that planned. I'm going to create a separate addon as a dependency that will respond to a shortcut and actually disable/enable the addon. That way it will be completey 'off' and not polling the interface or anything,
(2014-04-16, 05:58)eckythump Wrote: When the new version started, it then was trying to use 127.0.0.1 and that caused things to really break, to the point that xbmc would completely crash and restart.

The last line in the xbmc log file when it died was:

11:53:36 T:2809132112 NOTICE: service.xbmc.tts: ERROR: SJHttsdTTSBackend: wav.write - <urlopen error [Errno 111] Connection refused>
I tried it just now with the IP set to 127.0.0.1. I can hammer away changing controls. I get the same error, but I can't get XBMC to crash on me. What platform is this happening on?
(2014-04-16, 05:58)eckythump Wrote: I edited that error output to include self.httphost just to confirm where it was trying to connect, and then rolled back to the old version, changed to espeak, then upgrade again, changed back to ttsd and configured it properly. After that it was happy.

If we trap that exception better, how easy would it be to fall back to the highest priority backend that's available?
Well, I've been thinking we need some sort of fallback mechanism, and perhaps a dialog that confirms that you hear speech after a backend change and reverts if you don't confirm.
I'll try to add some of that soon.
(2014-04-16, 05:58)eckythump Wrote: I don't know enough about xbmc to know why that's making it barf so spectacularly, but hopefully it's easily fixed.

The only other issue I noticed, and this is very minor, is that when I changed voices, it didn't switch when I went OK. It did take affect when I rebooted, though. I didn't try any other things to see if I could get it to take.
I can't duplicate this either. It works fine for me. Hmmm.....
eckythump: There is a small bug in the Perl server. If you pass the text '0' it triggers a 403 error. Typing a 0 in a keyboard dialog will cause this. I suspect that this is being interpreted as a number and and evaluating false on the test for $text. It's been a while since I've done much coding in Perl so this is just a guess.
(2014-04-16, 03:03)eckythump Wrote: The speed range should be 0 to 10.
The documentation I saw said the range was -10 to 10, and this seems to work.
Information 
Added a new version to my repository: 0.0.38.

Get it or the repository from the Downloads Page.

Changes:
  • Added the ability to disable/enable the addon with F12 (you'll need to update the keymap from settings)
  • Added addon module dependency for script.library.xbmc.tts (for the enable/disable handling)
  • Fix for encoiding errors with non-ascii characters in HTTP speech wav server backend
eckythump: I was testing on the ATV2 via the perl server. On the first try changing the voice it didn't work. On the second try I changed the voice a and speed and it worked. Adding the speed may or may not have had anything to do with it. I noticed that the order of the voice list changed at one point. I'm not sure if this points to anything, I'd have to look at the code and I'm about to go to bed.
I tested setting the IP address to 127.0.0.1 on the ATV2 and managed to crash XBMC. In fact, I couldn't get to the settings without it crashing after that, and had to ssh in and change the settings.xml file manually.
I'll await finding out what platform you were using to get a better idea of what's going on.

Now I'm really off to bed Smile
(2014-04-16, 20:39)ruuk Wrote: eckythump: There is a small bug in the Perl server. If you pass the text '0' it triggers a 403 error. Typing a 0 in a keyboard dialog will cause this. I suspect that this is being interpreted as a number and and evaluating false on the test for $text. It's been a while since I've done much coding in Perl so this is just a guess.

Yep, good catch, and you're exactly right with your guess.

If you change the line:
Code:
if ($voice and defined($rate) and $text) {
to this:
Code:
if ($voice and defined($rate) and $text ne '') {

that'll fix it. The "defined" around the $rate is to avoid the same issue with a rate of 0. I'll probably redo this section and add in some actual input validation as it'll currently happily accept and try and use a rate of "asparagus" if someone felt so inclined to POST that to it.

I've registered a github account, and I'll post it there in the next few days once I've had a chance to give myself a git crash course.
ruuk: Sorry for not addressing your other questions earlier, I somehow managed to completely miss those posts last time I looked.

The platform I'm using is openelec 3.95.5 on a raspberry pi.

The order of voices does seem semi-random. I've actually made some changes to the perl server to return an array where the first item is "host server's default voice' + all the available voices sorted alphabetically to make that less annoying.

When I changed voice and it didn't take until I rebooted, I'm pretty sure I didn't touch the speed, but I will investigate that later.

Now it's my turn to stagger off to bed. Night. Smile
  • 1
  • 13
  • 14
  • 15(current)
  • 16
  • 17
  • 30

Logout Mark Read Team Forum Stats Members Help
Xbmc not working for blind users.5