Received: from mail-ed1-f47.google.com (mail-ed1-f47.google.com [209.85.208.47]) by nld3-dev1.alpinelinux.org (Postfix) with ESMTPS id BEF55782AF5 for <~alpine/devel@lists.alpinelinux.org>; Thu, 26 Dec 2019 22:39:18 +0000 (UTC) Received: by mail-ed1-f47.google.com with SMTP id cy15so23874186edb.4 for <~alpine/devel@lists.alpinelinux.org>; Thu, 26 Dec 2019 14:39:18 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:from:date:message-id:subject:to; bh=Ea5abqVvWq5k6azoGpYWtikGwOptOxQKl4oHZdcGBFk=; b=vUduUHKAg7ONeJRIb3RwHpn4iKlXWyT4WiIkM2+vjISzB7Mz6DUZozreYmvOQVzo4L P7Xbe2bhu4iklDmkbz2vXVghuUtuMW3csJcBUfaKLAbGS4n7fWncd3Hix7bPbxqycS+2 Y1KWm8kd+VTE1zF+sMYBARQSurLNYcpBMc+IJQ8TaMnLG5n+Kz1a3tVH5n/dMIsgi8Ts W8PIL6ZhOVoC6jF9+KBY1F6ftWKagsEDyJ/eGS8hYga1ZOLrvuIc9KKSBkfqRpMCuQoU yunyWYjqk36U/aVTGgAEXukG8NrxJJ7jfGTaAfOjhsfb9iLNgWP8Ifm3C5/sGpu2Ydn9 rs3w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:from:date:message-id:subject:to; bh=Ea5abqVvWq5k6azoGpYWtikGwOptOxQKl4oHZdcGBFk=; b=hstm/7xCv70FK60b+SLfoWGlIq5AUhAqXwBj6UkTNtJjAzPT4aH/G0cL/691DRQZK2 7A6WLSfOYyjD4LuvqWqmq0GsraDdYNEvNv3B52NgvVf24fI8X/uKr/eyP/iUGNoWamQt LfUUMs78OtzGO6ShkdA8jnjsFOHG9teJJr6QUYCdcIqKYuvM9k/x7arXfBFVdEbWrGWg DgwaLUOIDUJJ8k7tdqeeeXGsKC6GZqY8jBbWOpJZAvIpjORUKt4FqVhCVmLtF8GhORV/ hN2wF345d79yaG2rsK31ZBKXwRB7Q3VcVvDe2rYbaCbP0BCoJZlvgjBhpOB3RPNmN+S7 09Tg== X-Gm-Message-State: APjAAAWz2aRvdEenKr6j3yw3h10eOqku94akm20sl0wmlon6GO0aUd9M cr8IBiFSnWddpYSBeLA4jK8V2OD3lyb0LQqYhIrRmyVHExc= X-Google-Smtp-Source: APXvYqzyFIUvKxD45S+ylI+pm9yOZLoyncClfeeGofnh0FKfSdNCLbqy8mGy+IO1o4SbgIu5WeJOmdsLYa5ZUpGOMfI= X-Received: by 2002:a05:6402:3047:: with SMTP id bu7mr52364050edb.44.1577399958370; Thu, 26 Dec 2019 14:39:18 -0800 (PST) MIME-Version: 1.0 From: =?UTF-8?Q?David_Taill=C3=A9?= Date: Thu, 26 Dec 2019 23:39:07 +0100 Message-ID: Subject: 3.11.2 and RPi.GPIO 0.6.5 on Pi Zero : edge detection no longer working To: ~alpine/devel@lists.alpinelinux.org Content-Type: multipart/alternative; boundary="0000000000002fff53059aa30c2a" --0000000000002fff53059aa30c2a Content-Type: text/plain; charset="UTF-8" Hi all, I just installed Alpine 3.11.2 on a Pi Zero W, and just found RPi.GPIO no longer works for edge detection. Package installation : apk add python3 apk add py3-rpigpio Test file : import RPi.GPIO as g pin=4 g.setmode(g.BCM) print("pin%d mode is %d\n" % (pin, g.gpio_function(pin))) g.setup(pin, g.IN, pull_up_down=g.PUD_DOWN) print("pin%d state=%d\n" % (pin, g.input(pin))) while True: x = g.wait_for_edge(pin, g.BOTH) print("pin%d edge %d\n" % (pin, x)) On Alpine 3.10.0, it works as expected, printing a line as you bring pin 4 to ground or 3.3V. On Alpine 3.11.2, i get : # python3 testgpio.py function of pin 4 = 1 pin 4 now is 0 Traceback (most recent call last): File "testgpio.py", line 8, in x = g.wait_for_edge(pin, g.BOTH) RuntimeError: Error waiting for edge Other methods such as add_event_detect also fail with a RuntimeError about being unable to add edge detection. Other tests I ran prove reading pins and setting pin state do work. lsmod shows : i2c_gpio 16384 0 i2c_algo_bit 16384 1 i2c_gpio So, Which do you think is the culprit ? alpine or RPi.GPIO ? Who would you reach out to to get this fixed ? or at least examined ? Thanks for any feedback ! David --0000000000002fff53059aa30c2a Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Hi all,

I just installed Alp= ine 3.11.2 on a Pi Zero W, and just found RPi.GPIO no longer works for edge= detection.
Package installation :
apk add python3<= /div>
apk add py3-rpigpio

Test file :
import R= Pi.GPIO as g
pin=3D4
g.setmode(g.BCM)
print("pin%d mode is %d= \n" % (pin, g.gpio_function(pin)))
g.setup(pin, g.IN, pull_up_down= =3Dg.PUD_DOWN)
print("pin%d state=3D%d\n" % (pin, g.input(pin)= ))
while True:
=C2=A0=C2=A0 x =3D g.wait_for_edge(pin, g.BOTH)
=C2= =A0=C2=A0 print("pin%d edge %d\n" % (pin, x))
On Alpine 3.10.0, it works as expected, printing a line as you= bring pin 4 to ground or 3.3V.
On Alpine 3.11.2, i get :
# p= ython3 testgpio.py
function of pin 4 =3D 1

pin 4 now is 0
Tra= ceback (most recent call last):
=C2=A0 File "testgpio.py", lin= e 8, in <module>
=C2=A0 =C2=A0 x =3D g.wait_for_edge(pin, g.BOTH)<= br>RuntimeError: Error waiting for edge

Oth= er methods such as add_event_detect also fail with a RuntimeError about bei= ng unable to add edge detection.
Other tests I ran prove reading = pins and setting pin state do work.

lsmod shows :<= /div>
i2c_gpio =C2=A0 =C2=A0 =C2= =A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 16384 =C2=A00
i2c_algo_bit =C2=A0 =C2= =A0 =C2=A0 =C2=A0 =C2=A0 16384 =C2=A01 i2c_gpio

So,
Which do you think is the culprit ? alpine or RPi.GP= IO ?
Who would you reach out to to get this fixed ? or at least e= xamined ?

Thanks for any feedback !
= David






--0000000000002fff53059aa30c2a--