[raspberry-vi] Re: What a day. broke my raspbian install among other things.

  • From: Didier Spaier <didier@xxxxxxxx>
  • To: raspberry-vi@xxxxxxxxxxxxx
  • Date: Fri, 20 Mar 2020 15:58:24 +0100

Mike,

I concur with what you wrote about the speech-dispatcher modules.

Not loosing speech when switching between graphical and console
sessions may be a bit tricky but is quite feasible.

Here is how it's done in Slint, for the records. I am not saying that's
the only way, only that this way works.

1. Do not have any configuration file that redirects the audio output
from alsa to pulseaudio. What could be the offending file depends on the
distribution you use.
2. set pulseaudio to use dmix and dsnoop. This can be done including
these two lines in /etc/pulse.default.pa for instance:
load-module module-alsa-sink device=dmix
load-module module-alsa-source device=dsnoop
3. Start pulseaudio on demand (i.e. when an application requires it),
instead of when opening a session. This can be achieved for instance
writing in /etc/xdg/autostart/pulseaudio.desktop:
Hidden=true

With these settings, you can have speech:
1. To log in in console mode using espeakup, fenrir or speechd-up
2. To log in using a graphical login manager (lihgtdm or gdm) using Orca
3. In a graphical session (Mate, LXDE, Xfce, Fluxbox, ...) using Orca 
4. In espeakup and speechd-el, barnard, mumble, pidgin, ...
5. When switching from console mode to a graphical environment and
   reverse

I recommend to dynamically link espeakup to espeak-ng, not espeak,
and to exclusively use espeak-ng, to avoid issues when swithcing from
a grahical environment to a console  

Allows this allows alsa and pulseaudio to coxist peacefully 

As I previously wrote we do set libao as audio output method in
/etc/speech-dispatcher/speechd.conf and alsa as default driver
in /etc/libao.conf. I had no complaint so far about another app
like a misc player having issues because of that. 

As an aside, the Firefox we ship relies on pulseaudio. This works
well, however the pulseaudio haters may start it like this:
apulse firefox <smile>

Instructive reading about pulseaudio for who didn't come across it yet:
https://gavv.github.io/articles/pulseaudio-under-the-hood/

As Slackware does we ship two versions of emacs: emacs (aka emacs-nox)
and xemacs.

Cheers,
Didier

Le 20/03/2020 à 15:12, Mike Ray a écrit :

Guys,

A couple of things about speech-dispatcher, pulse and aALSA.

Firstly, whatever you put in the SD config file, it will load ALL of the
speech modules, that is ALL the files which begin with sd_ in I can't
remember which directory.  So, to lighten the load on a Pi, it is a good
idea to delete, or remove from that directory ALL the sd_ modules you
don't want to use.

I just looked up the path but don't want to edit the above path, the
modules are in:

/usr/lib/speech-dispatcher-modules

Remember, it matters not what these files are called, they will all be
loaded even if they are commented out in the config, making the
footprint of SD bigger.

Secondly, there is a bug in the sd_espeak module which causes it to
crash and be unloaded if SD is run with the AudioOutputMethod set to 'alsa'.

This causes Orca to go silent very often and randomly.

In order to avoid using ALSA or pulse, set the AudioOutputMethod to
'libao'.  You will have to install the libao libraries.

Thirdly, if you run SD in pulse mode, the console will go silent once
the GUI is launched if you are using speakup in the console.  I think
this is because of the way espeak selects which audio library to use.

As far as I have ever been able to figure out, if pulse is already
running, because it has been spawned by SD, espeak tries to use it
instead of ALSA or libao, but SD is not running as the console's logged
in user, so it fails.  The result is a silent console.  I find pulse a
right royal pain and have never been able to figure out how to solve
this, mostly because pulse winds me up to a temper in a very few minutes.

You may be able to avoid this by using Fenrir with SD instead of speakup.

For this third reason, I never personally regard any Linux as being
truly accessible unless both any installed GUI, and the console, or
virtual console, is accessible.  For this reason I usually use libao and
not pulse.  But this might screw up other sound apps like music players,
or might cause speakup to again go silent when SD is spawned by another app.

Also, if you want to use emacs and possibly emacspeak, I would suggest
you install emacs-nox, not the X version of emacs.

Mike



On 20/03/2020 11:09, Pranav Lal wrote:
Jessica,

You need  speech dispatcher for orca. The thing is that you need to ensure
that speech-dispatcher is working on the commandline before launching the
gui. 

I think you also need pulse audio for orca.

Pranav

-----Original Message-----
From: raspberry-vi-bounce@xxxxxxxxxxxxx <raspberry-vi-bounce@xxxxxxxxxxxxx>
On Behalf Of Jessica
Sent: Friday, March 20, 2020 1:45 PM
To: raspberry-vi@xxxxxxxxxxxxx
Subject: [raspberry-vi] What a day. broke my raspbian install among other
things.

At first I didn't install speech dispatcher. Then I thought hmmm wonder if I
install speech dispatcher. Got my speech back when I did that. But when I
signed into the gui again. No speech sigh. And it knocked out my system
again.
Wondering if speech-dispatcher being installed first before I do all the
other stuff would work.

Maybe something needed something and it wasn't there when orca installed.

Even stupidly installed pulseaudio sigh. But lol. I was fooling around. I
really wanted to try and get it working before I started over.

I will try again. just not on this sd card. Deciding whether I want to use
my only left SD card to try again.

At least then my working system won't be affected *smiles*.

Anyway. Yes. I plan on trying again. Just on another SD card.


=========================================================== 
The raspberry-vi mailing list 
Archives: //www.freelists.org/archives/raspberry-vi
Administrative contact: <mike.ray@xxxxxxxxxxxxxx>
-----------------------------------------------------------
Raspberry Pi and the Raspberry Pi logo are trademarks of the Raspberry Pi
Foundation.

This list is not affiliated to the Raspberry Pi Foundation and the views and
attitudes expressed by the subscribers to this list do not reflect those of
the Foundation.

Mike Ray, list creator, January 2013

=========================================================== 
The raspberry-vi mailing list 
Archives: //www.freelists.org/archives/raspberry-vi
Administrative contact: <mike.ray@xxxxxxxxxxxxxx>
-----------------------------------------------------------
Raspberry Pi and the Raspberry Pi logo are trademarks of the Raspberry Pi 
Foundation.

This list is not affiliated to the Raspberry Pi Foundation and the views and 
attitudes expressed by the subscribers to this list do not reflect those of 
the Foundation.

Mike Ray, list creator, January 2013



=========================================================== 
The raspberry-vi mailing list 
Archives: //www.freelists.org/archives/raspberry-vi
Administrative contact: <mike.ray@xxxxxxxxxxxxxx>
-----------------------------------------------------------
Raspberry Pi and the Raspberry Pi logo are trademarks of the Raspberry Pi 
Foundation.

This list is not affiliated to the Raspberry Pi Foundation and the views and 
attitudes expressed by the subscribers to this list do not reflect those of the 
Foundation.

Mike Ray, list creator, January 2013

Other related posts: