processing / processing/processing4

Unable to interact with the GPIO of Raspberry Pi 5

Abierto
#807 8 comentarios 0 reacciones 0 asignados Ver en GitHub

Nadie ha tomado este issue todavía.

has attachment help wanted raspberry pi
Lenguaje dominante
Java
Estrellas
494
Forks
183
Merge medio
4 h 39 min
PR fusionados (30 d)
3

Descripción

Created by: eMUQI

Description

Unable to interact with the GPIO of Raspberry Pi 5

Expected Behavior

Draw a dot on Processing, which blinks synchronously with the LED.
图片

Current Behavior

error

/sys/class/gpio/export:Invalid argument
GPIO pin 17 does not seem to be available on your platform
RuntimeException: /sys/class/gpio/export: Invalid argument
RuntimeException: /sys/class/gpio/export: Invalid argument

Steps to Reproduce

  1. Install Hardware I/O
    io

  2. Run the code

    import processing.io.*;
    int ledPin = 17;
    boolean state = true;
    
    void setup() {
        size(100, 100);
        frameRate(2); //set frame rate
        GPIO.pinMode(ledPin, GPIO.OUTPUT); //set the ledPin to output mode
    }
    
    void draw() {
        state = !state;
        if (state==true) {
            GPIO.digitalWrite(ledPin, GPIO.LOW); //led on
            fill(255, 0, 0); //set the fill color of led on
        } else {
            GPIO.digitalWrite(ledPin, GPIO.HIGH); //led off
            fill(155); //set the fill color of led off
        }
        ellipse(width/2, height/2, width*0.75, height*0.75);
    }
    
  3. error

Your Environment

  • Processing version:
    • 4.3
  • Operating System and OS version:
    • OS: Debian GNU/Linux 12 (bookworm) aarch64
    • Kernel: 6.1.0-rpi6-rpi-2712
  • Other information:
    • Raspberry Pi 5 Model B Rev 1.0
    • CPU: BCM2835 (4) @ 2.400GHz

Possible Causes / Solutions

My suspicion is that it might be related to the introduction of the new southbridge chip, RP1, on the Raspberry Pi 5, which now handles the GPIOs and may have altered the access protocol.

Other

Also report at https://discourse.processing.org/t/issue-with-gpio-access-on-raspberry-pi-5-using-processing-4/43337

Guía de contribución

Abrir la guía de contribución

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Línea de trabajo

Comienza con los puntos de entrada de Hardware I/O GPIO utilizados por GPIO.pinMode y GPIO.digitalWrite, y reproduce el sketch en Raspberry Pi 5 con Debian 12. Compara el fallo de /sys/class/gpio/export y el pin 17 no disponible con la ruta de acceso GPIO existente; se considera terminado cuando el sketch proporcionado pueda controlar el LED y dibujar el punto sincronizado sin la RuntimeException.

Escrito por el modelo de indexación a partir del texto del issue.

Evaluación

Stack tecnológico
java, raspberry-pi
Área
embedded-iot
Tipo de issue
Error
Dificultad
4/5
Tiempo estimado
3-5 días
Estado de actividad
Estancado
Claridad
Bastante claro
Aptitud para principiantes
30/100

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.