Add example configuration
This commit is contained in:
parent
0f9f622e37
commit
e80cec0d4f
|
@ -1,6 +1,6 @@
|
|||
# acpi_actor
|
||||
A Syndicate actor for publishing Linux ACPI events as well as an example of interacting with Linux generic netlink sockets in pure Nim (Linux C headers aside).
|
||||
|
||||
Not very useful. I thought that I would get battery capacity information over netlink but apparently that information is polled from files in /sys despite any stated deprecations.
|
||||
A configuration example is provide at [example-config.pr](./example-config.pr).
|
||||
|
||||
The lesson learned is that Netlink is of the sort of quality to be expected from the Linux kernel.
|
||||
Not very useful. I thought that I would get battery capacity information over netlink but apparently that information is polled from files in /sys despite any stated deprecations.
|
||||
|
|
|
@ -0,0 +1,18 @@
|
|||
<require-service <daemon acpi_actor>>
|
||||
|
||||
<daemon acpi_actor {
|
||||
argv: ["/bin/acpi_actor"]
|
||||
protocol: application/syndicate
|
||||
}>
|
||||
|
||||
? <machine-dataspace ?machine> [
|
||||
|
||||
? <service-object <daemon acpi_actor> ?cap> [
|
||||
$cap { machine: $machine }
|
||||
]
|
||||
|
||||
$machine ?? <acpi_event ?class ?bus ?type ?data> [
|
||||
$log ! <log "-" { acpi_event: { device: $class bus-id: $bus type: $type data: $data } }>
|
||||
]
|
||||
|
||||
]
|
Loading…
Reference in New Issue