diff options
author | cheapie <no-email-for-you@example.com> | 2022-01-02 18:42:08 -0600 |
---|---|---|
committer | cheapie <no-email-for-you@example.com> | 2022-01-02 18:42:08 -0600 |
commit | 243a8063ddbb107ab191aa333cc6cdc85701f410 (patch) | |
tree | 848d72cd8b91cc9d259f75196bfd577bd8e88e66 /mesecons_luacontroller/help/mesecons.txt | |
parent | 648f77bd43f1fbe59e6d655e57d96e2647a43b68 (diff) | |
download | mesecons-243a8063ddbb107ab191aa333cc6cdc85701f410.tar mesecons-243a8063ddbb107ab191aa333cc6cdc85701f410.tar.gz mesecons-243a8063ddbb107ab191aa333cc6cdc85701f410.tar.bz2 mesecons-243a8063ddbb107ab191aa333cc6cdc85701f410.tar.xz mesecons-243a8063ddbb107ab191aa333cc6cdc85701f410.zip |
Add Luacontroller examples/help system
Diffstat (limited to 'mesecons_luacontroller/help/mesecons.txt')
-rw-r--r-- | mesecons_luacontroller/help/mesecons.txt | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/mesecons_luacontroller/help/mesecons.txt b/mesecons_luacontroller/help/mesecons.txt new file mode 100644 index 0000000..8b8d562 --- /dev/null +++ b/mesecons_luacontroller/help/mesecons.txt @@ -0,0 +1,24 @@ +Mesecons I/O +============ + +Luacontrollers provide four pins for mesecons connections, labeled from A to D. +There is no need to manually switch between input and output modes - any pin not outputting mesecons power automatically works as an input. + +Input states can be read from the pin table. +Example: +if pin.a then + --Code here would be run only if pin A is active +end + +Outputs can be set by writing to the port table. +Example: +port.b = true --Outputs a signal on pin B + +When a pin starts or stops receiving a signal, an event occurs with some information about the pin. +Example: +{ + type = "on", + pin = { + name = "A" + } +} |