ios获取设备系统信息

    UIDevice *device_=[[UIDevice allocinit];

    NSLog(@"设备所有者的名称--%@",device_.name);

    NSLog(@"设备的类别-----%@",device_.model);

    NSLog(@"设备的的本地化版本-%@",device_.localizedModel);

    NSLog(@"设备运行的系统---%@",device_.systemName);

    NSLog(@"当前系统的版本---%@",device_.systemVersion);

    NSLog(@"设备识别码-----%@",device_.identifierForVendor.UUIDString);

        

    //得到设备屏幕高度

    float screenHeight=[UIScreen mainScreen].bounds.size.height;


  1. NSLog(@"globallyUniqueString=%@",[[NSProcessInfo processInfo] globallyUniqueString]);//全球唯一标识  
  2. NSLog(@"uniqueIdentifie=%@",[UIDevice currentDevice].uniqueIdentifier);//唯一的标识 可用于区分设备  
  3. NSLog(@"name=%@",[UIDevice currentDevice].name);//设备的名称  李四的 iPad、王五的 iPad .。。  
  4. NSLog(@"systemName=%@",[UIDevice currentDevice].systemName);//系统的名称  iPhone OS  
  5. NSLog(@"systemVersion=%@",[UIDevice currentDevice].systemVersion);//设备系统的版本号  5.1.1、6.0  
  6. NSLog(@"model=%@",[UIDevice currentDevice].model);//设备的型号   iPad、iphone、ipod touch。。。  
  7. NSLog(@"localizedModel=%@",[UIDevice currentDevice].localizedModel);//本地化的模型  iPad  
  8. NSLog(@"batteryLevel=%lf",[UIDevice currentDevice].batteryLevel);//电池电量  



打印结果如下

2013-03-08 17:31:13.944 WaiMai[14982:907] 设备所有者的名称--“zhangqingfeng” iPhone

2013-03-08 17:31:13.951 WaiMai[14982:907] 设备的类别-----iPhone

2013-03-08 17:31:13.953 WaiMai[14982:907] 设备的的本地化版本-iPhone

2013-03-08 17:31:13.957 WaiMai[14982:907] 设备运行的系统---iPhone OS

2013-03-08 17:31:13.961 WaiMai[14982:907] 当前系统的版本---6.0.1

2013-03-08 17:31:13.969 WaiMai[14982:907] 设备识别码-----7305AFE8-66C0-4C6B-8173-1AA61E9F837D

2013-03-08 17:31:14.178 WaiMai[14982:1703] 

  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值