I am creating a piano with the computer keyboard and I need to play '.wav' audio simultaneously.
I managed to do this perfectly using the SFML/Audio.hpp and SDL2/SDL_mixer.h libs, but the PlayAudio :: play () function of the code below takes a few…
I want to send large SysEx messages (which can be several Megabytes) through the ALSA sequencer:
Currently I split them into several ALSA events and send each of them in a loop like that:
while (1) {
result = snd_seq_event_output_direct(…
I wrote a simple C++ wrapper representing an AudioStream based on ALSA API. It seems to me very convenient to use the async mode. Unfortunately, the callback function registered for async mode doesn't get invoked.
The alsa documentation states for…
I'm using the asoundlib library to read sound (which is playing on my other PC and which I plugged into my external sound card) on my raspberry pi 4, first I tried using the mic input but apparently that shouldn't be used with amplified signals (my…
I want to record data from a microphone using alsa.
This command:
int buf[4096];
memset(buf, 0, sizeof(buf));
snd_pcm_readi(capture_handle, buf, avail);
writes the microphone data into the integer buffer buf. ( I am not sure if the data that is…
Problem statement: I do not receive the entire song in the output when dumped as a file (I can't hear the song through the jack but I could dump the file contents).
excerpts: I am new to ALSA programming and I have an embedded board with limited set…
Note: I have also created this as an issue for xgo here, but I thought it might be better suited as an SO question.
I am trying to cross compile my go application and one of the dependencies is the alsa.lib. I cannot get this to sucessfully compile…
For example I have a simple play() function that plays arbitrary tone just fine. The problem is that as soon as I decide to stop playing tone ALSA produces click/pop sound. I've already tried using snd_pcm_drain(), stopping tone when it finishes…
Can I use ALSA library for transcoding of audio from one format to another.
i.e S32 2 channels to S16 1 Channel audio from file as input source to file output
In one of link I saw statement,
Plugin: File
This plugin stores contents of a PCM stream…
I was going through alsa library code, I wanted to know read function that is being used. However I see there are more than one version of read functions.
i.e
.readi = snd_pcm_hw_readi
.readi = snd_pcm_ioplug_readi
.readi =…
I was using a sample C ALSA program as reference and ran along the following piece of code:
...
snd_ctl_event_t *event;
snd_ctl_event_alloca(&event);
...
Based on the ALSA source code, snd_ctl_event_alloca is a macro that calls __snd_alloca which…
I've got a dedicated thread that caputures audio from Alsa through snd_pcm_readi(). Recording happens fine for some 30 mins (each file of one minute duration), After that file size gradually decreases and results in "read from audio interface…
I have a embedded platform with two audiocodec. One is a tlv320aic3x (I2S) codec and the other is a USB Codec. The scenario is that a rtp stream is forwarded with a PjProject conferencer to the two codecs. When the call is established there is a…
I am able to record 8 channel mic audio (32bit audio but actual content is 24bit with 8 bit padding) in below format using alsa utils (pcm_read):
t0: channel 0, channel 1, channel 2, ....., channel 8
t1: channel 0, channel 1, channel 2, .....,…
I have a working VU meter plugin but wish to combine it with a spectrum analyzer however both have their own /etc/asound.conf. I want to combine the two together but nothing I have tried works because of the loopback that the spectrum requires. …