ThinkChat🤖让你学习和工作更高效,注册即送10W Token,即刻开启你的AI之旅 广告
> 本书出处:http://www.cocoachina.com/ios/20150324/11411.html 本文由CocoaChina翻译组成员[iBenjamin_Go](http://weibo.com/u/2771490773#_rnd1427356619219)和浅夏@旧时光翻译自苹果开发文档:[HomeKit Developer Guide](https://developer.apple.com/library/ios/documentation/NetworkingInternet/Conceptual/HomeKitDeveloperGuide/Introduction/Introduction.html#//apple_ref/doc/uid/TP40015050-CH1-SW1),敬请勘误。 该文档旨在帮你编写HomeKit app。HomeKit库是用来沟通和控制家庭自动化配件的,这些家庭自动化配件都支持苹果的HomeKit Accessory Protocol。HomeKit应用程序可让用户发现兼容配件并配置它们。用户可以创建一些action来控制智能配件(例如恒温或者光线强弱),对其进行分组,并且可以通过Siri触发。HomeKit 对象被存储在用户iOS设备的数据库中,并且通过iCloud还可以同步到其他iOS设备。HomeKit支持远程访问智能配件,并支持多个用户设备和多个用户。HomeKit 还对用户的安全和隐私做了处理。 ![into_diagram_2x.png](https://box.kancloud.cn/2015-08-08_55c57694f31ab.png "1427184694566459.png") 注意:如果你是开发设计HomeKit硬件的供应商,你可以去Hardware Developers下的[HomeKit](https://developer.apple.com/homekit/)页面了解MFi Program相关信息,也可以阅读 [External Accessory Programming Topics](https://developer.apple.com/library/ios/featuredarticles/ExternalAccessoryPT/Introduction/Introduction.html#//apple_ref/doc/uid/TP40009502). 另请参阅 以下资源提供了更多关于创建HomeKit应用程序的信息: * [HomeKit User Interface Guidelines](https://developer.apple.com/homekit/ui-guidelines/) 提供了用户界面设计指南 * [App Store Review Guidelines: HomeKit](https://developer.apple.com/app-store/review/guidelines/#homekit) 提供了加快app审核的技巧 * [HomeKit Framework Reference](https://developer.apple.com/library/ios/documentation/HomeKit/Reference/HomeKit_Framework/index.html#//apple_ref/doc/uid/TP40014519) 描述了HomeKit框架中的类和方法 * [External Accessory Framework Reference](https://developer.apple.com/library/ios/documentation/ExternalAccessory/Reference/ExternalAccessoryFrameworkReference/index.html#//apple_ref/doc/uid/TP40008235) 列出了系统提供的发现和配置无线智能家居产品UI * [HomeKit Catalog](https://developer.apple.com/library/ios/samplecode/HomeKitCatalog/Introduction/Intro.html#//apple_ref/doc/uid/TP40015048) 提供示例演示HomeKit特性 * [WWDC 2014: Introducing HomeKit](https://idmsa.apple.com/IDMSWebAuth/login.html?path=%2F%2Fvideos%2Fwwdc%2F2014%2F%3Fid%3D213&appIdKey=891bd3417a7776362562d2197f89480a8547b108fd934911bcbea0110d07f757) 对HomeKit更高层次的分析 * [iOS Security](https://www.apple.com/business/docs/iOS_Security_Guide.pdf) 描述HomeKit如何处理iOS上的安全和隐私