In this chapter, you learned how to use the HomeKit framework. This framework is supposed to be used with third-party physical devices, but Apple provides a simulator called the HomeKit Accessory Simulator.
We set some devices as well as created some services and received their security code. Once we had our virtual devices, we set a virtual home with virtual rooms and added home devices to them.
HomeKit works with asynchronous calls as they are done via Bluetooth. This is the reason why we had to switch threads while using the UI, check for errors, and also request for the current accessory value.
In the next chapter, you will learn how to control your health with HealthKit.