Skip to content

Commit 58e8cdd

Browse files
committed
docs: update readme with latest toml format
Signed-off-by: Paul Osborne <[email protected]>
1 parent a33b442 commit 58e8cdd

File tree

1 file changed

+11
-13
lines changed

1 file changed

+11
-13
lines changed

README.md

Lines changed: 11 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -55,29 +55,27 @@ how you can configure your GPIOs.
5555
# the following keys:
5656
#
5757
# - `num`: Required. The GPIO number.
58+
# - `names`: Required. One or more names for the GPIO
5859
# - `direction`: Default: `"in"`. Must be either "in" or "out"
59-
# - `active_low`: Default: `false`. If set to true, the polatiry of the pin will
60+
# - `active_low`: Default: `false`. If set to true, the polarity of the pin will
6061
# be reversed.
6162
# - `export`: Default: `true`. If true, this GPIO will be automatically
6263
# exported when `gpio export-all` is run (e.g. by an init script).
63-
# - `aliases`: Additional names for the same GPIO
6464
#
6565

66-
# Basic Form
67-
[pins.reset_button]
68-
num = 73 # required
69-
direction = "in" # default: in
70-
active_low = true # default: false
71-
export = true # default: true
66+
[[pins]]
67+
num = 73 # required
68+
names = ["reset_button"] # required (may have multiple)
69+
direction = "in" # default: in
70+
active_low = false # default: false (really means invert logic)
71+
export = true # default: true
7272

73-
[pins.status_led]
73+
[[pins]]
7474
num = 37
75-
aliases = ["A27", "green_led"]
75+
names = ["status_led", "A27", "green_led"]
7676
direction = "out"
7777

78-
# Compact Form
79-
[pins]
80-
error_led = { num = 11, direction = "in", export = false}
78+
# ...
8179
```
8280

8381
## Implementation Notes

0 commit comments

Comments
 (0)