我想检测用户设备的颜色以将其与实际设备的图像相关联(例如:Macbook SpaceGray或Gold).
我找到了一个用于iOS设备的私有API,但有没有办法在OSX中做到这一点(如果可能,合法)?
任何帮助是极大的赞赏.
解决方法
如果您的Mac应用使用互联网连接,那么
second answer on this page可能会有用:
07001
Download the OUI list from this page. However this will only supply
manufacturers portion of the OUI (the first 3 octets). You will need
to go to each manufacturer to obtain a copy of the address portion,
usually the 4th octet which will identify the device type. the 6th
octet is usually used for the unique device ID.
A mac address is a 48 bit hexadecimal number. The first 24 bits are
the OUI which can be used to identify the manufacturer.
困难的部分是确定Apple为每台计算机分配的mac代码