Skip to content

Commit acd162a

Browse files
authored
updated readme
1 parent e07d865 commit acd162a

File tree

1 file changed

+63
-24
lines changed

1 file changed

+63
-24
lines changed

README.md

Lines changed: 63 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -27,25 +27,25 @@ remote:
2727
- platform: jvcprojector
2828
name: Projector
2929
host: 192.168.1.14
30+
scan_interval: 30
3031

3132
# only required for NZ series and up
3233
password: MyPassword
3334

3435
# optional, default is 20554
3536
port: 20554
3637

37-
# optional, default is 10s
38-
timeout: 10
38+
# optional, float, default is 0.5 seconds
39+
# how long to wait before raising a communication error
40+
timeout: 0.5
3941

4042
# how long to wait between commands
41-
# optional, default is 600ms
43+
# optional, default is 600 milliseconds
4244
delay: 600
4345

4446
# how many times to retry on connection error
45-
# optional, default is 10
46-
max_retries: 10
47-
48-
scan_interval: 30
47+
# optional, default is 5
48+
max_retries: 5
4949
```
5050
You can implement changing of the projector input and lens memory based on `input_select` entities and some automation templates.
5151

@@ -113,36 +113,75 @@ pip install jvc-projector-remote
113113

114114
**host:** (string) (Required) your projector IP address.
115115

116-
**scan_interval:** (string) (Optional) timeout used to update the component (strong suggestion to set this to 30 or higher)
116+
**scan_interval:** (string) (Optional) timeout used to update the component
117+
118+
**password:** (string) (Optional) only required for NZ series (or up) projectors
119+
120+
**port:** (int) (Optional) which port to connect to, default is 20554
121+
122+
**timeout:** (float) (Optional) how many seconds to wait for response from projector before a communication error is called, default is 2.0 seconds
123+
124+
**delay:** (int) (Optional) how many milliseconds to wait between consecutive commands, default is 600 milliseconds
125+
126+
**max_retries:** (int) (Optional) how many times to retry connection on a socket error, default is 5
117127

118-
#### Service `remote.turn_off`
128+
#### Extra State Attributes:
129+
**`last_commands_sent`:** a list of the commands sent when `remote.send_command` was last called on this entity
130+
131+
**`last_commands_response`:** a list of the responses from the projector for each command in `last_commands_sent`. If the command was a successful write command (no response from projector), then the element in this list will be the string `success`. Otherwise, it will be a string representing the response from the projector.
132+
133+
**`power_state`:** the current power state of the projector. Will be one of: `lamp_on`, `reserved`, `standby`, `cooling`, `emergency`
134+
135+
**`signal_state`:** the current status of the input signal. Will be one of: `no_signal`, `active_signal`
136+
137+
**`input_state`:** the current input setting of the projector. Will be one of: `hdmi1`, `hdmi2`
138+
139+
**`lamp_state`:** the state of the lamp. Will be one of: `high`, `low`
140+
141+
**`picture_mode`:** the current picture mode setting. Will be one of: `cinema`, `natural`, `film`, `THX`, `hlg`, `hdr10`, `user{1-6}`
142+
143+
#### Service `remote.turn_off`:
119144
| Service data attribute | Optional | Description |
120145
| ---------------------- | -------- | ----------- |
121146
| `entity_id` | no |Entity ID to projector. |
122147

123-
#### Service `remote.turn_on`
148+
#### Service `remote.turn_on`:
124149
| Service data attribute | Optional | Description |
125150
| ---------------------- | -------- | ----------- |
126151
| `entity_id` | no |Entity ID to projector. |
127152

128-
#### Service `remote.send_command`
153+
#### Service `remote.send_command`:
129154
| Service data attribute | Optional | Description |
130155
| ---------------------- | -------- | ----------- |
131156
| `entity_id` | no |Entity ID to projector. |
132-
| `command` | no |A command to send. |
133-
134-
The available commands are:
135-
* **Lens Memory:** `memory-1`, `memory-2`, `memory-3`, `memory-4`,`memory-5`
136-
* **Source:** `input-hdmi1`, `input-hdmi2`
137-
* **Picture Mode:** `picture_mode-{cinema, natural, film, THX, hlg, hdr10}`, `picture_mode-user{1-6}`
138-
* **Low Latency Mode:** `low_latency-on`, `low_latency-off`
139-
* **Mask** `mask-off`, `mask-custom{1,2,3}`
157+
| `command` | no |A command (or list of commands) to send. |
158+
| `delay_secs` | yes |The time in seconds to wait between each command in the list. |
159+
160+
161+
#### Command Strings:
162+
These command strings will perform an operation on the projector. The corresponding entry in the `last_commands_response` attribute will be `success` if the operation succeeded, or `failed` otherwise. Values in '{}' indicate multiple choices.
163+
* **Power:** `power-{on,off}` (recommended to use the `remote.turn_on` and `remote.turn_off` services).
164+
* **Lens Memory:** `memory-{1-5}`
165+
* **Source:** `input-{hdmi1, hdmi2}`
166+
* **Picture Mode:** `picture_mode-{cinema, natural, film, THX, hlg, hdr10}`, `picture_mode-{user1-user6}`
167+
* **Low Latency Mode:** `low_latency-{on, off}`
168+
* **Mask** `mask-{off, custom1, custom2, custom3}`
140169
* **Lamp** `lamp-{high,low}`
141-
* **Menu Controls** `menu-{menu,up,down,left,right,ok,back}`
142-
* **Lens Aperture** `aperture-off`, `aperture-auto{1,2}`
143-
* **Anamorphic** `anamorphic-off`, `anamorphic-{a,b,c}`
144-
145-
Currently there is no feedback for these commands. For power on/off, use the `remote.turn_on` and `remote.turn_off` services, as these retrieve the power state.
170+
* **Menu Controls** `menu-{menu, up, down, left, right, ok, back}`
171+
* **Lens Aperture** `aperture-{off, auto1, auto2}`
172+
* **Anamorphic** `anamorphic-{off, a, b, c}`
173+
174+
These command strings will store the response from the projector in the corresponding element of the `last_commands_response` attribute or `failed` otherwise:
175+
* **Power status:** `power`, returns from `lamp_on`, `standby`, `cooling`, `reserved`, `emergency`
176+
* **Source:** `input`, returns from `hdmi1, hdmi2`
177+
* **Picture Mode:** `picture_mode`, returns from `cinema, natural, film, THX, hlg, hdr10, user{1-6}`
178+
* **Low Latency Mode:** `low_latency`, returns from `on, off`
179+
* **Mask** `mask`, returns from `off, custom1, custom2, custom3`
180+
* **Lamp** `lamp`, returns from `high, low`
181+
* **Lens Aperture** `aperture`, returns from `off, auto1, auto2`
182+
* **Anamorphic** `anamorphic`, returns from `off, a, b, c`
183+
* **MAC Address** `macaddr`, returns the projector's MAC address
184+
* **Model Info** `modelinfo`, returns the model string of the projector
146185

147186
### Support
148187
Check out the [Home Assistant Community Page](https://community.home-assistant.io/t/jvc-projector-component/123417) if you're having trouble getting this working.

0 commit comments

Comments
 (0)