Serial Port: Difference between revisions
No edit summary |
No edit summary |
||
(4 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
* get port settings | |||
<blockquote> | |||
<pre class="bash> | <pre class="bash> | ||
stty -F /dev/ttyUSB0 | |||
</pre> | </pre> | ||
</blockquote> | |||
* set port | |||
<blockquote> | |||
<pre class="bash> | |||
stty -F /dev/ttyUSB0 speed 115200 | |||
</pre> | |||
</blockquote> | |||
* read with cat | |||
<blockquote> | |||
<pre class="bash> | |||
stty -F /dev/ttyUSB0 speed 115200 raw | |||
cat /dev/ttyUSB0 | |||
</pre> | |||
</blockquote> | |||
<syntaxhighlight lang="bash"> | |||
</syntaxhighlight> | |||
[[Category:Hardware]] | [[Category:Hardware]] |
Latest revision as of 12:39, 13 February 2018
- get port settings
stty -F /dev/ttyUSB0
- set port
stty -F /dev/ttyUSB0 speed 115200
- read with cat
stty -F /dev/ttyUSB0 speed 115200 raw cat /dev/ttyUSB0