2
0
mirror of https://github.com/pikvm/pikvm synced 2024-11-06 21:20:32 +00:00

Update gpio.md

This commit is contained in:
Maxim Devaev 2021-07-17 02:34:07 +03:00 committed by GitHub
parent 8d6ad5f419
commit 43ede23438
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -202,13 +202,44 @@ kvmd:
driver: my_server
pin: 1
mode: output
switch: off
switch: false
my_server_off:
driver: my_server
pin: 2
mode: output
switch: off
switch: false
view:
table:
- [my_server_status, "my_server_on|On", "my_server_off|Off"]
```
### Wake-on-LAN
The driver `wol` provides a simple generator of Wake-on-LAN packages. One driver and one output are generated for one host if a [simplified configuration method](wol.md) is used. However, you can define multiple drivers if you want to manage different hosts. One driver controls one host, and can only be used as an output. Pin numbers are ignored.
```yaml
kvmd:
gpio:
drivers:
wol_server1:
type: wol
mac: ff:ff:ff:ff:ff:f1
wol_server2:
type: wol
mac: ff:ff:ff:ff:ff:f2
ip: 192.168.0.100
port: 9
scheme:
wol_server1:
driver: wol_server1
pin: 0
mode: output
switch: false
wol_server2:
driver: wol_server2
pin: 0
mode: output
switch: false
view:
table:
- ["#Server 1", "wol_server1|Send Wake-on-LAN"]
- ["#Server 2", "wol_server2|Send Wake-on-LAN"]
```