4

First of all, test the LED by connecting it to 3V3 and GND to make it come on without needing code. Then move from 3V3 to a GPIO pin and make sure you know which pin you're connected to. Refer to pinout.xyz. Your gpiozero example is wrong. Running led.blink() in a loop is repeatedly starting the loop but never giving it chance to cycle. You can either create ...


3

The stated question is regarding contact bounce. However, the data presented in the question does not reflect contact bounce - contact bounce does not repeat over the 100msec & 300msec durations presented in the text of the question. Let me try to be clear: The data provided does not rule out contact bounce, but the issue described by the data is not due ...


2

The RPi.GPIO module only runs on the Raspberry Pi. You will have to create your own dummy copy if you want to develop on another computer.


2

Your Question is misleading. Debounce settings work for their intended purpose (short term contact bounce), but this is not really your problem. Incidentally if you wanted to test bounce you couldn't have found a better "switch" to generate it - proper switches are designed to minimise bounce, although relay contacts are notorious for bounce. What ...


2

I have written several GPIO Python modules. They each implement a "proper" debounce. pigpio set_glitch_filter lgpio gpio_set_debounce_micros rgpio gpio_set_debounce_micros


1

I have had this issue myself. What you are after is a mock library. Give this one a go: https://pypi.org/project/Mock.GPIO/ pip install Mock.GPIO Just replace your import: import RPi.GPIO as GPIO with: import Mock.GPIO as GPIO


1

I would go with the RPi.GPIO on the Raspi. Which Version of Raspberry Pi you have? Two things that came up to my mind by reading your post were: Have you checked that the LED is working? Connect it with a Resistor which fits your led. If Resistor is to high the LED maybe flashing not very bright. Have you checked that you use the LED in the proper way (not ...


1

Driving a 3.3V pin with a 12V signal will require a level shifter anyway, and inverting level shifters have essentially the same complexity as non-inverting ones. For instance, here's an example using an optocoupler: simulate this circuit – Schematic created using CircuitLab The advantage of an optocoupler is that you don't have to have the same ...


1

EDIT: I have missed the pulldown resistor in my illustration for the accessories to ground. Don't forget that or you will get a floating value when the car is on! I know this is old but in the off chance it helps someone, I thought I might share my solution. I'm pretty new to all of this so please, if I am doing anything stupid, let me know. A small, ...


Only top voted, non community-wiki answers of a minimum length are eligible