Please select To the mobile version | Continue to access the desktop computer version

OrangePi

 Login            
 Register            
Search
Hot search: orangepi
View: 2426|Reply: 0

GPIO not work on Orange Pi Win Plus

[Copy link]

3

Threads

4

Posts

59

Credits

Registered member

Rank: 2

Credits
59
Post time 2017-10-14 17:46:53 | Show all posts |Read mode
I tried to use GPIO on A64 (arm64 arch) OPi Win Plus.
I installed WiringPI: https://github.com/OrangePiLibra/WiringPi
When i try to change PIN mode with gpio util or try to chage files of /sys/class/gpio - there is no result.
I can change GPIO value on PIN, but not mode (in/out/...)

Why?

  1. ~$ sudo gpio readall
  2. ...
  3. |  39 |  24 |  GPIO.24 |   IN | 0 | 35 || 36 | 0 | IN   | CTS2     | 27  | 35  |
  4. | 101 |  25 |  GPIO.25 |   IN | 0 | 37 || 38 | 0 | IN   | TxD2     | 28  | 32  |
  5. |     |     |       0v |      |   | 39 || 40 | 0 | IN   | RxD2     | 29  | 33  |
  6. +-----+-----+----------+------+---+----++----+---+------+----------+-----+-----+
  7. | BCM | wPi |   Name   | Mode | V | Physical | V | Mode | Name     | wPi | BCM |
  8. +-----+-----+----------+------+---+-Orange Pi Win/Win+ +---+------+----------+-----+-----+
  9. ~$ sudo gpio mode 25 out                                                                                                                        
  10. ~$ sudo gpio write 25 1
  11. ~$ sudo gpio readall
  12. +-----+-----+----------+------+---+-Orange Pi Win/Win+ +---+---+------+---------+-----+--+
  13. | BCM | wPi |   Name   | Mode | V | Physical | V | Mode | Name     | wPi | BCM |
  14. ...
  15. |  39 |  24 |  GPIO.24 |   IN | 0 | 35 || 36 | 0 | IN   | CTS2     | 27  | 35  |
  16. | 101 |  25 |  GPIO.25 |   IN | 1 | 37 || 38 | 0 | IN   | TxD2     | 28  | 32  |
  17. |     |     |       0v |      |   | 39 || 40 | 0 | IN   | RxD2     | 29  | 33  |
Copy the Code
  1. | 101 |  25 |  GPIO.25 |   IN | 0 | 37 || 38 | 0 | IN   | TxD2     | 28  | 32  |
  2. |     |     |       0v |      |   | 39 || 40 | 0 | IN   | RxD2     | 29  | 33  |
  3. +-----+-----+----------+------+---+----++----+---+------+----------+-----+-----+
  4. | BCM | wPi |   Name   | Mode | V | Physical | V | Mode | Name     | wPi | BCM |
  5. +-----+-----+----------+------+---+-Orange Pi Win/Win+ +---+------+----------+-----+-----+
  6. ~$ sudo echo 101 > /sys/class/gpio/export                                                                                               
  7. ~$ sudo echo out > /sys/class/gpio/gpio101/direction                                                                                    
  8. ~$ sudo echo 1 > /sys/class/gpio/gpio101/value
  9. ~$ sudo gpio readall
  10. | 101 |  25 |  GPIO.25 |   IN | 1 | 37 || 38 | 0 | IN   | TxD2     | 28  | 32  |
  11. |     |     |       0v |      |   | 39 || 40 | 0 | IN   | RxD2     | 29  | 33  |
Copy the Code

I need to change mode of some pins. Is it possible to change GPIO mode on WinPlus?

You have to log in before you can reply Login | Register

Points Rules

Archiver|Mobile edition|Darkroom|OrangePi En ( 粤ICP备14086627号-2

2019-9-19 14:57 GMT+8 , Processed in 0.029263 second(s), 23 queries .

Powered by Discuz! X3.2

© 2014-2015 orangepibbs en.

Quick Reply To Top Return to the list