-
-
Notifications
You must be signed in to change notification settings - Fork 106
This issue was moved to a discussion.
You can continue the conversation there. Go to discussion →
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Example for receive a call and record it #80
Comments
Are you sure that you receive 2 Bytes = 16 Bit? Normally you will get 8 Bit = 1 Byte. It worked for me, and the saved audio-file is totally okay. My Code:
|
That's correct, PCMU/A is 8 bit |
Thanks, sometimes the right solution is so easy. It works for me too. |
This code works, recording is permanently. How can i stop recording by time or (will be better) by silent in channel?
|
You could probably do something like: if data != b"\x80" * len(data):
w.writeframes(data) |
I'm trying to record a few seconds of a certain part in a call. However, I can't even get a simple recording to work properly... I want to save a recording as a .wav file. What am I missing here?
|
Don't use print() in the function answer(). If you need logging then use recording into a file. Parameter "blocking" better left by default. |
@TipsTricksMore, definitely heed what @Koshkodav said about blocking. But I think your problem is you don't want to be using |
I am getting only a 0-sec file what am I doing wrong? |
I believe the issue you are having is the |
This issue was moved to a discussion.
You can continue the conversation there. Go to discussion →
I try to record the call. For this I use this part in the callback function answer
This writes a wav file, but I only get is very noisy. I think the parameters in setparams a not right. But I don't know what to set here.
The text was updated successfully, but these errors were encountered: