Python Forum
Watching for inputs from multiple sources concurrently
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Watching for inputs from multiple sources concurrently
#3
Thanks Larz, though that is not quite what I'm after.

I guess what I'm asking is - when I see example code it's always setting up for a particular job. Watch for an incoming UDP packet over network. Wait for an incoming IR signal. Wait for the user to press a button. Etc. Each of these things is always given in a function with a singular purpose - makes the code easy.

But what if I want the device to both wait for a UDP packet, and also keep an eye on an IR signal and wait on the button press (or any other types of inputs / stimulus). IS this a case for round robin checking of sensors? Then I think I'll probably miss half an IR signal, or miss the UDP packet, etc. Can I have multiple functions watching all at once?... Not sure. What would be the term to research to look at that?
Reply


Messages In This Thread
RE: Watching for inputs from multiple sources concurrently - by anakaine - Mar-03-2019, 09:03 AM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Help with applying this instrument monitoring code to multiple inputs. Kid_Meier 1 321 Mar-04-2020, 12:01 PM
Last Post: Kid_Meier
  Problem with accepting multiple string inputs Ryan_Todd 5 505 Jan-22-2020, 06:12 PM
Last Post: buran
  reading 2 files concurrently Skaperen 3 1,068 Jun-01-2018, 07:07 AM
Last Post: Skaperen
  multiple inputs newbee 3 1,356 May-20-2018, 01:20 AM
Last Post: snippsat
  Python - Make Json objects to work concurrently through Threads? WeInThis 0 1,403 Sep-22-2017, 11:31 AM
Last Post: WeInThis
  run two tasks concurrently tony1812 1 1,075 Jul-24-2017, 05:43 PM
Last Post: Larz60+

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020