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

Reply
Contributor
NiCoX
Posts: 11
Registered: ‎10-29-2011
My Device: PlayBook

UDID

Hi,

 

In the BAR descriptor file I can see this permission: <action>read_device_identifying_information</action>

It makes me think that we should be able to read some device information, such as the UDID. Is it actually possible, and how?

 

Thanks in advance.

Please use plain text.
Developer
Innovatology
Posts: 1,280
Registered: ‎03-03-2011
My Device: Playbook, Z10, Q10, Z30 with Files & Folders and Orbit of course

Re: UDID

Check this:

 

http://www.blackberry.com/developers/docs/airapi/1.1.1/qnx/system/Device.html#pin

 

 

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
Please use plain text.
Contributor
NiCoX
Posts: 11
Registered: ‎10-29-2011
My Device: PlayBook

Re: UDID

Thanks a lot, it's now more clear for me why this permission is available :smileyhappy:

 

Do you know if there is a C/C++ equivalent? Or if it is possible to call some Air functions from an app developed in C/C++?

 

Thanks.

Please use plain text.
Developer
LMcRae
Posts: 163
Registered: ‎04-16-2009
My Device: Not Specified

Re: UDID

I also need this.  I tried to use confstr but it doesn't return anything.

 

char    buffer[1024];

confstr( _CS_HW_SERIAL, buffer, sizeof( buffer ) );

 I also have what I would except is the permission set in the bar

 

<action>read_device_identifying_information</action>

 

Please use plain text.
Administrator
MSohm
Posts: 14,569
Registered: ‎07-09-2008
My Device: BlackBerry Z30, BlackBerry PlayBook

Re: UDID

Currently, there is no native API to obtain the PIN of a BlackBerry PlayBook.  However, this is a high priority API that we're looking to provide soon.

Mark Sohm
BlackBerry Development Advisor

Please refrain from posting new questions in solved threads.
Problem solved? Click the Accept As Solution button.
Found a bug? Report it using Issue Tracker
Please use plain text.
Developer
LMcRae
Posts: 163
Registered: ‎04-16-2009
My Device: Not Specified

Re: UDID

What about any kind of GUID? 

Please use plain text.
Administrator
MSohm
Posts: 14,569
Registered: ‎07-09-2008
My Device: BlackBerry Z30, BlackBerry PlayBook

Re: UDID

The PIN would be the best thing to use as a GUID.  Just hold tight a little longer on this feature if you can.  :smileywink:

Mark Sohm
BlackBerry Development Advisor

Please refrain from posting new questions in solved threads.
Problem solved? Click the Accept As Solution button.
Found a bug? Report it using Issue Tracker
Please use plain text.
Developer
Innovatology
Posts: 1,280
Registered: ‎03-03-2011
My Device: Playbook, Z10, Q10, Z30 with Files & Folders and Orbit of course

Re: UDID


LMcRae wrote:

What about any kind of GUID? 


You could use the Wi-fi interface MAC address, that should be unique to the device. It's available in Air, not sure about NDK.

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
Please use plain text.
Developer
LMcRae
Posts: 163
Registered: ‎04-16-2009
My Device: Not Specified

Re: UDID

Is this in 2.0?

Please use plain text.
Administrator
MSohm
Posts: 14,569
Registered: ‎07-09-2008
My Device: BlackBerry Z30, BlackBerry PlayBook

Re: UDID

[ Edited ]

Using the 2.0 beta 3 NDK you can now obtain the device's PIN. Refer to deviceinfo found here:

 

https://bdsc.webapps.blackberry.com/native/beta/reference/com.qnx.doc.bps.lib_ref/com.qnx.doc.bps.li...

Mark Sohm
BlackBerry Development Advisor

Please refrain from posting new questions in solved threads.
Problem solved? Click the Accept As Solution button.
Found a bug? Report it using Issue Tracker
Please use plain text.