Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #59063

Re: Implementing a multivibrator function with python

From Terry Reedy <tjreedy@udel.edu>
Subject Re: Implementing a multivibrator function with python
Date 2013-11-11 05:58 -0500
References <c763cc2a-83d2-4ed7-9df6-83371e83d841@googlegroups.com>
Newsgroups comp.lang.python
Message-ID <mailman.2368.1384167526.18130.python-list@python.org> (permalink)

Show all headers | View raw


On 11/11/2013 4:41 AM, JL wrote:
> I am trying to implement a multivibrator function with python. This is how it works;
>
> - An trigger event happens
> - Upon receiving the event, a variable goes high for 5secs, then go low.
> - If the event happens again before the 5secs expire, the high duration will be extended by another 5 secs. This works like a retriggerable multivibrator for those who are into electronics.
>
> Is there some sample code for this problem or can someone point me to using the right library for this feature?

Python 3.4 will have a new asyncio package that includes an event loop 
module. It will be in the forthcoming 3.4.b0 release; it might be in 
3.4.a4 but I have not installed that yet. In any case, I believe it 
should make the above easy.

-- 
Terry Jan Reedy

Back to comp.lang.python | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

Implementing a multivibrator function with python JL <lightaiyee@gmail.com> - 2013-11-11 01:41 -0800
  Re: Implementing a multivibrator function with python Dave Angel <davea@davea.name> - 2013-11-11 04:56 -0600
    Re: Implementing a multivibrator function with python JL <lightaiyee@gmail.com> - 2013-11-12 06:44 -0800
      Re: Implementing a multivibrator function with python unknown <unknown@unknown.com> - 2013-11-12 16:04 +0000
      Re: Implementing a multivibrator function with python Antoon Pardon <antoon.pardon@rece.vub.ac.be> - 2013-11-12 17:37 +0100
      Re: Implementing a multivibrator function with python Joel Goldstick <joel.goldstick@gmail.com> - 2013-11-12 11:47 -0500
      Re: Implementing a multivibrator function with python Dennis Lee Bieber <wlfraed@ix.netcom.com> - 2013-11-12 19:42 -0500
  Re: Implementing a multivibrator function with python Terry Reedy <tjreedy@udel.edu> - 2013-11-11 05:58 -0500
  Re: Implementing a multivibrator function with python Antoon Pardon <antoon.pardon@rece.vub.ac.be> - 2013-11-11 15:00 +0100

csiph-web