Puppy Linux Discussion Forum Forum Index Puppy Linux Discussion Forum
Puppy HOME page : puppylinux.com
"THE" alternative forum : puppylinux.info
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

The time now is Thu 02 Oct 2014, 10:28
All times are UTC - 4
 Forum index » Advanced Topics » Puppy Derivatives
Talking Puppy (for the visually handicapped)
Moderators: Flash, JohnMurga
Post_new_topic   Reply_to_topic View_previous_topic :: View_next_topic
Page 1 of 2 Posts_count   Goto page: 1, 2 Next
Author Message
raffy

Joined: 25 May 2005
Posts: 4765
Location: Manila

PostPosted: Tue 03 Jul 2007, 22:23    Post_subject:  Talking Puppy (for the visually handicapped)
Sub_title: a project for PEOPLE who have a visual impairment
 

Is there a way to make the menu "talk" - play sounds rather than simply display items? Every highlighted item will "talk" itself out.

One function key (or key combination) should launch the menu. The rest of commands will be given keyboard shortcuts.

Maybe there are already packages for this purpose?

nibl in this forum has already done a text reader for Puppy - I hope his work can be shared here.

_________________
Puppy user since Oct 2004. Want FreeOffice? Get the sfs (English only).

Edited_time_total
Back to top
View user's profile Send_private_message 
WhoDo


Joined: 11 Jul 2006
Posts: 4441
Location: Lake Macquarie NSW Australia

PostPosted: Tue 03 Jul 2007, 23:09    Post_subject: Re: Talking Puppy (for the visually handicapped)
Sub_title: a project for blind people
 

raffy wrote:
Is there a way to make the menu "talk" - play sounds rather than simply display items? Every highlighted item will "talk" itself out.

One function key (or key combination) should launch the menu. The rest of commands will be given keyboard shortcuts.

Maybe there are already packages for this purpose?

My recollection from some time ago was that MU gave us a text to speech reader that maybe could be adapted to do what you want. It was entered in a shell script with a parameter for the file to read. I tried it and it worked, although it did seem to have a slight German accent! Razz

_________________
Actions speak louder than words ... and they usually work when words don't!
SIP:whodo@proxy01.sipphone.com; whodo@realsip.com
Back to top
View user's profile Send_private_message 
Lobster
Official Crustacean


Joined: 04 May 2005
Posts: 15117
Location: Paradox Realm

PostPosted: Tue 03 Jul 2007, 23:43    Post_subject: text 2 speech  

festival
http://www.murga-linux.com/puppy/viewtopic.php?search_id=829871212&t=8704

text2speech
http://www.murga-linux.com/puppy/viewtopic.php?p=53926&search_id=829871212#53926

- now they sing . . .
http://cslu.cse.ogi.edu/tts/demos/sing/femthree.au
from this page on synthesis
http://cslu.cse.ogi.edu/tts/

_________________
Puppy WIKI
Back to top
View user's profile Send_private_message Visit_website 
HairyWill


Joined: 26 May 2006
Posts: 2949
Location: Southampton, UK

PostPosted: Sun 08 Jul 2007, 21:52    Post_subject:  

Raffy,
I've hacked jwm so that it calls a shell script everytime a menu entry is highlighted and am successfully using madplay to play small mp3 clips I have of the text that should be read.

I have used Festival to generate the sound clips. The disadvantage of this system is that it is limited to the 200 or so menu entries that I have made clips for.

I tried calling Festival directly from my script but because it gets called so many times a second it is complaining about /dev/dsp being already in use.

Ideally I would like to start the festival server and then call it directly from jwm using C but that will involve more reading on my part.

I had a look for stuff posted by nibl but coudn't find anything useful.
If you want to try it out I can package it up as a pet for you.

_________________
Will
contribute: community website, screenshots, puplets, wiki, rss
Back to top
View user's profile Send_private_message 
willhunt


Joined: 05 Oct 2005
Posts: 495

PostPosted: Mon 09 Jul 2007, 01:48    Post_subject:  

I would really like to see that pet file please HairyWill
_________________
176 Icewm Themes Exclamation
vlc-0.8.6c-i586.pet
vlc-0.8.6c-i586.pet
Back to top
View user's profile Send_private_message 
HairyWill


Joined: 26 May 2006
Posts: 2949
Location: Southampton, UK

PostPosted: Mon 09 Jul 2007, 07:43    Post_subject:  

OK here we go:

for the impatient, the PET
install
http://users.ecs.soton.ac.uk/wmd04r/puppy/jwm_2.0.1_jwmspeak-0.1.1-i686.pet
restart X

now the warnings
It upgrades your JWM to 2.01, you may not like the default window border colour scheme you get. This can be replaced by putting a windowstyle declaration inside /root/.jwm/jwm-personal such as
Code:
<WindowStyle>
<Font>FreeSans-9:bold</Font>
<Width>4</Width>
<Height>20</Height>
<Active>
<Text>white</Text>
<Title>#70849d:#2e3a67</Title>
<Corner>white</Corner>
<Outline>black</Outline>
</Active>
<Inactive>
<Text>#aaaaaa</Text>
<Title>#808488:#303438</Title>
<Corner>#aaaaaa</Corner>
<Outline>black</Outline>
</Inactive>
</WindowStyle>

The replacement jwm executable is placed in /usr/local/bin so it doesn't actually overwrite the existing one it just appears on the path earlier.
The menus don't work when you are listening to music.

included
I have included mp3 files for all the entries in my menus if you want more you will need to create them yourself. Extra mp3 files should be put in /usr/local/jwm-speak/clips/ the naming scheme should be fairly obvious.
If you have festival installed you can use jwm-speak_create-phrases.sh to regenerate the sound files based on your .jwmrc so you will have sounds for any menu items that I haven't included.

source
I had to hack the jwm source a small amount to do this so here is a link to my modified source.
http://users.ecs.soton.ac.uk/wmd04r/puppy/jwm-2.0.1_with_jwm-speak_hook.tar.gz

no screenshot Smile

_________________
Will
contribute: community website, screenshots, puplets, wiki, rss

Edited_time_total
Back to top
View user's profile Send_private_message 
raffy

Joined: 25 May 2005
Posts: 4765
Location: Manila

PostPosted: Tue 10 Jul 2007, 09:09    Post_subject: using it now - THANKS!  

Am using it now for Puppy 2.14 as well as for 2.12 (with flite binaries, compliments of nibl).

Am at a loss how to customize the sound tracks for the menu entries. Is it correct that madplay does the playing of mp3 files?

Another possibility of playing audio is via flite, in console/text commands, like "flite menu phrase" (no separate saving of mp3 file is needed). For building flite in Puppy, nibl says:
Quote:
The binary depends on wxWidgets 2.63 (It is written in wxPerl which uses wxWidgets as its GUI, which is GTK+ based). It should be easy to move to any Puppy version which wxWidgets runs on. (It may require GTK version 2, not GTK version 1).
There is a dotpup of wxWidgets you can install, then it should work.


The latest flite I've seen is version 1.3.

_________________
Puppy user since Oct 2004. Want FreeOffice? Get the sfs (English only).
Back to top
View user's profile Send_private_message 
HairyWill


Joined: 26 May 2006
Posts: 2949
Location: Southampton, UK

PostPosted: Tue 10 Jul 2007, 09:52    Post_subject:  

Raffy,
jwm makes a call to /root/my-applications/bin/jwm-speak when there is something to say. The text to read is placed in /tmp/speak. So you could simply edit jwm-speak and place a call to flite there.

_________________
Will
contribute: community website, screenshots, puplets, wiki, rss
Back to top
View user's profile Send_private_message 
HairyWill


Joined: 26 May 2006
Posts: 2949
Location: Southampton, UK

PostPosted: Tue 10 Jul 2007, 11:08    Post_subject:  

I've just looked at the flite documentation and will try and incorporate it directly into jwm
_________________
Will
contribute: community website, screenshots, puplets, wiki, rss
Back to top
View user's profile Send_private_message 
willhunt


Joined: 05 Oct 2005
Posts: 495

PostPosted: Tue 10 Jul 2007, 22:20    Post_subject:  

Hairy the link is broken Crying or Very sad
_________________
176 Icewm Themes Exclamation
vlc-0.8.6c-i586.pet
vlc-0.8.6c-i586.pet
Back to top
View user's profile Send_private_message 
HairyWill


Joined: 26 May 2006
Posts: 2949
Location: Southampton, UK

PostPosted: Wed 11 Jul 2007, 09:57    Post_subject:  

Upgraded to 0.1.1

Link is live again, you'd think that a computer science school would be able to keep its servers up Embarassed.

I've modified the shell scripts in /root/my-applications/bin so that they call flite directly if you have it installed. If you have the earlier version you might want to just update these two files rather than downloading the whole pet. The flite voice is lower quality but louder than the mp3s.
/root/my-applications/bin/jwm-speak
Code:
#!/bin/sh

killall jwm-speak-delayed 2> /dev/null
killall madplay 2> /dev/null
killall flite 2> /dev/null
/root/my-applications/bin/jwm-speak-delayed &

/root/my-applications/bin/jwm-speak-delayed
Code:
#!/bin/sh
#replace slash with hyphen ; remove leading spaces ; remove trailing spaces; replace spaces with hyphen
PHRASE=`sed 's/\//-/g ; s/^[ ]*// ; s/[ ]*$// ; s/ /-/g' /tmp/speak`
CLIP="/usr/local/jwm-speak/clips/$PHRASE.mp3"
#sleep stops stuttering
usleep 1000
which flite && flite /tmp/speak || madplay "$CLIP" 2> /dev/null

I'm aware there is a problem with zombie jwm-speak processes my C programming isn't up to much. The zombies don't use any resources except process numbers and should die properly if you restart X.

@Raffy I presume you have flite connected to some applications to make it useful. Have you looked at emacspeak. I am fully sighted and can't use emacs but I suppose I have less incentive.

_________________
Will
contribute: community website, screenshots, puplets, wiki, rss
Back to top
View user's profile Send_private_message 
HairyWill


Joined: 26 May 2006
Posts: 2949
Location: Southampton, UK

PostPosted: Wed 11 Jul 2007, 12:19    Post_subject:  

Here is a pet for flite.
It is a single binary with a croaky voice.
usage
flite "A sentence to speak."
or
flite /root/myfile.txt

http://users.ecs.soton.ac.uk/wmd04r/puppy/flite-1.3.pet

_________________
Will
contribute: community website, screenshots, puplets, wiki, rss
Back to top
View user's profile Send_private_message 
cb88


Joined: 28 Jan 2007
Posts: 1169
Location: USA

PostPosted: Tue 25 Sep 2007, 19:03    Post_subject:  

will looks like you beat me to maing a .pet of flite i'll link yours to the talking stick page
_________________
Taking Puppy Linux to the limit of perfection. meanwhile try "puppy pfix=duct_tape" kernel parem eater.
X86: Sager NP6110 3630QM 16GB ram, Tyan Thunder 2 2x 300Mhz
Sun: SS2 , LX , SS5 , SS10 , SS20 ,Ultra 1, Ultra 10 , T2000
Mac: Platinum Plus, SE/30
Back to top
View user's profile Send_private_message Visit_website 
raffy

Joined: 25 May 2005
Posts: 4765
Location: Manila

PostPosted: Wed 26 Sep 2007, 04:33    Post_subject: highlight  

Will's flite binary is very useful, just command "flite" in console in any directory and go. Very Happy

I wonder if flite can be used to read highlighted paragraphs or phrases. There must be a way of using the clipboard for this. Question
Back to top
View user's profile Send_private_message 
cb88


Joined: 28 Jan 2007
Posts: 1169
Location: USA

PostPosted: Wed 26 Sep 2007, 07:52    Post_subject:  

@raffy I was thinking that too maybe a button on the taskbar to read selected text?

@hairywill do you know how to change the voice i spent a little time on it the other day but couldn't get it to compile after i changed the refeences to FL_VOX (i think that was it ) ti the kal somting or other voice maybe i was confused I'll have to read the readmes and stuff some more

_________________
Taking Puppy Linux to the limit of perfection. meanwhile try "puppy pfix=duct_tape" kernel parem eater.
X86: Sager NP6110 3630QM 16GB ram, Tyan Thunder 2 2x 300Mhz
Sun: SS2 , LX , SS5 , SS10 , SS20 ,Ultra 1, Ultra 10 , T2000
Mac: Platinum Plus, SE/30
Back to top
View user's profile Send_private_message Visit_website 
Display_posts:   Sort by:   
Page 1 of 2 Posts_count   Goto page: 1, 2 Next
Post_new_topic   Reply_to_topic View_previous_topic :: View_next_topic
 Forum index » Advanced Topics » Puppy Derivatives
Jump to:  

Rules_post_cannot
Rules_reply_cannot
Rules_edit_cannot
Rules_delete_cannot
Rules_vote_cannot
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group
[ Time: 0.1007s ][ Queries: 12 (0.0181s) ][ GZIP on ]