* reading peak meter values from a RME HDSP madi soundcard
@ 2008-03-14 14:16 ListsAccount
0 siblings, 0 replies; only message in thread
From: ListsAccount @ 2008-03-14 14:16 UTC (permalink / raw)
To: alsa-devel
Hi,
I'd like to read the peak values of the RME HDSP madi soundcard. To do
this, I use the function: snd_hwdep_ioctl() with the ioctl command
"SNDRV_HDSPM_IOCTL_GET_PEAK_RMS".
I use the following code:
// create container
hdspm_peak_rms_t madi_peak_rms;
hdspm_peak_rms_t* ptr_madi_peak_rms = &madi_peak_rms;
//snd_hwdep_open
...
// fill the container with values
snd_hwdep_ioctl(hw,
SNDRV_HDSPM_IOCTL_GET_PEAK_RMS,
(void *)&ptr_madi_peak_rms);
for (unsigned int chn = 0; chn < numberOfChannels; ++chn)
{
//put values from madi soundcard into std::vector containers
currentInputPeak[chn] = madi_peak_rms.level_offset[chn];
currentPlaybackPeak[chn] = madi_peak_rms.level_offset[chn+64];
currentOutputPeak[chn] = madi_peak_rms.level_offset[chn+128];
}
The upper 24 bit of the read out values should be the signal peak. The
next 8 bit seem to represent a clipping counter.
For the first eight input channels this works pretty well. But for every
eighth channel of all further channels (input, playback and output) the
peak value is to low and is not in time with the other channels.
Do i use the function in the right way?
Is there a special function to get the peak meter values? (In a similar
way as for ADAT soundcards?)
Best regards.
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2008-03-14 14:16 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-03-14 14:16 reading peak meter values from a RME HDSP madi soundcard ListsAccount
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox