hc
hc is a lightweight framework to develop HomeKit accessories in Go.
File Explorer
Download Latest Version (.zip)- main.go
- main.go
- client.go
- home-icon.png
- accessory.go
- bridge.go
- camera.go
- colored_lightbulb.go
- constant.go
- container.go
- container_test.go
- doc.go
- lightbulb.go
- outlet.go
- README.md
- switch.go
- television.go
- thermometer.go
- thermostat.go
- window.go
- accessory_flags.go
- accessory_identifier.go
- active.go
- active_identifier.go
- administrator_only_access.go
- air_particulate_density.go
- air_particulate_size.go
- air_quality.go
- app_matching_identifier.go
- audio_feedback.go
- battery_level.go
- bool.go
- bool_test.go
- brightness.go
- bytes.go
- bytes_test.go
- carbon_dioxide_detected.go
- carbon_dioxide_level.go
- carbon_dioxide_peak_level.go
- carbon_monoxide_detected.go
- carbon_monoxide_level.go
- carbon_monoxide_peak_level.go
- category.go
- characteristic.go
- characteristic_test.go
- charging_state.go
- closed_captions.go
- color_temperature.go
- configure_bridged_accessory.go
- configure_bridged_accessory_status.go
- configured_name.go
- constants.go
- contact_sensor_state.go
- cooling_threshold_temperature.go
- current_air_purifier_state.go
- current_ambient_light_level.go
- current_door_state.go
- current_fan_state.go
- current_heater_cooler_state.go
- current_heating_cooling_state.go
- current_horizontal_tilt_angle.go
- current_humidifier_dehumidifier_state.go
- current_media_state.go
- current_position.go
- current_relative_humidity.go
- current_slat_state.go
- current_temperature.go
- current_tilt_angle.go
- current_time.go
- current_transport.go
- current_vertical_tilt_angle.go
- current_visibility_state.go
- day_of_the_week.go
- digital_zoom.go
- discover_bridged_accessories.go
- discovered_bridged_accessories.go
- display_order.go
- doc.go
- filter_change_indication.go
- filter_life_level.go
- firmware_revision.go
- float.go
- float_test.go
- hardware_revision.go
- heating_cooling_mode_test.go
- heating_threshold_temperature.go
- hold_position.go
- hue.go
- identifier.go
- identify.go
- identify_test.go
- image_mirroring.go
- image_rotation.go
- in_use.go
- input_device_type.go
- input_source_type.go
- int.go
- int_test.go
- is_configured.go
- leak_detected.go
- link_quality.go
- lock_control_point.go
- lock_current_state.go
- lock_last_known_action.go
- lock_management_auto_security_timeout.go
- lock_physical_controls.go
- lock_target_state.go
- logs.go
- manufacturer.go
- manufacturer_test.go
- model.go
- model_test.go
- motion_detected.go
- mute.go
- name.go
- name_test.go
- night_vision.go
- nitrogen_dioxide_density.go
- obstruction_detected.go
- occupancy_detected.go
- on.go
- on_test.go
- optical_zoom.go
- outlet_in_use.go
- ozone_density.go
- pair_setup.go
- pair_verify.go
- pairing_features.go
- pairing_pairings.go
- picture_mode.go
- pm10_density.go
- pm2_5_density.go
- position_state.go
- power_mode_selection.go
- program_mode.go
- programmable_switch_event.go
- programmable_switch_output_state.go
- reachable.go
- relative_humidity_dehumidifier_threshold.go
- relative_humidity_humidifier_threshold.go
- remaining_duration.go
- remote_key.go
- reset_filter_indication.go
- rotation_direction.go
- rotation_speed.go
- saturation.go
- security_system_alarm_type.go
- security_system_current_state.go
- security_system_target_state.go
- selected_camera_recording_configuration.go
- selected_rtp_stream_configuration.go
- selected_stream_configuration.go
- serial_number.go
- service_label_index.go
- service_label_namespace.go
- set_duration.go
- setup_endpoints.go
- slat_type.go
- sleep_discovery_mode.go
- smoke_detected.go
- software_revision.go
- status_active.go
- status_fault.go
- status_jammed.go
- status_low_battery.go
- status_tampered.go
- streaming_status.go
- string.go
- string_test.go
- sulphur_dioxide_density.go
- supported_audio_recording_configuration.go
- supported_audio_stream_configuration.go
- supported_camera_recording_configuration.go
- supported_rtp_configuration.go
- supported_video_recording_configuration.go
- supported_video_stream_configuration.go
- swing_mode.go
- target_air_purifier_state.go
- target_air_quality.go
- target_door_state.go
- target_fan_state.go
- target_heater_cooler_state.go
- target_heating_cooling_state.go
- target_horizontal_tilt_angle.go
- target_humidifier_dehumidifier_state.go
- target_media_state.go
- target_position.go
- target_relative_humidity.go
- target_slat_state.go
- target_temperature.go
- target_tilt_angle.go
- target_vertical_tilt_angle.go
- target_visibility_state.go
- temperature_display_units.go
- test_conn.go
- time_update.go
- tunnel_connection_timeout.go
- tunneled_accessory_advertising.go
- tunneled_accessory_connected.go
- tunneled_accessory_state_number.go
- valve_type.go
- version.go
- voc_density.go
- volume.go
- volume_control_type.go
- volume_selector.go
- water_level.go
- wifi_capabilities.go
- wifi_configuration_control.go
- import.go
- markdown.go
- swift_decl.go
- chacha20_poly1305.go
- curve25519.go
- hkdf.go
- cryptographer.go
- doc.go
- ed25519.go
- packet.go
- packet_test.go
- secure_session.go
- secure_session_test.go
- database.go
- database_test.go
- doc.go
- entity.go
- constant.go
- event_emitter.go
- event_emitter_test.go
- event_listener.go
- category.go
- characteristic.go
- path.go
- service.go
- category.go
- service.go
- characteristic.go
- enum.go
- service.go
- metadata.go
- metadata.json
- characteristics.go
- characteristics_test.go
- doc.go
- doc.go
- pair-setup.go
- pair-verify.go
- pairings.go
- resource.go
- accessories.go
- characteristics.go
- doc.go
- err.go
- identify.go
- json.go
- listener.go
- server.go
- admin.go
- doc.go
- error_types.go
- errors.go
- handler.go
- method_types.go
- pairing_controller.go
- pairing_controller_test.go
- sequence_types.go
- setup_client_controller.go
- setup_client_session.go
- setup_controller_test.go
- setup_server_controller.go
- setup_server_session.go
- srp.go
- tag_types.go
- verify_client_controller.go
- verify_controller_test.go
- verify_server_controller.go
- verify_session.go
- chunked_writer.go
- chunked_writer_test.go
- connection.go
- constants.go
- context.go
- device.go
- device_test.go
- doc.go
- handler.go
- keep_alive.go
- notification.go
- notification_test.go
- secured_device.go
- session.go
- log.go
- audio_stream_configuration.go
- configuration.go
- setup_endpoints.go
- setup_endpoints_test.go
- stream_configuration.go
- stream_configuration_test.go
- stream_controller_test.go
- stream_status.go
- video_stream_configuration.go
- accessory_information.go
- air_purifier.go
- air_quality_sensor.go
- battery_service.go
- bridge_configuration.go
- bridging_state.go
- camera_control.go
- camera_recording_management.go
- camera_rtp_stream_management.go
- carbon_dioxide_sensor.go
- carbon_monoxide_sensor.go
- colored_lightbulb.go
- constants.go
- contact_sensor.go
- cooler.go
- doc.go
- door.go
- doorbell.go
- fan.go
- fan_v2.go
- faucet.go
- filter_maintenance.go
- garage_door_opener.go
- heater.go
- heater_cooler.go
- humidifier_dehumidifier.go
- humidity_sensor.go
- input_source.go
- irrigation_system.go
- leak_sensor.go
- light_sensor.go
- lightbulb.go
- lock_management.go
- lock_mechanism.go
- microphone.go
- motion_sensor.go
- occupancy_sensor.go
- outlet.go
- README.md
- security_system.go
- service.go
- service_label.go
- service_test.go
- slat.go
- smoke_sensor.go
- speaker.go
- stateful_programmable_switch.go
- stateless_programmable_switch.go
- switch.go
- television.go
- temperature_sensor.go
- thermostat.go
- time_information.go
- tunneled_btle_accessory_service.go
- valve.go
- wifitransport.go
- window.go
- window_covering.go
- decoder.go
- encoder.go
- marshal.go
- marshal_test.go
- reader.go
- unmarshal.go
- unmarshal_test.go
- writer.go
- writer_test.go
- container.go
- doc.go
- file_storage.go
- file_storage_test.go
- mac.go
- rand.go
- rand_test.go
- serial.go
- serial_test.go
- storage.go
- string.go
- tlv8.go
- tlv8_test.go
- xhmurl.go
- xhmurl_test.go
- .gitignore
- .travis.yml
- config.go
- config_test.go
- CREDITS
- doc.go
- go.mod
- go.sum
- ip_transport.go
- LICENSE
- password.go
- password_test.go
- README.md
- termination.go
- transport.go
# Installation Guide
1. Get the code
git clone https://github.com/brutella/hc
Downloads the entire project code from GitHub to your computer.
cd hc
Moves into the project folder you just downloaded.
2. Go
Medium RecommendedPrerequisites
go build ./...
Compiles the Go program into an executable.
go run .
Runs the Go program directly without a separate build step.
If the build finishes without errors, it worked. If you used go run ., check the terminal output.
// repository documentation
Was this content helpful?
(0 ratings)
