New answers tagged

0

This is not really a Pi specific question but programming. Nonetheless checking buttons in callback is error prone. The traditional approach is to set flags until the callback finishes. NOTE there should be no reason you can't use gpiozero as this is (normally) just a wrapper around RPi.GPIO. I note you are still calling SystemExit. This is not normal and ...


0

The problem you have is that you're trying to use RPi.GPIO without setting the numbering system as required - as the error message states. However, as mentioned in the comments, it's not recommended that you mix the two libraries, and gpiozero has implicit cleanup, so you don't need to use GPIO.cleanup() - which is mentioned in the docs: https://gpiozero....


0

It is impossible to determine the pull state of GPIO on most Pi (except by measurement). It is possible with the BCM2711 used by Pi4 and I have written a Python3 library (based on RPi.GPIO) which does this and a program gpioread which shows this and the actual programmed function/state. See https://raspberrypi.stackexchange.com/a/117593/8697 Corrupted git ...


0

You can't query the pull state with RPi.GPIO. In fact you can only query the pulls in software in the latest Pi models based on the BCM2711. I'm not sure if any of the mainstream GPIO libraries actually provide support for doing so.


0

The code itself is pretty fine. I have just checked, and it looks your issue is very similar the one that described here as the modules are pretty similar. Hence, try to increase your delay before to while loop to 1 min to see if it helps. For these kind of questions please include a diagram that shows how you connected your sensor module, and a datasheet of ...


0

The installation instructions is described on the given link: sudo apt install git git clone https://github.com/fruxefarms/FruxePi.git cd FruxePi sudo bash install.sh


Top 50 recent answers are included