[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

problems with espeak and pulseaudio



Hi Robert

I just upgraded to Ubuntu 10.10. I found espeak under emacspeak very unreliable
with the standard install. While I didn't notice the clipping that I observed
with earlier installs, I did find that speech was stopping and I had to restart
the server often. 

I downloaded the latest espeak from sourceforge and re-compiled after changing
the variable in the Makefile from portaudio to pulseaudio. This appears to have
resolved all the problems I had. The espeak responsiveness with respect to
character echo is still slow, but I get around this by disableing character
echo when typing large amounts of text (such as this email). 

So far, all seems to be working for me. I suspect your pulseaudio is working
with the correct permissions and real time scheduling (from memory, you would
get a message via syslog if it wasn't and no message if it is). 

All I can suggest is that you verify your build of espeak from the sources has
installed correctly. Changing from portaudio to pulseaudio certainly fixed all
my problems with text being clipped. Maybe rebuild the emacspeak espeak library
against the new espeak version you have installed will help?

I find now that I don't need any 'special' configuration for pulseaudio and
ahve removed my local configuration files. Likewise, I also no longer require a
local alsa config file. I'm running emacspeak from svn with emacs 24 built from
bzr. My system is a 64 bit Intel with a soundblaster Audigy 4 card.

I only did this upgrade yesterday, so I may yet run into issues, but all seems
good so far. 

Tim



Robert D. Crawford writes:
 > I just got a shiny new computer and installed Ubuntu 10.10rc (the
 > final release was a day or two pending).  I'm running into some
 > problems with espeak but only in emacspeak.
 > 
 > Here is what I have installed:
 > 
 > emacs 23.2.1 from source
 > emacspeak 32 from source into /usr/local
 > 
 > On first running emacspeak with orca, orca reads well but with
 > emacspeak there is an issue with speech being clipped off at the last
 > character or two.  responsiveness is good, though, i.e. moving up and
 > down lines in the buffer provides immediate feedback.
 > 
 > I read Tim's email concerning getting espeak and pulseaudio to work well
 > together.  
 > 
 > The first thing I did was to change the logging level to info.  All I
 > get in the logs are lines like the following:
 > 
 > ,----
 > | Oct 12 09:31:30 E6410 pulseaudio[23792]: ratelimit.c: 139 events suppressed
 > `----
 > 
 > No other info is given, either then or now.
 > 
 > The next thing I did was to download espeak 1.44.05 source from the
 > site.  Changed portaudio line to pulseaudio in the makefile and
 > received no warnings compiling.  I then ran ldconfig and rebuilt the
 > emacspeak server.  Orca speech is good.  running tclsh espeak, speech
 > server is working well.
 > 
 > Speech in emacspeak is hosed.  Pause before speaking lines.  As an
 > example of the problem, If I do C-x C-f and do not hit anything else,
 > it immediately says "Capital Find file colon" but if I type C-x C-f
 > and type a period before the speech stops, there is a 3-4 second pause
 > before it says "colon dot."  If I try to scroll several lines in a
 > buffer there is 3-4 second pause between speech output which is only the
 > first "cap" of the word "Capital."
 > 
 > I tried putting Tim's .asoundrc file in my $HOME with no joy.
 > 
 > running pacmd and list-sinks, I get this output.  This command seemed
 > to show what I should be looking for.  (comments in-line):
 > 
 > ,----
 > | 1 sink(s) available.
 > |   * index: 0
 > | 	name: <alsa_output.pci-0000_00_1b.0.analog-stereo>
 > | 	driver: <module-alsa-card.c>
 > | 	flags: HARDWARE HW_MUTE_CTRL HW_VOLUME_CTRL DECIBEL_VOLUME LATENCY
 > DYNAMIC_LATENCY
 > | 	state: RUNNING
 > | 	suspend cause: 
 > | 	priority: 9959
 > `----
 > 
 > The above line tells the priority of pulseaudio, right?  Is this
 > high-priority?  How can I tell if it is using rt-scheduling?
 > 
 > ,----
 > | 	volume: 0:  44% 1:  44%
 > | 	        0: -21.32 dB 1: -21.32 dB
 > | 	        balance 0.00
 > | 	base volume: 100%
 > | 	             0.00 dB
 > | 	volume steps: 65537
 > | 	muted: no
 > | 	current latency: 7.76 ms
 > `----
 > 
 > >From what I have seen, since this is less than the requested latency
 > shown below, something set by the application making the request, this
 > should be fine.  Do I misunderstand?
 > 
 > ,----
 > | 	max request: 1 KiB
 > | 	max rewind: 344 KiB
 > | 	monitor source: 0
 > | 	sample spec: s16le 2ch 44100Hz
 > `----
 > 
 > If I run list, the above line matches the output at the top.  I've
 > included the first few lines below, after the output of this command
 > 
 > ,----
 > |       channel map: front-left,front-right
 > | 	             Stereo
 > | 	used by: 2
 > | 	linked by: 2
 > | 	configured latency: 8.00 ms; range is 8.00 .. 1999.82 ms
 > `----
 > 
 > Here is the latency line I was referring to above.
 > 
 > ,----
 > |       card: 0 <alsa_card.pci-0000_00_1b.0>
 > | 	module: 4
 > | 	properties:
 > | 		alsa.resolution_bits = "16"
 > | 		device.api = "alsa"
 > | 		device.class = "sound"
 > | 		alsa.class = "generic"
 > | 		alsa.subclass = "generic-mix"
 > | 		alsa.name = "STAC92xx Analog"
 > | 		alsa.id = "STAC92xx Analog"
 > | 		alsa.subdevice = "0"
 > | 		alsa.subdevice_name = "subdevice #0"
 > | 		alsa.device = "0"
 > | 		alsa.card = "0"
 > | 		alsa.card_name = "HDA Intel"
 > | 		alsa.long_card_name = "HDA Intel at 0xf6960000 irq 48"
 > | 		alsa.driver_name = "snd_hda_intel"
 > | 		device.bus_path = "pci-0000:00:1b.0"
 > | 		sysfs.path = "/devices/pci0000:00/0000:00:1b.0/sound/card0"
 > | 		device.bus = "pci"
 > | 		device.vendor.id = "8086"
 > | 		device.vendor.name = "Intel Corporation"
 > | 		device.product.id = "3b56"
 > | 		device.product.name = "5 Series/3400 Series Chipset High
 > Definition Audio"
 > | 		device.form_factor = "internal"
 > | 		device.string = "front:0"
 > | 		device.buffering.buffer_size = "352768"
 > `----
 > 
 > This buffer size is much larger than the one I have on my current system.
 > 
 > ,----
 > | 		device.buffering.fragment_size = "176384"
 > |                 device.access_mode = "mmap+timer"
 > | 		device.profile.name = "analog-stereo"
 > | 		device.profile.description = "Analog Stereo"
 > | 		device.description = "Internal Audio Analog Stereo"
 > | 		alsa.mixer_name = "Intel IbexPeak HDMI"
 > | 		alsa.components = "HDA:111d76d5,1028040a,00100104
 > HDA:14f12c06,14f1000f,00100000 HDA:80862804,80860101,00100000"
 > | 		module-udev-detect.discovered = "1"
 > | 		device.icon_name = "audio-card-pci"
 > | 	ports:
 > | 		analog-output: Analog Output (priority 9900)
 > | 		analog-output-headphones: Analog Headphones (priority 9000)
 > | 	active port: <analog-output>
 > `----
 > 
 > Output of first few lines of 'list':
 > 
 > ,----
 > | Memory blocks currently allocated: 72, size: 227.2 KiB.
 > | Memory blocks allocated during the whole lifetime: 78640, size: 507.1 MiB.
 > | Memory blocks imported from other processes: 57, size: 89.4 KiB.
 > | Memory blocks exported to other processes: 0, size: 0 B.
 > | Total sample cache size: 0 B.
 > | Default sample spec: s16le 2ch 44100Hz
 > | Default channel map: front-left,front-right
 > | Default sink name: alsa_output.pci-0000_00_1b.0.analog-stereo
 > | Default source name: alsa_input.pci-0000_00_1b.0.analog-stereo
 > | Memory blocks of type POOL: 15 allocated/2526 accumulated.
 > | Memory blocks of type POOL_EXTERNAL: 0 allocated/0 accumulated.
 > | Memory blocks of type APPENDED: 0 allocated/0 accumulated.
 > | Memory blocks of type USER: 0 allocated/0 accumulated.
 > | Memory blocks of type FIXED: 0 allocated/74856 accumulated.
 > | Memory blocks of type IMPORTED: 57 allocated/1258 accumulated.
 > `----
 > 
 > I'm not sure how to go about resolving the issue.  Since speech seems
 > to work well in orca but not in emacs, it leads me to believe it might
 > be an emacspeak server issue.  orca is using the speech-dispatcher backend, if
 > it
 > matters.  Also, the problem doesn't change if orca is not running or
 > if I run outside of X on a VT.
 > 
 > If anyone can shed some light on this and point me in the right
 > direction I would surely be grateful.
 > 
 > Thanks,
 > rdc
 > -- 
 > Robert D. Crawford                                     robdcraw@gmail.com
 > 
 > Drop the vase and it will become a Ming of the past.
 > 		-- The Adventurer
 > 
 > -----------------------------------------------------------------------------
 > To unsubscribe from the emacspeak list or change your address on the
 > emacspeak list send mail to "emacspeak-request@cs.vassar.edu" with a
 > subject of "unsubscribe" or "help".
 > 

-- 
Tim Cross
tcross@rapttech.com.au

There are two types of people in IT - those who do not manage what they 
understand and those who do not understand what they manage.

-----------------------------------------------------------------------------
To unsubscribe from the emacspeak list or change your address on the
emacspeak list send mail to "emacspeak-request@cs.vassar.edu" with a
subject of "unsubscribe" or "help".



If you have questions about this archive or had problems using it, please send mail to:

priestdo@cs.vassar.edu No Soliciting!

Emacspeak List Archive | 2010 | 2009 | 2008 | 2007 | 2006 | 2005 | 2004 | 2003 | 2002 | 2001 | 2000 | 1999 | 1998 | Pre 1998

Emacspeak Files | Emacspeak Blog | Search the archive