Python Forum
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
background
#1
Guys,

first things first. HI - I am new here and to python.

How can I do a job in the background while doing a different thing.
Its just a small project for my Raspberry
script simple:

import python-forum-knowledge

def main():
  start_blink()  #  just let a led blink in a while loop

  if fetch_my_mails(): # nomen est omen
    stop_blink()
I thought about subprocess.getstatusoutput, but this one is wating for an output of course.
Some kind of threading inside the script?
Ohhh yeah. the whole thing is runnging under daemon.DaemonContext

So if you could push me in a direction - do it!

Thanks.
K.
Reply


Messages In This Thread
background - by somboku - Jul-29-2021, 02:10 PM
RE: background - by jefsummers - Jul-29-2021, 07:33 PM
RE: background - by somboku - Jul-31-2021, 02:07 AM

Forum Jump:

User Panel Messages

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