New answers tagged

1

This does a fairly accurate job of reading pwm fq and dutyCycle, as long as the signal is < 50hz: #!/usr/bin/python2.7 import RPi.GPIO as gpio from datetime import datetime from time import sleep, time gpio.setmode(gpio.BCM) gpio.setup(2, gpio.IN) global risingCount global pulseWidth global timeStart risingCount = 0 pulseWidth=0 timeStart=0 def ...


Top 50 recent answers are included