Complete documentation overhaul.

This commit is contained in:
Dermot Duffy
2024-04-01 21:09:20 -07:00
parent 9d62a5ceee
commit 955bcb3a9a
87 changed files with 6360 additions and 4540 deletions
+53
View File
@@ -0,0 +1,53 @@
# 2-way Audio
This card supports 2-way audio (e.g. transmitting audio from a microphone to a
suitably equipped camera). In general, due to the myriad of different cameras,
security requirements and browser limitations getting 2-way to work may be
challenging.
## Requirements
### Environmental requirements
* Must have a camera that supports audio out (otherwise what's the point!)
* Camera must be supported by `go2rtc` for 2-way audio (see [supported cameras](https://github.com/AlexxIT/go2rtc#two-way-audio)).
* Must be accessing your Home Assistant instance over `https`. The browser will enforce this.
### Card requirements
* Only Frigate cameras are supported.
* Only the `go2rtc` live provider is supported.
* Only the `webrtc` mode supports 2-way audio:
* Must have microphone menu button enabled:
## Example configuration
```yaml
type: custom:frigate-card
cameras:
- camera_entity: camera.office
live_provider: go2rtc
go2rtc:
modes:
- webrtc
menu:
buttons:
microphone:
enabled: true
```
## Usage
* The camera will always load *without* the microphone connected, unless the
[`always_connected`](../configuration/live.md?id=microphone) microphone option is
set to `true`.
* To speak, hold-down the microphone menu button.
* On first press, this will reset the `webrtc` connection to include 2-way
audio unless [`always_connected`](../configuration/live.md?id=microphone) has
been used.
* Thereafter hold the microphone button down to unmute/speak, let go to
mute.
* The video will automatically reset to remove the microphone after the number
of seconds specified by
[`disconnect_seconds`](../configuration/live.md?id=microphone) configuration have
elapsed since the last mute/unmute press.
+16
View File
@@ -0,0 +1,16 @@
# Usage
The usage of the card is intended to be reasonably self-explanatory. Some more
complex situations / requirements are discussed here.
### 2-way audio
See [2-way audio](2-way-audio.md) for documentation on using 2-way audio.
### Casting
See [Casting](casting.md) for documentation on casting the card.
### URL Actions
See [URL Actions](url-actions.md) for documentation on acting based on URL contents.
+13
View File
@@ -0,0 +1,13 @@
* [Getting Started](../README.md)
* [Configuration](../configuration/README.md)
* [Examples](../examples.md)
* [Screenshots](../screenshots.md)
* [Troubleshooting](../troubleshooting.md)
* [Usage](README.md)
* [2-way audio](2-way-audio.md)
* [Casting](casting.md)
* [URL Actions](url-actions.md)
---
* [Developing](../developing.md)
+45
View File
@@ -0,0 +1,45 @@
# Casting the Card
This card can be (Chrome) casted to a device (such as a [Nest
Hub](https://store.google.com/us/product/nest_hub_2nd_gen)) through the use of
[Home Assistant Cast](https://cast.home-assistant.io/).
## Instructions
* Visit [Home Assistant Cast](https://cast.home-assistant.io/) and click `Start Casting`
* Enter your Home Assistant URL, and authorize your account.
* Click `Start Casting` and choose the device to cast to from the browser menu.
* Choose which view/dashboard to display.
* If successful, the view will be cast to the device.
## Limitations
Casting Home Assistant dashboards comes with a number of caveats:
* Home Assistant Casting does not support the HA `streaming` component
([source](https://cast.home-assistant.io/faq.html)). This means clips playing
and the `ha` live provider can not work. Other live providers such as `jsmpeg`
and `webrtc-card` function correctly.
* The Javascript fullscreen API does not work (so the fullscreen button does not
work, but see below for an equivalent).
## Recommended configuration for Nest Hub
Using a `panel` dashboard with the following base configuration will result in
the card consuming the entire device screen:
### Configuration
```yaml
type: custom:frigate-card
cameras:
- camera_entity: camera.office
live_provider: go2rtc
dimensions:
aspect_ratio: 1024:600
aspect_ratio_mode: static
```
### Result
![](../images/card-on-nest-hub.jpg "Casting on a Nest Hub :size=400")
+77
View File
@@ -0,0 +1,77 @@
# URL Actions
It is possible to pass the Frigate card one or more
[actions](../configuration/actions.md) from the URL (e.g. select a particular
camera, open the live view in expanded mode, etc).
### When actions are executed
The Frigate card will execute these actions in the following circumstances:
* On initial card load.
* On 'tab' change in a dashboard.
* When a `navigate` [action](https://www.home-assistant.io/dashboards/actions/)
is called on the dashboard (e.g. a button click requests navigation).
* When the user uses the `back` / `forward` browser buttons whilst viewing a
dashboard.
## Instructions
To send an action to *all* Frigate Cards on a dashboard:
```
[PATH_TO_YOUR_HA_DASHBOARD]?frigate-card-action.[ACTION]=[VALUE]
```
To send an action to a specific named Frigate Card:
```
[PATH_TO_YOUR_HA_DASHBOARD]?frigate-card-action.[CARD_ID].[ACTION]=[VALUE]
```
| Parameter | Description |
| - | - |
| `ACTION` | One of the supported Frigate Card custom actions. See below. |
| `CARD_ID` | When specified only cards that have a [`card_id`](../configuration/README.md) parameter will act. |
| `VALUE` | An optional value to use with the `camera_select` and `live_substream_select` actions. |
?> Both `.` and `:` may be used as the delimiter. If you use `:` some
browsers may require it be escaped to `%3A`.
!> If a dashboard has multiple Frigate cards on it, even if they are on
different 'tabs' within that dashboard, they will all respond to the actions
unless the action is targeted with a `CARD_ID` as shown above.
## Supported Actions
Only a subset of all [actions](../configuration/actions.md) are supported in URL form.
| Action | Supported in URL | Explanation |
| - | - | - |
| `camera_select` | :white_check_mark: | |
| `camera_ui`| :white_check_mark: | |
| `clip` | :white_check_mark: | |
| `clips` | :white_check_mark: | |
| `default` | :white_check_mark: | |
| `download`| :heavy_multiplication_x: | Latest media information is not available on initial render. |
| `expand` | :white_check_mark: | |
| `fullscreen` | :heavy_multiplication_x: | Javascript does not support activating fullscreen without direct human interaction. Use `expand` as an alternative. |
| `image` | :white_check_mark: | |
| `live_substream_select` | :white_check_mark: | |
| `live` | :white_check_mark: | |
| `media_player`| :heavy_multiplication_x: | Please [request](https://github.com/dermotduffy/frigate-hass-card/issues) if you need this. |
| `menu_toggle` | :white_check_mark: | |
| `microphone_mute`, `microphone_unmute`| :heavy_multiplication_x: | |
| `mute`, `unmute` | :heavy_multiplication_x: | |
| `play`, `pause` | :heavy_multiplication_x: | |
| `ptz` | :heavy_multiplication_x: | Please [request](https://github.com/dermotduffy/frigate-hass-card/issues) if you need this. |
| `recording` | :white_check_mark: | |
| `recordings` | :white_check_mark: | |
| `screenshot`| :heavy_multiplication_x: | Latest media information is not available on initial render. |
| `show_ptz` | :heavy_multiplication_x: | Please [request](https://github.com/dermotduffy/frigate-hass-card/issues) if you need this. |
| `snapshot` | :white_check_mark: | |
| `snapshots` | :white_check_mark: | |
## Examples
See [URL actions examples](../examples.md?id=url-actions).