Python Forum
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
SOLVED python script help
#2
You need to put your button.wait_for_press and subsequent code in a loop. For starters, I suggest adding
while True:
at line 19 and indent all of your code after that one level. You will need to ctrl-C to get out of the program, but once it prints Motioneye started it will go back to the top of the loop and wait for press again.
Reply


Messages In This Thread
SOLVED python script help - by buku - Nov-15-2020, 12:06 AM
RE: python script help - by jefsummers - Nov-15-2020, 02:17 PM
RE: python script help - by buku - Nov-15-2020, 08:16 PM
RE: python script help - by jefsummers - Nov-15-2020, 10:24 PM
RE: python script help - by buku - Nov-16-2020, 01:22 AM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Is there a *.bat DOS batch script to *.py Python Script converter? pstein 3 3,866 Jun-29-2023, 11:57 AM
Last Post: gologica
  math formula does not give the same result as bash script [SOLVED] AlphaInc 3 1,108 Apr-02-2023, 07:21 PM
Last Post: AlphaInc
  [SOLVED] [Linux] Script in cron stops after first run in loop Winfried 2 1,060 Nov-16-2022, 07:58 PM
Last Post: Winfried
  [SOLVED] Requiring help running an old Python script (non Python savvy user) Miletkir 13 5,938 Jan-16-2021, 10:20 PM
Last Post: Miletkir
  How to kill a bash script running as root from a python script? jc_lafleur 4 6,234 Jun-26-2020, 10:50 PM
Last Post: jc_lafleur
  crontab on RHEL7 not calling python script wrapped in shell script benthomson 1 2,440 May-28-2020, 05:27 PM
Last Post: micseydel
  Package python script which has different libraries as a single executable or script tej7gandhi 1 2,742 May-11-2019, 08:12 PM
Last Post: keames
  Check Python version from inside script? Run Pythons script in v2 compatibility mode? pstein 2 9,995 Jul-07-2017, 08:59 AM
Last Post: snippsat
  Cant pass corect variables to python script in bash script neradp 3 6,382 Nov-05-2016, 01:26 AM
Last Post: Larz60+

Forum Jump:

User Panel Messages

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