On Friday, July 26, 2019 at 1:24:57 PM UTC-4, Claudia wrote:

> Just to humor myself, I was going to try testing if I could hear sound 
> from Qubes after resume, but it seems audio isn't working at all. Which 
> is a whole 'nother problem. Aplay says "... unable to open slave; audio 
> open error: no such file or directory." `echo -e '\a'` doesn't work even 
> on a TTY (lsmod shows pcspkr), and `beep` isn't installed. 
>

Notably, Xen does not pass the real PC speaker device to dom0 and while it 
simulates it for dom0, it does not actually invoke the hardware. Something 
something considered dangerous to expose adjacent-to-speaker hardware in 
dom0, apparently.

So terminal beeps, etc. do nothing (except maybe flash the terminal window, 
depending on your config).

I use a snippet I got from google:
function create_beep () {
    # create our beep file as xen does not expose the real "bell" device w/i
n the Qubes configuration and a simple echo "\007" does not work.
    > /tmp/sinewave.wav
    printf "\x52\x49\x46\x46\x64\x1F\x00\x00\x57\x41\x56\x45\x66\x6D\x74\x20
\x10\x00\x00\x00\x01\x00\x01\x00\x40\x1F\x00\x00\x40\x1F\x00\x00\x01\x00\x08\x00
\x64\x61\x74\x61\x40\x1F\x00\x00" >> /tmp/sinewave.wav
    for n in {0..999}
    do
            printf "\x80\x26\x00\x26\x7F\xD9\xFF\xD9" >> /tmp/sinewave.wav
    done
}

And then invoke the following when I need a beep (probably should be made a 
function) in scripts dom0: 

  aplay -q /tmp/sinewave.wav --duration=1
 
Brendan

-- 
You received this message because you are subscribed to the Google Groups 
"qubes-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to qubes-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/qubes-users/cdc16c4b-a197-48e7-b9aa-6a487cd43383%40googlegroups.com.

Reply via email to