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.

Trusted Contributor
Posts: 140
Registered: ‎11-23-2010
My Device: Torch 9800
My Carrier: Rogers

New to the NDK

Hello all,


  Before anyone kick me in the chin for all my stupid questions let me just tell you that I'm new to the whole NDK and that my c++ coding is far back in high school and that I'm pretty rusty on all the concepts. But still I'm trying to develop for the playbook cause I think that it's a great platform and I wish I could shut the trap on all the bad press on the playbook. So on that here are my questions.


  1. I was playing around in the led.h under bps and I was trying to implement a simple led_request_color("a", LED_COLOR_BLUE, 10) the "a" is a id I don't know if I'm suppose to pass anything else here! But when the app starts it closes back down with a : unknown symbol: led_request_color - ldd:FATAL: Could not resolve all symbols. I don't know if it has something to do with the : access_led_control that I don't know how to implement.
  2. I would like some more info on the :  int sensor_info(sensor_type_t type, sensor_info_t **info); Right now I manage to make it work but I don't understand how to get the info out of there



Thank you for your time and help.


If anyone could point me out on a good website on the c++ development to get me going on the playbook ndk development I would appreciate.

Posts: 1,280
Registered: ‎03-03-2011
My Device: Playbook, Z10, Q10, Z30 with Files & Folders and Orbit of course
My Carrier: Vodafone

Re: New to the NDK

Here's a good C++ tutorial, though not PB-specific:


Files & Folders, the unified file & cloud manager for PlayBook and BB10 with SkyDrive, SugarSync, Box, Dropbox, Google Drive, Google Docs. Free 3-day trial! - Jon Webb - Innovatology - Utrecht, Netherlands
Trusted Contributor
Posts: 140
Registered: ‎11-23-2010
My Device: Torch 9800
My Carrier: Rogers

Re: New to the NDK

Thank you for the web site. I'll look into it!


BTW do you have a clue why the led is not working?

BlackBerry Development Advisor
Posts: 683
Registered: ‎11-29-2011
My Device: PRIV
My Carrier: Rogers

Re: New to the NDK


You have missing symbols because you did not pull the appropriate library into your project.  Add libraries under project->properties->C/C++ Build->Settings->QCC Linker->Libraries.  Make sure "bps" is added.  However, I do not believe led access is currently available to user applications at this time.


Regarding sensor info.. I'm not sure how documented this is just yet.  What exactly are you attempting?






Super Contributor
Posts: 253
Registered: ‎08-19-2010
My Device: BB10, Playbook, 9900, 9800, 9700, 9550, 9530, 9500, 8700.
My Carrier: TT

Re: New to the NDK

The code can help you to get sensor information.


sensor_info_t *info = NULL;

sensor_info(SENSOR_TYPE_ACCELEROMETER, &info);

if (info){
information = sensor_info_get_range_maximum(info);
fprintf(f,"%7.3f\n", information);


Enjoy playbook development.


-Fight with BB10