PINE64
Configuring Python GPIO Pin Control Rock64 - Printable Version

+- PINE64 (https://forum.pine64.org)
+-- Forum: ROCK64 (https://forum.pine64.org/forumdisplay.php?fid=85)
+--- Forum: Rock64 Hardware and Accessories (https://forum.pine64.org/forumdisplay.php?fid=89)
+--- Thread: Configuring Python GPIO Pin Control Rock64 (/showthread.php?tid=5331)



Configuring Python GPIO Pin Control Rock64 - www139 - 10-31-2017

I haven't had experience working with GPIO but it appears I need to find a Python GPIO pin library to control the GPIO pins on the Rock64 for the project I'm developing. What libraries do you (the community) think I should use for GPIO pin control on my Rock64? Depending on standardization, it seems a library should be on the documentation page for the board.

Thank you.


RE: Configuring Python GPIO Pin Control Rock64 - MarkHaysHarris777 - 11-03-2017

(10-31-2017, 09:49 AM)www139 Wrote: I haven't had experience working with GPIO but it appears I need to find a Python GPIO pin library to control the GPIO pins on the Rock64 for the project I'm developing. What libraries do you (the community) think I should use for GPIO pin control on my Rock64? Depending on standardization, it seems a library should be on the documentation page for the board.

At the moment you have two options:  1)  write your own wrapper for /sys/class/gpio/  either in python or C for use with python,  or 2)  port the  RPi.GPIO-PineA64  package  for use with the Rock64 in Python.  Option (2) needs to be done by someone ( might as well be you ).  

The RPi.GPIO-PineA64 package is a port of the Raspberry PI Python GPIO written for the RPi3.  Its open source on git and should be fairly easy to port for use on the Rock64.  The C portions are going to be very very similar;  what will differ is the base address and the calculations for offsets ( pad addresses ).  You will want to crosscheck with the Technical Reference Manual Part I, and the datasheets for the RK3328.

Shy


RE: Configuring Python GPIO Pin Control Rock64 - nolan - 05-05-2021

Has the porting process / task been done as of today since you posted that going on... wow, 4 years ago now.

I would hope so... I was hoping to play with some pins tonight.


RE: Configuring Python GPIO Pin Control Rock64 - Mrfixit2001 - 06-22-2021

https://github.com/mrfixit2001/Rock64-R64.GPIO