Last modified by Xiaoling on 2023/06/01 17:01

From version 4.1
edited by Edwin Chen
on 2022/05/03 08:00
Change comment: There is no comment for this version
To version 6.1
edited by Edwin Chen
on 2022/05/03 08:54
Change comment: There is no comment for this version

Summary

Details

Page properties
Content
... ... @@ -22,10 +22,10 @@
22 22  
23 23  == OpenWrt Base OS ==
24 24  
25 -=== Example to Control an GPIO: ===
26 -
27 -(% class="box infomessage" %)
25 +(% class="box infomessage" id="HControlanGeneralGPIO:" %)
28 28  (((
27 +Control an General GPIO:
28 +
29 29  **echo 18 > /sys/class/gpio/export**     ~/~/ Export gpio 18 so we can use it
30 30  **echo "high" > /sys/class/gpio/gpio18/direction**   ~/~/  Set direction to out and
31 31  set level to high. Use "low" to set direction to output and level to low