Python GPIO Library for the Rock64 (R64.GPIO)
(04-27-2018, 03:04 PM)Leapo Wrote: Looking over their code... might be useful, but their interrupt implementation is pretty thin compared to RPi.GPIO

Current progress: One interrupt feature is in. The background threading required to implement the others is slowing me down a bit, but I'm still working on it.

Hi Leapo,

First off, thanks for taking the time to port RPi.GPIO lib to Rock64 !

I have a Rock64, running Armbian 5.42 Ubuntu Xenial minimal (4.4.124-rk3328) and trying to use the R64 GPIO lib .

I read your note, stating testing was done on using Ayufan's release 0.5.15 and other distros/versions are not guaranteed to work, yet I want to inquire of a certain error I am receiving.

I used the "prefered" way of getting the lib, downloading the R64 directory and running the script in the same path as it.
The module seems to be imported, yet I get some errors when exporting the the GPIO pin, like below:

root@rock64:/home/pi/projects# cat
import R64.GPIO as GPIO

pin = 16
GPIO.setup(pin, GPIO.OUT, initial=GPIO.HIGH)

root@rock64:/home/pi/projects# python
Error: Unable to export GPIO
Error: Unable to set GPIO direction

I want to add , I tried the script as 'root', as at first I believed it could not write tot he '/sys/class/gpio/export' file. I tried mode BCM (pin=23), ROCK(pin=101), BOARD(pin=16), always getting the same error.

If I try to set pin 16 to "out" via bash, it works, but only If I add an offset of 1000, i.e 101 becomes 1101. Could this be the reason why the R64.GPIO lib fails, where should I go about to add this offset in the lib if possible ?


Messages In This Thread
RE: Python GPIO Library for the Rock64 (R64.GPIO) - by AnythingIsFine - 05-11-2018, 02:56 AM

Possibly Related Threads…
Thread Author Replies Views Last Post
  OpenWRT on the Rock64 CanadianBacon 6 1,283 06-10-2022, 05:43 PM
Last Post: anchor00
  Rock64 bricked shawwwn 6 1,828 01-29-2022, 05:49 AM
Last Post: shawwwn
  Rock64 board not working, no HDMI no Ethernet. EDited 2 917 01-26-2022, 08:46 AM
Last Post: TRS-80
  Rock64 <--> Rock64 Serial Connection mark1250 1 693 12-23-2021, 09:27 PM
Last Post: barray
  Are you guys still using Ayufan's OMV on your Rock64? AkiraSensei 0 682 11-26-2021, 07:01 PM
Last Post: AkiraSensei
  Rock64 kernel panics clay 15 4,561 10-17-2021, 06:30 PM
Last Post: Rocklobster
  Pine Rock64 eMMC lifespan moonspell79 3 1,861 08-19-2021, 06:46 PM
Last Post: bcnaz
  Rock64 No Audio - Solved wbecks 12 22,175 08-13-2021, 01:23 PM
Last Post: blakeadam
  Trustzone support for Rock64 capablegh 1 1,324 07-17-2021, 10:15 AM
Last Post: capablegh
  rock64, compile problems "illegal instruction", "memory fault" -> ddr_333Mhz? klausfelix 0 899 07-02-2021, 03:13 PM
Last Post: klausfelix

Forum Jump:

Users browsing this thread: 2 Guest(s)