diff --git a/Services.md b/Services.md new file mode 100644 index 0000000..1604525 --- /dev/null +++ b/Services.md @@ -0,0 +1,160 @@ +## Services guide + +- [Table of content](#services) + - [1. `send_magic_packet`](#1-send_magic_packet) + - [2. `restart_to_windows_from_linux`](#2-restart_to_windows_from_linux) + - [3. `restart_to_linux_from_windows`](#3-restart_to_linux_from_windows) + - [4. `start_computer_to_windows`](#4-start_computer_to_windows) + - [5. `put_computer_to_sleep`](#5-put_computer_to_sleep) + - [6. `restart_computer`](#6-restart_computer) + - [7. `change_monitors_config`](#7-change_monitors_config) + - [8. `steam_big_picture`](#8-steam_big_picture) + - [9. `change_audio_config`](#9-change_audio_config) + - [10. `debug_info`](#10-debug_info) + +## Introduction + +Welcome to the user documentation for the services of the `easy_computer_manager` custom integration for Home Assistant. + +This integration provides a set of services to manage various aspects of a computer, such as sending Wake-On-LAN (WoL) packets, restarting the computer between different operating systems (if dual-boot), adjusting audio configurations, changing monitor settings, and more. + +## Services + +### 1. `send_magic_packet` + +**Description:** Send a 'magic packet' to wake up a device with 'Wake-On-LAN' capabilities. + +**Fields:** +- **mac:** + - **Name:** MAC Address + - **Description:** MAC address of the target device. + - **Required:** true + - **Example:** "aa:bb:cc:dd:ee:ff" + +- **broadcast_address:** + - **Name:** Broadcast Address + - **Description:** Broadcast IP to send the magic packet. + - **Example:** 192.168.255.255 + +- **broadcast_port:** + - **Name:** Broadcast Port + - **Description:** Port to send the magic packet. + - **Default:** 9 + +### 2. `restart_to_windows_from_linux` + +**Description:** Restart the computer to Windows while running Linux using Grub. + +**Target Device:** +- **Example:** "switch.my_computer" +- **Integration:** `easy_computer_manager` + +### 3. `restart_to_linux_from_windows` + +**Description:** Restart the computer to Linux while running Windows. + +**Target Device:** +- **Example:** "switch.my_computer" +- **Integration:** `easy_computer_manager` + +### 4. `start_computer_to_windows` + +**Description:** Directly start the computer into Windows (boot to Linux, set Grub reboot, then boot to Windows). + +**Target Device:** +- **Example:** "switch.my_computer" +- **Integration:** `easy_computer_manager` + +### 5. `put_computer_to_sleep` + +**Description:** Put the computer into sleep mode. + +**Target Device:** +- **Example:** "switch.my_computer" +- **Integration:** `easy_computer_manager` + +### 6. `restart_computer` + +**Description:** Restart the computer. + +**Target Device:** +- **Example:** "switch.my_computer" +- **Integration:** `easy_computer_manager` + +### 7. `change_monitors_config` + +**Description:** Modify monitors configuration. + +**Fields:** +- **monitors_config:** + - **Name:** Monitors Configuration + - **Description:** Monitors configuration details. + - **Required:** true + - **Example:** + ```yaml + HDMI-1: + enabled: true + primary: true + position: [0, 0] + mode: 3840x2160@120.000 + transform: normal + scale: 2 + ``` +**Target Device:** +- **Example:** "switch.my_computer" +- **Integration:** `easy_computer_manager` + +### 8. `steam_big_picture` + +**Description:** Start/Stop Steam Big Picture mode. + +**Fields:** +- **action:** + - **Name:** Action + - **Description:** Choose whether to start, stop, or return to the desktop Steam UI. + - **Required:** true + - **Example:** "start" + - **Choices:** + - "start" + - "stop" + - "exit" +**Target Device:** +- **Example:** "switch.my_computer" +- **Integration:** `easy_computer_manager` + +### 9. `change_audio_config` + +**Description:** Adjust audio settings (volume, mute, input, output). + +**Fields:** +- **volume:** + - **Name:** Volume + - **Description:** Set the desired volume level. + - **Example:** 50 + +- **mute:** + - **Name:** Mute + - **Description:** Mute the audio. + - **Example:** true + +- **input_device:** + - **Name:** Input Device + - **Description:** Specify the ID/name/description of the input device. + - **Example:** "Kraken 7.1 Chroma Stereo Analog" + +- **output_device:** + - **Name:** Output Device + - **Description:** Specify the ID/name/description of the output device. + - **Example:** "Starship/Matisse HD Audio Controller Stereo Analog" + +**Target Device:** +- **Example:** "switch.my_computer" +- **Integration:** `easy_computer_manager` + +### 10. `debug_info` + +**Description:** Display debug information to help with setup and troubleshooting. Use this data (such as monitor resolutions, audio device names/IDs, etc.) with other services such as `change_audio_config` or `change_monitors_config`. + +**Target Device:** +- **Example:** "switch.my_computer" +- **Integration:** `easy_computer_manager` \ No newline at end of file