mcasp and alsasrc for dm6467



I have a question regarding alsasrc used on a dm6467.


I have a pipeline that capture audio using mcasp (RX_MODE), encode and stream it over the ner (RTP).

I'm observing that it works ok if I set provide-clock=false as alsasrc parameter.

Not good if I set provide-clock=true.

What does it mean?


another question:

I'm using MCASP0 in RX_MODE with 2 serializer.

I receive AHCLKR from an external clock (that is clocked with the video clock), to avoid audio-video unsync.


But I don't uderstand how to have 2 input video in sync with the audio if the audio clock of mcasp0 is only one!




4 Replies

  • how can I provide the real master clock AHCLKR to alsasrc ?


  • In reply to Claudio Filipponi:


    making some progress...

    Looking into the /mach-davinci/time.c code ...

             * Configure the 2 64-bit timer as 4 32-bit timers with
             * following assignments.
             * T0_BOT: Timer 0, bottom:  AV Sync
             * T0_TOP: Timer 0, top:  free-running counter,
             *                        used for cycle counter
             * T1_BOT: Timer 1, bottom:  reserved for DSP
             * T1_TOP: Timer 1, top   :  Linux system tick
            tid_system = T1_TOP;
            tid_freerun = T0_TOP;

    Both system and freerun user internal clock source.

    For streaming application, I'm using an external audio master clock (24576000 Hz ) as T0_BOT time. So now I have a clocksource in time with this external clock.

    How can provide this audio clock to ALSA ?

  • In reply to Claudio Filipponi:

    I don't see any T0_BOT configuration in the code ...

    Is there any place where to set the codec master clock, in order to have a correct configuration for capture timer ?

    cat /proc/asound/timers
    G0: system timer : 10000.000us (10000000 ticks)
    P0-0-1: PCM capture 0-0-1 : SLAVE



  • What do you mean with "Not good if I set provide-clock=true" ? provide-clock=true is the default setting and I guess it is working for me on DM6446. I just encounter another problem with alsasrc, as postet in

    And how do you create a pipe that captures audio using mcasp (RX_MODE) - actually you don't worry about McASP if you are going through ALSA, aren't you? (I guess you are talking about streamer pipes)