* custom audio card on beaglebone
@ 2017-01-22 21:38 jo
2017-01-22 23:47 ` anish singh
0 siblings, 1 reply; 4+ messages in thread
From: jo @ 2017-01-22 21:38 UTC (permalink / raw)
To: kernelnewbies
Hi everyone,
I am currently trying to get a simple audio I2S DAC board
(https://polyvection.com/shop/plaindac/) to work on a beaglebone green
wireless. The components is a PCM5121, a popular one that has an
existing driver.
so far,
- I have a custom compiled kernel with the apropriate driver compiled
$ grep PCM512 .config
CONFIG_SND_SOC_PCM512x=m
CONFIG_SND_SOC_PCM512x_I2C=m
- I can boot with a custom device tree including my definition of the
board as an "asoc-simple-card" and it get recognise without error on boot.
root at beaglebone:~# dmesg |grep sound
[ 28.730678] asoc-simple-card sound: pcm512x-hifi <-> 48038000.mcasp
mapping ok
root at beaglebone:~# lsmod |grep pcm512
snd_soc_pcm512x_i2c 2782 1
snd_soc_pcm512x 24341 1 snd_soc_pcm512x_i2c
snd_soc_core 192029 5
snd_soc_pcm512x,snd_soc_davinci_mcasp,snd_soc_edma,snd_soc_omap,snd_soc_simple_card
snd_pcm 103172 6
snd_soc_pcm512x,snd_soc_davinci_mcasp,snd_soc_core,snd_soc_omap,snd_pcm_dmaengine
- I can open the device with alsamixer, and can confirm the sound is on 100%
Howewer, I still can't get any sound of the device.
Does someone has experience in regards to asoc audio device and cant
give me some thought on easy to miss things ?
I am still trying to figure out if I have omitted something on the
device tree, or if I need to configure something more on the OS (alsa,
pulseaudio ?)...
I have attached my device tree, if someone feel like giving a look at
it. (my addition from the original one comes after line 73).
Also some output that may give you more info that they are giving to me:
root at beaglebone:~# aplay -v Pom\ Pom.wav
Playing WAVE 'Pom Pom.wav' : Signed 32 bit Little Endian, Rate 44100 Hz,
Stereo
ALSA <-> PulseAudio PCM I/O Plugin
Its setup is:
stream : PLAYBACK
access : RW_INTERLEAVED
format : S32_LE
subformat : STD
channels : 2
rate : 44100
exact rate : 44100 (44100/1)
msbits : 32
buffer_size : 22050
period_size : 5512
period_time : 125000
tstamp_mode : NONE
period_step : 1
avail_min : 5512
period_event : 0
start_threshold : 22050
stop_threshold : 22050
silence_threshold: 0
silence_size : 0
boundary : 1445068800
#nothing play and the above stay displayed -as is- until I ctrl-c
root at beaglebone:~# aplay -l
**** List of PLAYBACK Hardware Devices ****
card 0: plaindac [plaindac], device 0: davinci-mcasp.0-pcm512x-hifi
pcm512x-hifi-0 []
Subdevices: 0/1
Subdevice #0: subdevice #0
root at beaglebone:~# cat /proc/asound/card0/pcm0p/info
card: 0
device: 0
subdevice: 0
stream: PLAYBACK
id: davinci-mcasp.0-pcm512x-hifi pcm512x-hifi-0on
name:
subname: subdevice #0
class: 0
subclass: 0
subdevices_count: 1
subdevices_avail: 0
Regards,
Jonathan.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: am335x-bonegreen-wireless-pcm.dts
Type: audio/vnd.dts
Size: 3399 bytes
Desc: not available
Url : http://lists.kernelnewbies.org/pipermail/kernelnewbies/attachments/20170122/c982be48/attachment.bin
^ permalink raw reply [flat|nested] 4+ messages in thread
* custom audio card on beaglebone
2017-01-22 21:38 custom audio card on beaglebone jo
@ 2017-01-22 23:47 ` anish singh
2017-01-25 10:30 ` crazyiop at gmail.com
0 siblings, 1 reply; 4+ messages in thread
From: anish singh @ 2017-01-22 23:47 UTC (permalink / raw)
To: kernelnewbies
On Sun, Jan 22, 2017 at 1:38 PM, jo <crazyiop@gmail.com> wrote:
> Hi everyone,
>
> I am currently trying to get a simple audio I2S DAC board (
> https://polyvection.com/shop/plaindac/) to work on a beaglebone green
> wireless. The components is a PCM5121, a popular one that has an existing
> driver.
>
> so far,
> - I have a custom compiled kernel with the apropriate driver compiled
> $ grep PCM512 .config
> CONFIG_SND_SOC_PCM512x=m
> CONFIG_SND_SOC_PCM512x_I2C=m
>
>
> - I can boot with a custom device tree including my definition of the
> board as an "asoc-simple-card" and it get recognise without error on boot.
>
> root at beaglebone:~# dmesg |grep sound
> [ 28.730678] asoc-simple-card sound: pcm512x-hifi <-> 48038000.mcasp
> mapping ok
> root at beaglebone:~# lsmod |grep pcm512
> snd_soc_pcm512x_i2c 2782 1
> snd_soc_pcm512x 24341 1 snd_soc_pcm512x_i2c
> snd_soc_core 192029 5 snd_soc_pcm512x,snd_soc_davinc
> i_mcasp,snd_soc_edma,snd_soc_omap,snd_soc_simple_card
> snd_pcm 103172 6 snd_soc_pcm512x,snd_soc_davinc
> i_mcasp,snd_soc_core,snd_soc_omap,snd_pcm_dmaengine
>
>
> - I can open the device with alsamixer, and can confirm the sound is on
> 100%
>
> Howewer, I still can't get any sound of the device.
>
> Does someone has experience in regards to asoc audio device and cant give
> me some thought on easy to miss things ?
> I am still trying to figure out if I have omitted something on the device
> tree, or if I need to configure something more on the OS (alsa, pulseaudio
> ?)...
>
> I have attached my device tree, if someone feel like giving a look at it.
> (my addition from the original one comes after line 73).
> Also some output that may give you more info that they are giving to me:
>
> root at beaglebone:~# aplay -v Pom\ Pom.wav
> Playing WAVE 'Pom Pom.wav' : Signed 32 bit Little Endian, Rate 44100 Hz,
> Stereo
> ALSA <-> PulseAudio PCM I/O Plugin
> Its setup is:
> stream : PLAYBACK
> access : RW_INTERLEAVED
> format : S32_LE
> subformat : STD
> channels : 2
> rate : 44100
> exact rate : 44100 (44100/1)
> msbits : 32
> buffer_size : 22050
> period_size : 5512
> period_time : 125000
> tstamp_mode : NONE
> period_step : 1
> avail_min : 5512
> period_event : 0
> start_threshold : 22050
> stop_threshold : 22050
> silence_threshold: 0
> silence_size : 0
> boundary : 1445068800
>
> #nothing play and the above stay displayed -as is- until I ctrl-c
>
Possible that you have not turned on the mixer controls i.e.
enabling the volume?
Check sw_ptr and hw_ptr and see if those are increasing or not?
Probe the I2S lines and see if there is any data?
>
>
> root at beaglebone:~# aplay -l
> **** List of PLAYBACK Hardware Devices ****
> card 0: plaindac [plaindac], device 0: davinci-mcasp.0-pcm512x-hifi
> pcm512x-hifi-0 []
> Subdevices: 0/1
> Subdevice #0: subdevice #0
>
>
> root at beaglebone:~# cat /proc/asound/card0/pcm0p/info
> card: 0
> device: 0
> subdevice: 0
> stream: PLAYBACK
> id: davinci-mcasp.0-pcm512x-hifi pcm512x-hifi-0on
> name:
> subname: subdevice #0
> class: 0
> subclass: 0
> subdevices_count: 1
> subdevices_avail: 0
>
>
> Regards,
> Jonathan.
>
> _______________________________________________
> Kernelnewbies mailing list
> Kernelnewbies at kernelnewbies.org
> https://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.kernelnewbies.org/pipermail/kernelnewbies/attachments/20170122/a58c7fef/attachment.html
^ permalink raw reply [flat|nested] 4+ messages in thread
* custom audio card on beaglebone
2017-01-22 23:47 ` anish singh
@ 2017-01-25 10:30 ` crazyiop at gmail.com
2017-01-25 23:35 ` anish singh
0 siblings, 1 reply; 4+ messages in thread
From: crazyiop at gmail.com @ 2017-01-25 10:30 UTC (permalink / raw)
To: kernelnewbies
Hi Anish,
thanks for giving me some thougt.
Here is what I found:
On Sun, Jan 22, 2017 at 03:47:54PM -0800, anish singh wrote:
> On Sun, Jan 22, 2017 at 1:38 PM, jo <crazyiop@gmail.com> wrote:
>
> > root at beaglebone:~# aplay -v Pom\ Pom.wav
> > Playing WAVE 'Pom Pom.wav' : Signed 32 bit Little Endian, Rate 44100 Hz,
> > Stereo
> > ALSA <-> PulseAudio PCM I/O Plugin
> > Its setup is:
> > stream : PLAYBACK
> > access : RW_INTERLEAVED
> > format : S32_LE
> > subformat : STD
> > channels : 2
> > rate : 44100
> > exact rate : 44100 (44100/1)
> > msbits : 32
> > buffer_size : 22050
> > period_size : 5512
> > period_time : 125000
> > tstamp_mode : NONE
> > period_step : 1
> > avail_min : 5512
> > period_event : 0
> > start_threshold : 22050
> > stop_threshold : 22050
> > silence_threshold: 0
> > silence_size : 0
> > boundary : 1445068800
> >
> > #nothing play and the above stay displayed -as is- until I ctrl-c
> >
>
> Possible that you have not turned on the mixer controls i.e.
> enabling the volume?
>
> Check sw_ptr and hw_ptr and see if those are increasing or not?
>
> Probe the I2S lines and see if there is any data?
>
>
So first, the above command in fact do finish after the length of the file (I
thought I took a much smaller test sample..)
The mixer control were all on and volume to the max.
I don't have a scope, but you made me realize that I'm clueless in front
of my problem without one... So I finnaly found an access to one. The measure
show that the input clock of the pll (mclk) is just non-existant.
I now know what to look for.
I tried to find a reference to those sw_ptr and hw_ptr somewhere,
without success, what are they and where can I find/probe them ?
Thanks!!
Jonathan.
^ permalink raw reply [flat|nested] 4+ messages in thread
* custom audio card on beaglebone
2017-01-25 10:30 ` crazyiop at gmail.com
@ 2017-01-25 23:35 ` anish singh
0 siblings, 0 replies; 4+ messages in thread
From: anish singh @ 2017-01-25 23:35 UTC (permalink / raw)
To: kernelnewbies
On Wed, Jan 25, 2017 at 2:30 AM, <crazyiop@gmail.com> wrote:
> Hi Anish,
>
> thanks for giving me some thougt.
> Here is what I found:
>
> On Sun, Jan 22, 2017 at 03:47:54PM -0800, anish singh wrote:
> > On Sun, Jan 22, 2017 at 1:38 PM, jo <crazyiop@gmail.com> wrote:
> >
> > > root at beaglebone:~# aplay -v Pom\ Pom.wav
> > > Playing WAVE 'Pom Pom.wav' : Signed 32 bit Little Endian, Rate 44100
> Hz,
> > > Stereo
> > > ALSA <-> PulseAudio PCM I/O Plugin
> > > Its setup is:
> > > stream : PLAYBACK
> > > access : RW_INTERLEAVED
> > > format : S32_LE
> > > subformat : STD
> > > channels : 2
> > > rate : 44100
> > > exact rate : 44100 (44100/1)
> > > msbits : 32
> > > buffer_size : 22050
> > > period_size : 5512
> > > period_time : 125000
> > > tstamp_mode : NONE
> > > period_step : 1
> > > avail_min : 5512
> > > period_event : 0
> > > start_threshold : 22050
> > > stop_threshold : 22050
> > > silence_threshold: 0
> > > silence_size : 0
> > > boundary : 1445068800
> > >
> > > #nothing play and the above stay displayed -as is- until I ctrl-c
> > >
> >
> > Possible that you have not turned on the mixer controls i.e.
> > enabling the volume?
> >
> > Check sw_ptr and hw_ptr and see if those are increasing or not?
> >
> > Probe the I2S lines and see if there is any data?
> >
> >
>
> So first, the above command in fact do finish after the length of the file
> (I
> thought I took a much smaller test sample..)
>
> The mixer control were all on and volume to the max.
> I don't have a scope, but you made me realize that I'm clueless in front
> of my problem without one... So I finnaly found an access to one. The
> measure
> show that the input clock of the pll (mclk) is just non-existant.
> I now know what to look for.
>
> I tried to find a reference to those sw_ptr and hw_ptr somewhere,
> without success, what are they and where can I find/probe them ?
>
# cat /proc/asound/card0/pcm0p/sub0/status
state: RUNNING
owner_pid : 1440
trigger_time: 16024.849105290
tstamp : 16175.605386326
delay : 768
avail : 1280
avail_max : 2048
-----
hw_ptr : 7236608
appl_ptr : 7237376
>
> Thanks!!
> Jonathan.
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.kernelnewbies.org/pipermail/kernelnewbies/attachments/20170125/8a6ea81b/attachment.html
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2017-01-25 23:35 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-01-22 21:38 custom audio card on beaglebone jo
2017-01-22 23:47 ` anish singh
2017-01-25 10:30 ` crazyiop at gmail.com
2017-01-25 23:35 ` anish singh
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).