Comments (6)
Hi!
In order to record calls there is a PulseAudio profile called voicecall-record which is available during an established voice call only. As soon as the sound card is in this profile, you can read downmixed voice call data from both parties from the primary sink. Basically that's what the Call Recorder does.
Can you please check if you can write a voice call audio using PA commands? As soon as the call is established. the card must be in voicecall profile:
$ pactl list cards | grep 'Active profile'
Active Profile: voicecall
Then put the card to voicecall-record profile:
$ pactl set-card-profile 0 voicecall-record
Then check if the card is in the voicecall-record profile using the first command. Then try playing with this command that writes data from the active sink:
$ parec --record --device=sink.primary --channels=1 --file-format=wav output.wav
If the output.wav contains feasible audio, then we'll look into Call Recorder itself, there might be some initialisation order to be changed or something.
Can you please also attach the full output of pacmd list-cards and pacmd list-sinks?
from harbour-callrecorder.
Thanks tor your quick reply!
First I stopped the Call Recorder daemon.
Then I checked the active profile, with no call it is "Active Profile: primary-primary"
and with voicecall going, it is "Active Profile: voicecall"
With call ongoing, I give the command "pactl set-card-profile 0 voicecall-record"
After that, the profile is "Active Profile: voicecall-record"
When I give the parec command, it fails with error message "Stream error: No such entity"
Here are the cards and sinks:
http://www.swagman.org/juice/list_cards.txt
http://www.swagman.org/juice/list_sinks.txt
from harbour-callrecorder.
Sorry, I should have tested the command myself before posting!
The exact command I've just used to record in voicecall-record mode is the following:
$ parec --record --device=sink.primary**.monitor** --file-format=wav --verbose output.wav
Can you please try this one out? You should be able to play the captured audio using
$ paplay output.wav
from harbour-callrecorder.
Thanks!
It indeed seems there is some glitch ongoing; I tried that and the parec command produced just a fairly small file. (2868 bytes for few minutes of call)
When the call ended, maybe 10 seconds after that the parec command timeouted.
Also, after the call was finished I checked "pactl list cards | grep 'Active'" and that command hung.
When I interrupted that and checked "top", it shows pulseaudio taking about 20% of CPU time...
This time the pulseaudio seems to be in busyloop, still taking 20% CPU after 10 minutes.
## Before voicecall
[nemo@Sailfish ~]$
[nemo@Sailfish ~]$ pactl list cards | grep 'Active'
Active Profile: primary-primary
## Now started voicecall
[nemo@Sailfish ~]$
[nemo@Sailfish ~]$ pactl list cards | grep 'Active'
Active Profile: voicecall
[nemo@Sailfish ~]$ pactl set-card-profile 0 voicecall-record
[nemo@Sailfish ~]$
[nemo@Sailfish ~]$ parec --record --device=sink.primary.monitor --file-format=wav --verbose output.wav
Opening a recording stream with sample specification 's16le 2ch 44100Hz' and channel map 'front-left,front-right'.
Connection established.
Stream successfully created.
Buffer metrics: maxlength=4194304, fragsize=352800
Using sample spec 's16le 2ch 44100Hz', channel map 'front-left,front-right'.
Connected to device source.primary (index: 5, suspended: no).
Failed to get latency: Timeout
[nemo@Sailfish ~]$
## command timeouted maybe 10 seconds after finishing call, and the next command hung.
[nemo@Sailfish ~]$ pactl list cards | grep 'Active'
^CGot SIGINT, exiting.
[nemo@Sailfish ~]$
[nemo@Sailfish ~]$ ls -latr *wav
-rw-rw-r-- 1 nemo nemo 2868 Aug 16 23:42 output.wav
[nemo@Sailfish ~]$
from harbour-callrecorder.
I can't really help you then, it seems to be a PulseAudio problem,..
@jusa , can you please take a look?
from harbour-callrecorder.
Thanks for looking into this anyway.
The fact that both devices work similarily up to the point of actually recording the audio, so that call establishing uses same method in pulseaudio leads me to believe that it is possible to get Call Recorder working for Hammerhead too, provided that this issue is fixed.
Most probably this is a bug in pulseaudio setup/environment rather than in the actual code.
I will have to try looking into it, though it is fairly complicated as I understand.
from harbour-callrecorder.
Related Issues (20)
- Not working in sailfish OS 2.0.1 HOT 1
- Очень тихи входящий сигнал HOT 3
- Feature request HOT 2
- Info on recording HOT 1
- Recording daemon stops on lipstick restart HOT 12
- 2.0.2 Aurajoki - Call recorder HOT 12
- Possible CRLF problems in launcher script HOT 1
- Possible build dependency missing: libarchive HOT 1
- Second sim not get recorded HOT 2
- Unknown numbers break UI
- Use speex instead of the FLAC codec
- Daemon crashes on startup on 2.1.0.9 HOT 1
- Install/Update error still present after all this time HOT 2
- Call Recorder problems with XperiaX HOT 1
- Fatal Error : Nothing provides libQt5Contacts.so.5 HOT 2
- Incoming calls record only silence in SFOS X 2.2.0 / Xperia X HOT 1
- SFOS 4.0.1 libcontactcache-qt5.so undefined symbol HOT 4
- aarch64 build?
- Sailfish 4.6 and libFLAC.so.8 HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from harbour-callrecorder.