Python GPIO Library for the Rock64 (R64.GPIO)
#5
Hi @Leapo

I have this error..running
Code:
R64-GPIO-test.py



Code:
root@rock64:/home/Rock64-R64.GPIO# sudo python R64-GPIO-test.py
Testing R64.GPIO Module...

Module Variables:
Name           Value
----           -----
GPIO.ROCK      ROCK
GPIO.BOARD     BOARD
GPIO.BCM       BCM
GPIO.OUT       out
GPIO.IN        in
GPIO.HIGH      1
GPIO.LOW       0
GPIO.PUD_UP    0
GPIO.PUD_DOWN  1
GPIO.VERSION   0.6.3
GPIO.RPI_INFO  {'P1_REVISION': 3, 'RAM': '1024M', 'REVISION': 'a22082', 'TYPE': 'Pi 3 Model B', 'PROCESSOR': 'BCM2837', 'MANUFACTURER': 'Embest'}
Error: Unable to export GPIO
Error: Unable to set GPIO direction
Error: Unable to export GPIO
Error: Unable to set GPIO direction

Testing GPIO Input/Output:
You must setup() the GPIO channel first
Output State : None
You must setup() the GPIO channel as an output first
You must setup() the GPIO channel first
Input State  : None
You must setup() the GPIO channel as an output first

Testing PWM Output - DutyCycle - High Precision:
60Hz at 50% duty cycle for 1 second
Traceback (most recent call last):
  File "R64-GPIO-test.py", line 58, in <module>
    p.start(50)
  File "/home/Rock64-R64.GPIO/R64/_GPIO.py", line 333, in start
    self.pwm_calc()
  File "/home/Rock64-R64.GPIO/R64/_GPIO.py", line 350, in pwm_calc
    self.sleep_low = (1.0 / self.freq) * ((100 - self.dutycycle) / 100.0)
AttributeError: PWM instance has no attribute 'freq'
root@rock64:/home/Rock64-R64.GPIO# uname -a
Linux rock64 4.4.114-rockchip-ayufan-193 #1 SMP Sun Mar 4 20:24:21 UTC 2018 aarch64 GNU/Linux

@Leapo

I update to 4.4.120, it fixed the issue with IO  error


Code:
Linux rock64 4.4.120-rockchip-ayufan-209 #1 SMP Mon Apr 2 16:05:07 UTC 2018 aarch64 GNU/Linux
  Reply


Messages In This Thread
RE: Python GPIO Library for the Rock64 (R64.GPIO) - by i69fstop - 04-08-2018, 04:11 AM

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

Forum Jump:


Users browsing this thread: 1 Guest(s)