Usage of 86IO
Describe
86IO is a built-in tool program in L86duntu, which is used to set the output status of the 86Duino digital I/O pin or read the input status of the digital I/O pin. The implementation method is to directly call digitalRead() and digitalWrite() in the 86Duino API, and the original code is placed in the /home/dmp/86Duino_Tools/src/86io
directory, and users can refer to or modify it themselves.
How to use
When using 86IO, just enter the following command directly in the /home/dmp/86Duino_Tools
directory:.
./86io [mode] [pin] [logic level]
: Set the working mode of the digital I/O pin. There are two options: "r" and "w". "r" means setting the digital I/O pin as the input, and "w" means setting the digital I/O pin as the output.
: The specified digital I/O pin number. : This parameter needs to be provided when selecting "w". There are two options: "HIGH" or "LOW"; "HIGH" means output high potential, and "LOW" means output low potential.
When mode
is selected as “r”, no logic level
parameter is required. After the 86IO tool program is executed, the voltage status (LOW or HIGH) on the specified I/O pin at that time will be returned.
Example
1. The following command will read the input potential of the digital I/O pin with number 0 and print the result on the screen:
./86io r 0
2. The following command will cause the digital I/O pin numbered 12 to output a high potential (in this example, an LED light is connected to the pin numbered 12 to light up the LED when it outputs a high potential):
./86io w 12 HIGH
Hacking Page
The text of the 86Duino reference is licensed under a Creative Commons Attribution-ShareAlike 3.0 License.