Template:Networking rut9m manual input output status: Difference between revisions
(Created page with "{{#ifeq:{{{name}}}|RUT956| <pre> ioman.gpio.din1 - 4PIN input ioman.gpio.dout1 - 4PIN output ioman.gpio.din2 - Digital input (only for passive sensors) ioman.gpio.dout...") |
No edit summary |
||
Line 1: | Line 1: | ||
{{# | {{#switch:{{{name}}}|RUT956|RUT906= | ||
<pre> | <pre> | ||
ioman.gpio.din1 - 4PIN input | ioman.gpio.din1 - 4PIN input | ||
Line 9: | Line 9: | ||
ioman.adc.adc0 - Analog input | ioman.adc.adc0 - Analog input | ||
ioman.acl.acl0 - Analog Current loop | ioman.acl.acl0 - Analog Current loop | ||
</pre>| | </pre>|#default= | ||
<pre> | <pre> | ||
ioman.gpio.din1 - 4PIN input | ioman.gpio.din1 - 4PIN input | ||
Line 37: | Line 37: | ||
<li>"value": "<b>1</b>" means high level state.</li> | <li>"value": "<b>1</b>" means high level state.</li> | ||
</ul> | </ul> | ||
</li>{{# | </li>{{#switch:{{{name}}}|RUT956|RUT906= | ||
<li><b>relay0</b> is the relay: | <li><b>relay0</b> is the relay: | ||
<ul> | <ul> | ||
Line 43: | Line 43: | ||
<li>"state": "<b>closed</b>" means closed relay state.</li> | <li>"state": "<b>closed</b>" means closed relay state.</li> | ||
</ul> | </ul> | ||
</li>|}} | </li>|#default=}} | ||
</ul> | </ul> | ||
{{# | {{#switch:{{{name}}}|RUT956|RUT906= | ||
To change relay settings, use the <i><b>update</i></b> command and specify a state: | To change relay settings, use the <i><b>update</i></b> command and specify a state: | ||
ubus call ioman.relay.relay0 update '{"state":"open"}' | ubus call ioman.relay.relay0 update '{"state":"open"}' | ||
ubus call ioman.relay.relay0 update '{"state":"closed"}' | ubus call ioman.relay.relay0 update '{"state":"closed"}' | ||
|}} | |#default=}} |
Latest revision as of 15:23, 10 July 2023
ioman.gpio.din1 - 4PIN input ioman.gpio.dout1 - 4PIN output
Call command ubus call value status :
root@Teltonika-{{{name}}}:~# ubus call ioman.gpio.din1 status { "value": "0", "direction": "in", "bi_dir": false, "invert_input": false }
- din1 is the input:
- "value": "0" means low level state.
- "value": "1" means high level state.
- dout1 is the output:
- "value": "0" means low level state.
- "value": "1" means high level state.