Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Native Development


Thank you for visiting the BlackBerry Support Community Forums.

BlackBerry will be closing the BlackBerry Support Community Forums Device Forums on April 1st (Developers, see below)

BlackBerry remains committed to providing excellent customer support to our customers. We are delighted to direct you to the CrackBerry Forums, a well-established and thorough support channel, for continued BlackBerry support. Please visit http://forums.crackberry.com or http://crackberry.com/ask. You can also continue to visit BlackBerry Support or the BlackBerry Knowledge Base for official support options available for your BlackBerry Smartphone.

"When we launched CrackBerry.com 10 years ago, we set out to make it a fun and useful destination where BlackBerry Smartphone owners could share their excitement and learn to unleash the full potential of their BlackBerry. A decade later, the CrackBerry community is as active and passionate as ever and I know our knowledgeable members and volunteers will be excited to welcome and assist more BlackBerry owners with their questions."

- Kevin Michaluk, Founder, CrackBerry.com

Developers, for more information about the BlackBerry Developer Community please review Join the Conversation on the BlackBerry Developer Community Forums found on Inside BlackBerry.


Reply
Highlighted
Developer
Posts: 101
Registered: ‎02-25-2011
My Device: Playbook, q5, z10
My Carrier: TM
Accepted Solution

Preferred PCM

Preferred PCM vs Other PSM

 

while i was investigating how to record sound and some other sound regarding issues, i came across:
https://bdsc.webapps.blackberry.com/native/reference/com.qnx.doc.neutrino.audio/topic/architecture_c...

so i was interested in the last part of hte documention:
"You can list the devices that are on your system by typing:

ls /dev/snd"

 

i investigated this point and here is the output:

 

$ ls -la /dev/snd
total 0
-rw-rw-rw-   1 root      nto               0 Jan 04 12:27 controlC0
-rw-rw-rw-   1 root      nto               0 Jan 03 18:16 mixerC0D0
-rw-rw-rw-   1 root      nto               0 Jan 04 11:09 pcmC0D0c
-rw-rw-rw-   1 root      nto               0 Jan 04 12:27 pcmC0D0p
-rw-rw-rw-   1 root      nto               0 Jan 03 18:17 pcmC0D1p
-rw-rw-rw-   1 root      nto               0 Jan 04 12:27 pcmC0D2p
-rw-rw-rw-   1 root      nto               0 Jan 04 12:27 pcmC0D3p
-rw-rw-rw-   1 root      nto               0 Jan 04 12:27 pcmC0D4c
-rw-rw-rw-   1 root      nto               0 Jan 04 12:27 pcmC0D5c
-rw-rw-rw-   1 root      nto               0 Jan 04 12:27 pcmC0D5p
-rw-rw-rw-   1 root      nto               0 Jan 04 12:27 pcmC0D6c
lrw-rw-rw-   1 root      nto               0 Jan 04 12:27 pcmPreferredc -> pcmC0D0c
lrw-rw-rw-   1 root      nto               0 Jan 04 12:27 pcmPreferredp -> pcmC0D1p

 

an image in the docu show pcmC0D0p as some kind of "standard" pcm, but the preferred is linked to pcmC0D1p.

does anybody know why ?

 

 

________________
mappau Dev Team
blackberry@mappau.com
twitter: mappau
Retired
Posts: 2,559
Registered: ‎10-16-2009
My Device: BlackBerry Z10
My Carrier: Bell

Re: Preferred PCM

Hi,

 

The diagram in the linked site is just a generic diagram of audio devices and does not reflect the preferred PCM. To determine the preferred PCM you have a few options:
Synchronously - use

audiodevice_get()

 

 Asynchronously - call

audiodevice_request_events() 

Before your BPS loop then check for audio change events using

 audiodevice_event_get_path()

 

Regards,

Garett
@garettBeuk
--
Goodbye everybody!
Developer
Posts: 101
Registered: ‎02-25-2011
My Device: Playbook, q5, z10
My Carrier: TM

Re: Preferred PCM

thx for the clarification

________________
mappau Dev Team
blackberry@mappau.com
twitter: mappau