This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Amixer settings for BT to work on Panda Board

Need some help with the amixer settings for BT UL/DL (uplink and Downlink) to work from user space

Have attached the amixer/aplay/arecord settings as a text file.

It will good to know how to route the data from the BT_VX Switch to the Headset or save a raw pcm in user space by running the arecord as shown below.

Currently i'm trying to run these amixer settings, but nothing seems to happen

amixer cset name='MUX_UL10' 7
amixer cset name='MUX_UL11' 8
amixer cset name='DL1 BT_VX Switch' 1

arecord -f S32_LE -d 10 -D hw:0,13 record.wav

Any clues on why this should happen?

Logs attached below:

amixer output :
Simple mixer control 'Sidetone Equalizer',0
  Capabilities: enum
  Items: 'Flat response' 'High-pass 0dB' 'High-pass -12dB' 'High-pass -18dB'
  Item0: 'Flat response'
Simple mixer control 'Sidetone Mixer Capture',0
  Capabilities: pswitch pswitch-joined penum
  Playback channels: Mono
  Mono: Playback [off]
Simple mixer control 'Sidetone Mixer Playback',0
  Capabilities: pswitch pswitch-joined penum
  Playback channels: Mono
  Mono: Playback [on]
Simple mixer control 'Aux FM',0
  Capabilities: volume penum
  Playback channels: Front Left - Front Right
  Capture channels: Front Left - Front Right
  Limits: 0 - 7
  Front Left: 0 [0%] [-18.00dB]
  Front Right: 0 [0%] [-18.00dB]
Simple mixer control 'Capture',0
  Capabilities: cvolume penum
  Capture channels: Front Left - Front Right
  Limits: Capture 0 - 4
  Front Left: Capture 4 [100%] [30.00dB]
  Front Right: Capture 4 [100%] [30.00dB]
Simple mixer control 'Capture Mixer Media Playback',0
  Capabilities: pswitch pswitch-joined penum
  Playback channels: Mono
  Mono: Playback [off]
Simple mixer control 'Capture Mixer Tones',0
  Capabilities: pswitch pswitch-joined penum
  Playback channels: Mono
  Mono: Playback [off]
Simple mixer control 'Capture Mixer Voice Capture',0
  Capabilities: pswitch pswitch-joined penum
  Playback channels: Mono
  Mono: Playback [off]
Simple mixer control 'Capture Mixer Voice Playback',0
  Capabilities: pswitch pswitch-joined penum
  Playback channels: Mono
  Mono: Playback [off]
Simple mixer control 'Capture Preamplifier',0
  Capabilities: volume penum
  Playback channels: Front Left - Front Right
  Capture channels: Front Left - Front Right
  Limits: 0 - 1
  Front Left: 1 [100%] [0.00dB]
  Front Right: 1 [100%] [0.00dB]
Simple mixer control 'AMIC Equalizer',0
  Capabilities: enum
  Items: 'High-pass 0dB' 'High-pass -12dB' 'High-pass -18dB'
  Item0: 'High-pass 0dB'
Simple mixer control 'AMIC UL',0
  Capabilities: volume penum
  Playback channels: Front Left - Front Right
  Capture channels: Front Left - Front Right
  Limits: 0 - 149
  Front Left: 120 [81%] [0.00dB]
  Front Right: 120 [81%] [0.00dB]
Simple mixer control 'AUDUL Media',0
  Capabilities: volume volume-joined penum
  Playback channels: Mono
  Capture channels: Mono
  Limits: 0 - 149
  Mono: 0 [0%] [-99999.99dB]
Simple mixer control 'AUDUL Mono Mixer',0
  Capabilities: pswitch pswitch-joined penum
  Playback channels: Mono
  Mono: Playback [off]
Simple mixer control 'AUDUL Tones',0
  Capabilities: volume volume-joined penum
  Playback channels: Mono
  Capture channels: Mono
  Limits: 0 - 149
  Mono: 0 [0%] [-99999.99dB]
Simple mixer control 'AUDUL Voice DL',0
  Capabilities: volume volume-joined penum
  Playback channels: Mono
  Capture channels: Mono
  Limits: 0 - 149
  Mono: 0 [0%] [-99999.99dB]
Simple mixer control 'AUDUL Voice UL',0
  Capabilities: volume volume-joined penum
  Playback channels: Mono
  Capture channels: Mono
  Limits: 0 - 149
  Mono: 120 [81%] [0.00dB]
Simple mixer control 'AUXL',0
  Capabilities: pswitch pswitch-joined penum
  Playback channels: Mono
  Mono: Playback [off]
Simple mixer control 'AUXR',0
  Capabilities: pswitch pswitch-joined penum
  Playback channels: Mono
  Mono: Playback [off]
Simple mixer control 'Analog Left',0
  Capabilities: cenum
  Items: 'Headset Mic' 'Main Mic' 'Aux/FM Left' 'Off'
  Item0: 'Off'
Simple mixer control 'Analog Right',0
  Capabilities: cenum
  Items: 'Headset Mic' 'Sub Mic' 'Aux/FM Right' 'Off'
  Item0: 'Off'
Simple mixer control 'BT UL',0
  Capabilities: volume penum
  Playback channels: Front Left - Front Right
  Capture channels: Front Left - Front Right
  Limits: 0 - 149
  Front Left: 120 [81%] [0.00dB]
  Front Right: 120 [81%] [0.00dB]
Simple mixer control 'DL1 BT_VX',0
  Capabilities: pswitch pswitch-joined penum
  Playback channels: Mono
  Mono: Playback [off]
Simple mixer control 'DL1 Capture',0
  Capabilities: pvolume pvolume-joined penum
  Playback channels: Mono
  Limits: Playback 0 - 149
  Mono: Playback 0 [0%] [-99999.99dB]
Simple mixer control 'DL1 Equalizer',0
  Capabilities: enum
  Items: 'Flat response' 'High-pass 0dB' 'High-pass -12dB' 'High-pass -20dB' '4Khz LPF   0dB'
  Item0: 'Flat response'
Simple mixer control 'DL1 MM_EXT',0
  Capabilities: pswitch pswitch-joined penum
  Playback channels: Mono
  Mono: Playback [off]
Simple mixer control 'DL1 Media',0
  Capabilities: pvolume pvolume-joined penum
  Playback channels: Mono
  Limits: Playback 0 - 149
  Mono: Playback 90 [60%] [-30.00dB]
Simple mixer control 'DL1 Mixer Capture',0
  Capabilities: pswitch pswitch-joined penum
  Playback channels: Mono
  Mono: Playback [off]
Simple mixer control 'DL1 Mixer Multimedia',0
  Capabilities: pswitch pswitch-joined penum
  Playback channels: Mono
  Mono: Playback [on]
Simple mixer control 'DL1 Mixer Tones',0
  Capabilities: pswitch pswitch-joined penum
  Playback channels: Mono
  Mono: Playback [off]
Simple mixer control 'DL1 Mixer Voice',0
  Capabilities: pswitch pswitch-joined penum
  Playback channels: Mono
  Mono: Playback [off]
Simple mixer control 'DL1 Mono Mixer',0
  Capabilities: pswitch pswitch-joined penum
  Playback channels: Mono
  Mono: Playback [off]
Simple mixer control 'DL1 PDM',0
  Capabilities: pswitch pswitch-joined penum
  Playback channels: Mono
  Mono: Playback [on]
Simple mixer control 'DL1 Tones',0
  Capabilities: pvolume pvolume-joined penum
  Playback channels: Mono
  Limits: Playback 0 - 149
  Mono: Playback 0 [0%] [-99999.99dB]
Simple mixer control 'DL1 Voice',0
  Capabilities: pvolume pvolume-joined penum
  Playback channels: Mono
  Limits: Playback 0 - 149
  Mono: Playback 0 [0%] [-99999.99dB]
Simple mixer control 'DL2 Capture',0
  Capabilities: pvolume pvolume-joined penum
  Playback channels: Mono
  Limits: Playback 0 - 149
  Mono: Playback 0 [0%] [-99999.99dB]
Simple mixer control 'DL2 Left Equalizer',0
  Capabilities: enum
  Items: 'Flat response' 'High-pass 0dB' 'High-pass -12dB' 'High-pass -20dB' '450Hz High-pass'
  Item0: 'Flat response'
Simple mixer control 'DL2 Media',0
  Capabilities: pvolume pvolume-joined penum
  Playback channels: Mono
  Limits: Playback 0 - 149
  Mono: Playback 0 [0%] [-99999.99dB]
Simple mixer control 'DL2 Mixer Capture',0
  Capabilities: pswitch pswitch-joined penum
  Playback channels: Mono
  Mono: Playback [off]
Simple mixer control 'DL2 Mixer Multimedia',0
  Capabilities: pswitch pswitch-joined penum
  Playback channels: Mono
  Mono: Playback [off]
Simple mixer control 'DL2 Mixer Tones',0
  Capabilities: pswitch pswitch-joined penum
  Playback channels: Mono
  Mono: Playback [off]
Simple mixer control 'DL2 Mixer Voice',0
  Capabilities: pswitch pswitch-joined penum
  Playback channels: Mono
  Mono: Playback [off]
Simple mixer control 'DL2 Mono Mixer',0
  Capabilities: pswitch pswitch-joined penum
  Playback channels: Mono
  Mono: Playback [off]
Simple mixer control 'DL2 Right Equalizer',0
  Capabilities: enum
  Items: 'Flat response' 'High-pass 0dB' 'High-pass -12dB' 'High-pass -20dB' '450Hz High-pass'
  Item0: 'Flat response'
Simple mixer control 'DL2 Tones',0
  Capabilities: pvolume pvolume-joined penum
  Playback channels: Mono
  Limits: Playback 0 - 149
  Mono: Playback 0 [0%] [-99999.99dB]
Simple mixer control 'DL2 Voice',0
  Capabilities: pvolume pvolume-joined penum
  Playback channels: Mono
  Limits: Playback 0 - 149
  Mono: Playback 0 [0%] [-99999.99dB]
Simple mixer control 'DMIC Equalizer',0
  Capabilities: enum
  Items: 'High-pass 0dB' 'High-pass -12dB' 'High-pass -18dB'
  Item0: 'High-pass 0dB'
Simple mixer control 'DMIC1 UL',0
  Capabilities: volume penum
  Playback channels: Front Left - Front Right
  Capture channels: Front Left - Front Right
  Limits: 0 - 149
  Front Left: 120 [81%] [0.00dB]
  Front Right: 120 [81%] [0.00dB]
Simple mixer control 'DMIC2 UL',0
  Capabilities: volume penum
  Playback channels: Front Left - Front Right
  Capture channels: Front Left - Front Right
  Limits: 0 - 149
  Front Left: 120 [81%] [0.00dB]
  Front Right: 120 [81%] [0.00dB]
Simple mixer control 'DMIC3 UL',0
  Capabilities: volume penum
  Playback channels: Front Left - Front Right
  Capture channels: Front Left - Front Right
  Limits: 0 - 149
  Front Left: 120 [81%] [0.00dB]
  Front Right: 120 [81%] [0.00dB]
Simple mixer control 'Earphone',0
  Capabilities: pvolume pvolume-joined pswitch pswitch-joined penum
  Playback channels: Mono
  Limits: Playback 0 - 15
  Mono: Playback 0 [0%] [-24.00dB] [off]
Simple mixer control 'Handsfree',0
  Capabilities: pvolume penum
  Playback channels: Front Left - Front Right
  Limits: Playback 0 - 29
  Mono:
  Front Left: Playback 0 [0%] [-52.00dB]
  Front Right: Playback 0 [0%] [-52.00dB]
Simple mixer control 'Handsfree Left Playback',0
  Capabilities: enum
  Items: 'Off' 'HF DAC' 'Line-In amp'
  Item0: 'Off'
Simple mixer control 'Handsfree Right Playback',0
  Capabilities: enum
  Items: 'Off' 'HF DAC' 'Line-In amp'
  Item0: 'Off'
Simple mixer control 'Headset',0
  Capabilities: pvolume penum
  Playback channels: Front Left - Front Right
  Limits: Playback 0 - 15
  Mono:
  Front Left: Playback 13 [87%] [-4.00dB]
  Front Right: Playback 13 [87%] [-4.00dB]
Simple mixer control 'Headset Left Playback',0
  Capabilities: enum
  Items: 'Off' 'HS DAC' 'Line-In amp'
  Item0: 'HS DAC'
Simple mixer control 'Headset Power Mode',0
  Capabilities: enum
  Items: 'Low-Power' 'High-Perfomance'
  Item0: 'Low-Power'
Simple mixer control 'Headset Right Playback',0
  Capabilities: enum
  Items: 'Off' 'HS DAC' 'Line-In amp'
  Item0: 'HS DAC'
Simple mixer control 'MUX_UL00',0
  Capabilities: enum
  Items: 'None' 'DMic0L' 'DMic0R' 'DMic1L' 'DMic1R' 'DMic2L' 'DMic2R' 'BT Left' 'BT Right' 'MMExt Left' 'MMExt Right' 'AMic0' 'AMic1' 'VX Left' 'VX Right'
  Item0: 'MMExt Left'
Simple mixer control 'MUX_UL01',0
  Capabilities: enum
  Items: 'None' 'DMic0L' 'DMic0R' 'DMic1L' 'DMic1R' 'DMic2L' 'DMic2R' 'BT Left' 'BT Right' 'MMExt Left' 'MMExt Right' 'AMic0' 'AMic1' 'VX Left' 'VX Right'
  Item0: 'MMExt Right'
Simple mixer control 'MUX_UL02',0
  Capabilities: enum
  Items: 'None' 'DMic0L' 'DMic0R' 'DMic1L' 'DMic1R' 'DMic2L' 'DMic2R' 'BT Left' 'BT Right' 'MMExt Left' 'MMExt Right' 'AMic0' 'AMic1' 'VX Left' 'VX Right'
  Item0: 'None'
Simple mixer control 'MUX_UL03',0
  Capabilities: enum
  Items: 'None' 'DMic0L' 'DMic0R' 'DMic1L' 'DMic1R' 'DMic2L' 'DMic2R' 'BT Left' 'BT Right' 'MMExt Left' 'MMExt Right' 'AMic0' 'AMic1' 'VX Left' 'VX Right'
  Item0: 'None'
Simple mixer control 'MUX_UL04',0
  Capabilities: enum
  Items: 'None' 'DMic0L' 'DMic0R' 'DMic1L' 'DMic1R' 'DMic2L' 'DMic2R' 'BT Left' 'BT Right' 'MMExt Left' 'MMExt Right' 'AMic0' 'AMic1' 'VX Left' 'VX Right'
  Item0: 'None'
Simple mixer control 'MUX_UL05',0
  Capabilities: enum
  Items: 'None' 'DMic0L' 'DMic0R' 'DMic1L' 'DMic1R' 'DMic2L' 'DMic2R' 'BT Left' 'BT Right' 'MMExt Left' 'MMExt Right' 'AMic0' 'AMic1' 'VX Left' 'VX Right'
  Item0: 'None'
Simple mixer control 'MUX_UL06',0
  Capabilities: enum
  Items: 'None' 'DMic0L' 'DMic0R' 'DMic1L' 'DMic1R' 'DMic2L' 'DMic2R' 'BT Left' 'BT Right' 'MMExt Left' 'MMExt Right' 'AMic0' 'AMic1' 'VX Left' 'VX Right'
  Item0: 'None'
Simple mixer control 'MUX_UL07',0
  Capabilities: enum
  Items: 'None' 'DMic0L' 'DMic0R' 'DMic1L' 'DMic1R' 'DMic2L' 'DMic2R' 'BT Left' 'BT Right' 'MMExt Left' 'MMExt Right' 'AMic0' 'AMic1' 'VX Left' 'VX Right'
  Item0: 'None'
Simple mixer control 'MUX_UL10',0
  Capabilities: enum
  Items: 'None' 'DMic0L' 'DMic0R' 'DMic1L' 'DMic1R' 'DMic2L' 'DMic2R' 'BT Left' 'BT Right' 'MMExt Left' 'MMExt Right' 'AMic0' 'AMic1' 'VX Left' 'VX Right'
  Item0: 'None'
Simple mixer control 'MUX_UL11',0
  Capabilities: enum
  Items: 'None' 'DMic0L' 'DMic0R' 'DMic1L' 'DMic1R' 'DMic2L' 'DMic2R' 'BT Left' 'BT Right' 'MMExt Left' 'MMExt Right' 'AMic0' 'AMic1' 'VX Left' 'VX Right'
  Item0: 'None'
Simple mixer control 'MUX_VX0',0
  Capabilities: enum
  Items: 'None' 'DMic0L' 'DMic0R' 'DMic1L' 'DMic1R' 'DMic2L' 'DMic2R' 'BT Left' 'BT Right' 'MMExt Left' 'MMExt Right' 'AMic0' 'AMic1' 'VX Left' 'VX Right'
  Item0: 'None'
Simple mixer control 'MUX_VX1',0
  Capabilities: enum
  Items: 'None' 'DMic0L' 'DMic0R' 'DMic1L' 'DMic1R' 'DMic2L' 'DMic2R' 'BT Left' 'BT Right' 'MMExt Left' 'MMExt Right' 'AMic0' 'AMic1' 'VX Left' 'VX Right'
  Item0: 'None'
Simple mixer control 'PLL Selection',0
  Capabilities: enum
  Items: 'Low-Power' 'High-Perfomance'
  Item0: 'Low-Power'
Simple mixer control 'SDT DL',0
  Capabilities: volume volume-joined penum
  Playback channels: Mono
  Capture channels: Mono
  Limits: 0 - 149
  Mono: 120 [81%] [0.00dB]
Simple mixer control 'SDT UL',0
  Capabilities: volume volume-joined penum
  Playback channels: Mono
  Capture channels: Mono
  Limits: 0 - 149
  Mono: 0 [0%] [-99999.99dB]
Simple mixer control 'VXREC Media',0
  Capabilities: volume volume-joined penum
  Playback channels: Mono
  Capture channels: Mono
  Limits: 0 - 149
  Mono: 0 [0%] [-99999.99dB]
Simple mixer control 'VXREC Tones',0
  Capabilities: volume volume-joined penum
  Playback channels: Mono
  Capture channels: Mono
  Limits: 0 - 149
  Mono: 0 [0%] [-99999.99dB]
Simple mixer control 'VXREC Voice DL',0
  Capabilities: volume volume-joined penum
  Playback channels: Mono
  Capture channels: Mono
  Limits: 0 - 149
  Mono: 0 [0%] [-99999.99dB]
Simple mixer control 'VXREC Voice UL',0
  Capabilities: volume volume-joined penum
  Playback channels: Mono
  Capture channels: Mono
  Limits: 0 - 149
  Mono: 0 [0%] [-99999.99dB]
Simple mixer control 'Vibra Left Playback',0
  Capabilities: enum
  Items: 'Input FF' 'Audio PDM'
  Item0: 'Input FF'
Simple mixer control 'Vibra Right Playback',0
  Capabilities: enum
  Items: 'Input FF' 'Audio PDM'
  Item0: 'Input FF'
Simple mixer control 'Voice Capture Mixer Capture',0
  Capabilities: pswitch pswitch-joined penum
  Playback channels: Mono
  Mono: Playback [off]
Simple mixer control 'Voice Capture Mixer Media Playback',0
  Capabilities: pswitch pswitch-joined penum
  Playback channels: Mono
  Mono: Playback [off]
Simple mixer control 'Voice Capture Mixer Tones Playback',0
  Capabilities: pswitch pswitch-joined penum
  Playback channels: Mono
  Mono: Playback [off]

aplay >
**** List of PLAYBACK Hardware Devices ****
card 0: PandaES [PandaES], device 0: Multimedia (*) []
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PandaES [PandaES], device 2: Voice (*) []
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PandaES [PandaES], device 3: Tone Playback (*) []
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PandaES [PandaES], device 4: VIB-DL (*) []
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PandaES [PandaES], device 5: MODEM (*) []
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PandaES [PandaES], device 6: Multimedia (*) []
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PandaES [PandaES], device 8: Headset Playback twl6040-legacy-8 []
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PandaES [PandaES], device 9: (HS Playback) []
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PandaES [PandaES], device 11: (HF Playback) []
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PandaES [PandaES], device 12: (Vibra) []
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PandaES [PandaES], device 13: (BT Capture) []
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PandaES [PandaES], device 14: (BT Playback) []
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PandaES [PandaES], device 15: (FM Playback) []
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PandaES [PandaES], device 16: (FM Capture) []
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 1: OMAPHDMI [OMAPHDMI], device 0: HDMI omap-hdmi-hifi-0 []
  Subdevices: 1/1
  Subdevice #0: subdevice #0


arecord >
**** List of CAPTURE Hardware Devices ****
card 0: PandaES [PandaES], device 0: Multimedia (*) []
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PandaES [PandaES], device 1: Multimedia Capture (*) []
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PandaES [PandaES], device 2: Voice (*) []
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PandaES [PandaES], device 5: MODEM (*) []
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PandaES [PandaES], device 8: Headset Playback twl6040-legacy-8 []
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PandaES [PandaES], device 10: (Analog Capture) []
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PandaES [PandaES], device 13: (BT Capture) []
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PandaES [PandaES], device 14: (BT Playback) []
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PandaES [PandaES], device 15: (FM Playback) []
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PandaES [PandaES], device 16: (FM Capture) []
  Subdevices: 1/1
  Subdevice #0: subdevice #0
arecord: main:682: audio open error: No such file or directory


Thanks,

  • Replying to my own query...

    After some study and trials found a way of not crashing the board with the mixer commands as explained above.

    Again for the online community sake, i'm curently tapping the MCBSP1 port( BT interface) of the Panda Board ES Rev B3 board to connect our custom audio chip. The plan is get pcm data to the user space. After a little bit of hardware tweaking, i am in a state where the MCBSP port 1 complains of some parent clock issues. in my design the audio chip sends out the BitCLK, Frame sync to teh MCBSP1 and this is seen on the scope. All the signals look good. But once i execute the commands shown below, i get a mcbsp crash from the kernel.

    >:~$ amixer cset name='MUX_UL10' 7
    numid=56,iface=MIXER,name='MUX_UL10'
    ; type=ENUMERATED,access=rw------,values=1,items=15
    ; Item #0 'None'
    ; Item #1 'DMic0L'
    ; Item #2 'DMic0R'
    ; Item #3 'DMic1L'
    ; Item #4 'DMic1R'
    ; Item #5 'DMic2L'
    ; Item #6 'DMic2R'
    ; Item #7 'BT Left'
    ; Item #8 'BT Right'
    ; Item #9 'MMExt Left'
    ; Item #10 'MMExt Right'
    ; Item #11 'AMic0'
    ; Item #12 'AMic1'
    ; Item #13 'VX Left'
    ; Item #14 'VX Right'
    : values=7

    >:~$ amixer cset name='MUX_UL11' 8
    numid=55,iface=MIXER,name='MUX_UL11'
    ; type=ENUMERATED,access=rw------,values=1,items=15
    ; Item #0 'None'
    ; Item #1 'DMic0L'
    ; Item #2 'DMic0R'
    ; Item #3 'DMic1L'
    ; Item #4 'DMic1R'
    ; Item #5 'DMic2L'
    ; Item #6 'DMic2R'
    ; Item #7 'BT Left'
    ; Item #8 'BT Right'
    ; Item #9 'MMExt Left'
    ; Item #10 'MMExt Right'
    ; Item #11 'AMic0'
    ; Item #12 'AMic1'
    ; Item #13 'VX Left'
    ; Item #14 'VX Right'
    : values=8

    >arecord -f S32_LE -d 10 -D hw:0,1 test.wav

    dmesg logs with the crash:

    [ 173.097503] mcbsp_be_hw_params_fixup+
    [ 173.097534] be_id = 4
    [ 173.097534] mcbsp_be_hw_params_fixup-
    [ 173.097564] omap_abe_mcbsp_hw_params +
    [ 173.097595] omap_abe_mcbsp_hw_params 4
    [ 173.097595] Configure the BT device for audio
    [ 173.097625] omap_mcbsp_dai_set_dai_fmt +
    [ 173.097656] omap-mcbsp omap-mcbsp.1: **** McBSP1 regs ****
    [ 173.097686] omap-mcbsp omap-mcbsp.1: DRR2: 0x13d87029
    [ 173.097717] omap-mcbsp omap-mcbsp.1: DRR1: 0x0000
    [ 173.097747] omap-mcbsp omap-mcbsp.1: DXR2: 0x0000
    [ 173.097778] omap-mcbsp omap-mcbsp.1: DXR1: 0x0000
    [ 173.097778] omap-mcbsp omap-mcbsp.1: SPCR2: 0x0000
    [ 173.097808] omap-mcbsp omap-mcbsp.1: SPCR1: 0x0000
    [ 173.097839] omap-mcbsp omap-mcbsp.1: RCR2: 0x0000
    [ 173.097869] omap-mcbsp omap-mcbsp.1: RCR1: 0x0000
    [ 173.097900] omap-mcbsp omap-mcbsp.1: XCR2: 0x0000
    [ 173.097930] omap-mcbsp omap-mcbsp.1: XCR1: 0x0000
    [ 173.097930] omap-mcbsp omap-mcbsp.1: SRGR2: 0x2000
    [ 173.097961] omap-mcbsp omap-mcbsp.1: SRGR1: 0x0001
    [ 173.097991] omap-mcbsp omap-mcbsp.1: PCR0: 0x0000
    [ 173.098022] omap-mcbsp omap-mcbsp.1: ***********************
    [ 173.098052] omap_mcbsp_dai_set_dai_fmt -
    [ 173.098052] MCBSP1 is made the slave, gets the clk and sync from the codec
    [ 173.098083] omap_abe_mcbsp_hw_params -
    [ 173.098114] omap_mcbsp_dai_hw_params +
    [ 173.098144] omap-mcbsp omap-mcbsp.1: Configuring McBSP1 phys_base: 0x40122000
    [ 173.098144] omap_mcbsp_dai_hw_params -
    [ 173.103576] omap-mcbsp omap-mcbsp.1: **** McBSP1 regs ****
    [ 173.103607] omap-mcbsp omap-mcbsp.1: DRR2: 0x13d87029
    [ 173.103637] omap-mcbsp omap-mcbsp.1: DRR1: 0x0000
    [ 173.103668] omap-mcbsp omap-mcbsp.1: DXR2: 0x0000
    [ 173.103698] omap-mcbsp omap-mcbsp.1: DXR1: 0x0000
    [ 173.103698] omap-mcbsp omap-mcbsp.1: SPCR2: 0x0230
    [ 173.103729] omap-mcbsp omap-mcbsp.1: SPCR1: 0x0031
    [ 173.103759] omap-mcbsp omap-mcbsp.1: RCR2: 0x8041
    [ 173.103790] omap-mcbsp omap-mcbsp.1: RCR1: 0x0040
    [ 173.103820] omap-mcbsp omap-mcbsp.1: XCR2: 0x8041
    [ 173.103851] omap-mcbsp omap-mcbsp.1: XCR1: 0x0040
    [ 173.103881] omap-mcbsp omap-mcbsp.1: SRGR2: 0x001f
    [ 173.103881] omap-mcbsp omap-mcbsp.1: SRGR1: 0x0f00
    [ 173.103912] omap-mcbsp omap-mcbsp.1: PCR0: 0x000f
    [ 173.103942] omap-mcbsp omap-mcbsp.1: ***********************
    [ 174.784606] ------------[ cut here ]------------
    [ 174.784667] WARNING: at arch/arm/mach-omap2/clkt_clksel.c:75 _get_clksel_by_parent+0x58/0x70()
    [ 174.784698] clock: Could not find parent clock mcbsp2_sync_mux_ck in clksel array of clock mcbsp1_fck
    [ 174.784729] Modules linked in:
    [ 174.784759] Backtrace:
    [ 174.784820] [<c00129bc>] (dump_backtrace+0x0/0x114) from [<c056079c>] (dump_stack+0x20/0x24)
    [ 174.784851] r6:c0030f60 r5:00000009 r4:e995bd50 r3:c078e404
    [ 174.784942] [<c056077c>] (dump_stack+0x0/0x24) from [<c003e9a8>] (warn_slowpath_common+0x5c/0x74)
    [ 174.784973] [<c003e94c>] (warn_slowpath_common+0x0/0x74) from [<c003ea7c>] (warn_slowpath_fmt+0x40/0x48)
    [ 174.785034] r8:ed29ec00 r7:c07c7e58 r6:c0816f94 r5:c07c7df8 r4:00000000
    [ 174.785064] r3:00000009
    [ 174.785125] [<c003ea3c>] (warn_slowpath_fmt+0x0/0x48) from [<c0030f60>] (_get_clksel_by_parent+0x58/0x70)
    [ 174.785156] r3:c069ff89 r2:c06a65a1
    [ 174.785217] [<c0030f08>] (_get_clksel_by_parent+0x0/0x70) from [<c0031434>] (omap2_clksel_set_parent+0x44/0x100)
    [ 174.785247] r4:c07c7df8
    [ 174.785278] [<c00313f0>] (omap2_clksel_set_parent+0x0/0x100) from [<c00303c4>] (omap2_clk_set_parent+0x30/0x44)
    [ 174.785308] r7:a00f0113 r6:c0816f94 r5:c07c7df8 r4:c07c7e58
    [ 174.785400] [<c0030394>] (omap2_clk_set_parent+0x0/0x44) from [<c00357d8>] (clk_set_parent+0x84/0xbc)
    [ 174.785430] [<c0035754>] (clk_set_parent+0x0/0xbc) from [<c00246d0>] (omap2_mcbsp_set_clk_src+0xdc/0xfc)
    [ 174.785461] r7:c07c7df8 r6:ed201336 r5:ed223008 r4:c07c7e58
    [ 174.785552] [<c00245f4>] (omap2_mcbsp_set_clk_src+0x0/0xfc) from [<c03dd800>] (omap2_mcbsp_set_clks_src+0x4c/0x60)
    [ 174.785583] r7:ed2bce00 r6:ed0fa518 r5:ed20c000 r4:ed0fa510
    [ 174.785644] [<c03dd7b4>] (omap2_mcbsp_set_clks_src+0x0/0x60) from [<c03dd8d0>] (omap_mcbsp_free+0xbc/0x114)
    [ 174.785705] [<c03dd814>] (omap_mcbsp_free+0x0/0x114) from [<c03dc25c>] (omap_mcbsp_dai_shutdown+0x34/0x3c)
    [ 174.785736] r6:ed136300 r5:ed0fa510 r4:00000000 r3:c03dc228
    [ 174.785827] [<c03dc228>] (omap_mcbsp_dai_shutdown+0x0/0x3c) from [<c03d65b0>] (soc_pcm_close+0xdc/0x1f4)
    [ 174.785858] r5:ed3cc964 r4:ed133900
    [ 174.785888] [<c03d64d4>] (soc_pcm_close+0x0/0x1f4) from [<c03d6994>] (soc_dpcm_be_dai_shutdown+0xdc/0x130)
    [ 174.785949] [<c03d68b8>] (soc_dpcm_be_dai_shutdown+0x0/0x130) from [<c03d8390>] (soc_dpcm_fe_dai_close+0x5c/0x1ec)
    [ 174.786010] [<c03d8334>] (soc_dpcm_fe_dai_close+0x0/0x1ec) from [<c03c10b0>] (snd_pcm_release_substream+0x64/0xb4)
    [ 174.786071] [<c03c104c>] (snd_pcm_release_substream+0x0/0xb4) from [<c03c115c>] (snd_pcm_release+0x5c/0xac)
    [ 174.786102] r5:ed1b2000 r4:ed141e00
    [ 174.786163] [<c03c1100>] (snd_pcm_release+0x0/0xac) from [<c00f9fc0>] (fput+0x120/0x22c)
    [ 174.786193] r8:ed1299d0 r7:ebc4b550 r6:00000008 r5:ed3ec1c0 r4:e98bd9c0
    [ 174.786224] r3:c03c1100
    [ 174.786285] [<c00f9ea0>] (fput+0x0/0x22c) from [<c00f6214>] (filp_close+0x80/0x8c)
    [ 174.786346] [<c00f6194>] (filp_close+0x0/0x8c) from [<c00f62e0>] (sys_close+0xc0/0xf8)
    [ 174.786376] r6:ed20c540 r5:ed20c500 r4:00000004 r3:00000000
    [ 174.786437] [<c00f6220>] (sys_close+0x0/0xf8) from [<c000e440>] (ret_fast_syscall+0x0/0x30)
    [ 174.786468] r7:00000006 r6:b6f30000 r5:0002f5c8 r4:0002f618
    [ 174.786529] ---[ end trace 1b75b31a2719ed1e ]---
    [ 174.786560] omap-mcbsp: clks: could not clk_set_parent() to mcbsp2_sync_mux_ck

    Any reason why this is happening ? McBSP2 logs look to be fine and the audio works on that port. But if i test the McBSP1 DAI path end up with a error ...

    Also the code with the changes is pasted below:
    static int omap_abe_mcbsp_hw_params(struct snd_pcm_substream *substream,
    struct snd_pcm_hw_params *params)
    {
    struct snd_soc_pcm_runtime *rtd = substream->private_data;
    struct snd_soc_dai *cpu_dai = rtd->cpu_dai;
    struct snd_soc_card *card = rtd->card;
    int ret;
    unsigned int be_id, channels;
    printk("omap_abe_mcbsp_hw_params +\n");

    be_id = rtd->dai_link->be_id;

    printk("omap_abe_mcbsp_hw_params %d\n", be_id);

    if (be_id == OMAP_ABE_DAI_BT_VX) {
    printk(" Configure the BT device for audio\n");
    ret = snd_soc_dai_set_fmt(cpu_dai, SND_SOC_DAIFMT_I2S |
    SND_SOC_DAIFMT_NB_NF | SND_SOC_DAIFMT_CBM_CFM);
    }
    else

    /* Set cpu DAI configuration */
    ret = snd_soc_dai_set_fmt(cpu_dai, SND_SOC_DAIFMT_I2S |
    SND_SOC_DAIFMT_NB_NF | SND_SOC_DAIFMT_CBM_CFM);

    if (ret < 0) {
    dev_err(card->dev, "can't set cpu DAI configuration\n");
    return ret;
    }

    if (params != NULL) {
    struct omap_mcbsp *mcbsp = snd_soc_dai_get_drvdata(cpu_dai);
    /* Configure McBSP internal buffer usage */
    /* this need to be done for playback and/or record */
    channels = params_channels(params);
    if (substream->stream == SNDRV_PCM_STREAM_PLAYBACK)
    omap_mcbsp_set_tx_threshold(mcbsp, channels);
    else
    omap_mcbsp_set_rx_threshold(mcbsp, channels);
    }


    if (be_id == OMAP_ABE_DAI_BT_VX) {
    // not setting any clocks as this is in slave mode. is my assumption correct ?
    }
    #endif
    }
    else

    {

    /* Set McBSP clock to external */
    ret = snd_soc_dai_set_sysclk(cpu_dai, OMAP_MCBSP_SYSCLK_CLKS_FCLK,
    64 * params_rate(params), SND_SOC_CLOCK_IN);
    if (ret < 0)
    dev_err(card->dev, "can't set cpu system clock\n");
    }
    printk("omap_abe_mcbsp_hw_params -\n");
    return ret;
    }

    Any help is appreciated. I'm using the 3.4 kernel as part of the link given below :
    http://github.com/svtronics/kernel-pandaboard-ES-RevB3

    Thanks,
  • Hello All,

    Happy New Year!!!!

    Continuing with my debugging, i tried to fix the MCBSP crashes and was able to advance a little bit. The issue now is i capture only zeros from the MCBSP1 port and nothing else. Here are the register dump

    [ 122.232086] omap-mcbsp omap-mcbsp.1: **** McBSP1 regs ****
    [ 122.232116] omap-mcbsp omap-mcbsp.1: DRR2: 0x12d87429
    [ 122.232147] omap-mcbsp omap-mcbsp.1: DRR1: 0x0000
    [ 122.232177] omap-mcbsp omap-mcbsp.1: DXR2: 0x0000
    [ 122.232208] omap-mcbsp omap-mcbsp.1: DXR1: 0x0000
    [ 122.232208] omap-mcbsp omap-mcbsp.1: SPCR2: 0x0230
    [ 122.232238] omap-mcbsp omap-mcbsp.1: SPCR1: 0x0033
    [ 122.232269] omap-mcbsp omap-mcbsp.1: RCR2: 0x8041
    [ 122.232299] omap-mcbsp omap-mcbsp.1: RCR1: 0x0040
    [ 122.232330] omap-mcbsp omap-mcbsp.1: XCR2: 0x8041
    [ 122.232360] omap-mcbsp omap-mcbsp.1: XCR1: 0x0040
    [ 122.232391] omap-mcbsp omap-mcbsp.1: SRGR2: 0x001f
    [ 122.232421] omap-mcbsp omap-mcbsp.1: SRGR1: 0x0f00
    [ 122.232421] omap-mcbsp omap-mcbsp.1: PCR0: 0x000f
    [ 122.232452] omap-mcbsp omap-mcbsp.1: ***********************

    Here are the list of commnds i execute from my ubuntu OS with alsa utils

    amixer cset name='MUX_UL10' 7
    amixer cset name='MUX_UL11' 8
    amixer cset name='BT UL Volume' 120
    arecord -f S32_LE -r 16 -d 10 -D hw:0,1 test.wav

    Probed all the signals coming from the external chip and it all looked good at the input to the MCBSP1 pins. All i am trying to capture raw PCM samples to the user space, but just see zeros with the header info.

    Any clues on what i could be still missing ?

    Thanks,