引用自:http://www.sf.org.cn/Article/symbiandev/200511/3239.html

利用symbianAPI得到手机型号


利用symbianAPI得到手机型号

问 :困扰我很久的一个问题,在symbianapi里面,就找到一个HAL类,可以返回一些定义好的enum,但也只是厂商等等,搞不懂symbian为什么要返回enum,为什么不返回一个字符串?厂商在制定的时候加进去就是了。
但是型号确始终得不到,请问大家有没有什么方法来得到型号(比如要得到7610

答:

事例:

from Forum_Nokia_Technical_Library_v1_8_en.chm

Fetching device model information
+-------------------------------------------------------------------------+
|Subject      |How can I fetch device model information                   |
+-------------+-------------------------------+---------------------------+
|             |Platform(s)                    |Device(s), SW version(s)   |
+             +-------------------------------+---------------------------+
|             |Series 60 Platform 1st Edition |N/A                        |
|             |Series 60 Platform 2st Edition |                           |
+-------------+-------------------------------+---------------------------+
|Category     |Symbian C++                                                |
+-------------+-----------------------------------------------------------+
|Subcategory  |General                                                    |
+-------------+-----------------------------------------------------------+
|Description  |In Symbian OS phones the machine UID is unique for each    |
|             | device type. Unfortunately the UID can be same for device |
|             |variants, such as Communicator variants (Nokia 9210, Nokia |
|             |9210i, Nokia 9290, and Nokia 9210c), and the UID cannot be |
|             |used to distinguish between exact device models. The       |
|             |Symbian machine UID can be retrieved with the HAL::Get()   |
|             |method, using HALData::EMachineUid as a parameter.         |
|             |                                                           |
|             |#include <hal.h>  // also link to hal.lib                  |
|             |                                                           |
|             |TInt mUid = 0;                                             |
|             |                                                           |
|             |HAL::Get(HALData::EMachineUid, mUid);                      |
|             |                                                           |
|             |For example:                                               |
|             |                                                           |
|             | 3650        0x101f466a                                    |
|             | 7650        0x101f4fc3                                    |
|             | N-Gage      0x101f8c19                                    |
|             | N-Gage QD   0x101fb2b1                                    |
|             | Siemens SX1 0x101F9071                                    |
|             | 6600        0x101fb3dd                                    |
|             | 7610        0x101fb3f3                                    |
|             | 9500        0x101f3ee3                                    |
|             | 6260        0x101fb3f4                                    |
|             | 6630        0x101fbb55                                    |
|             | 6680        0x10200F99                                    |
|             | 3230        0x10200F97                                    |
|             | 6682        0x10200F9B                                    |
|             | 6681        0x10200F9C                                    |
|             | N90         0x10200F98                                    |
|             |                                                           |
|             |Check the document Series 60 Platform Identification Code  |
|             |available at http://www.forum.nokia.com for a list of      |
|             |machine UIDs.                                              |
+-------------+-----------------------------------------------------------+
|Creation date|May 24, 2005                                               |
+-------------+-----------------------------------------------------------+
|Last modified|                                                           |
+-------------------------------------------------------------------------+

 

posted on 2006-02-25 04:37 移动开发 阅读(590) 评论(0)  编辑 收藏 引用

只有注册用户登录后才能发表评论。
网站导航: 博客园   IT新闻   BlogJava   博问   Chat2DB   管理