Follow

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use
Contact

How can I use python to control multiple concurrant command line programs?

I’d like to use a python program to send different videos to different devices.

My plan is to use ffmpeg to control the video and the destination (I can do this for one destination using os.system) but I’m not sure how to write concurrent ffmpeg commands so that 6 videos are playing at the same time on different devices.

Initially I thought I could use tmux but I can’t find a solution for how to control/access different tmux windows within my python program. Am I missing something obvious?

MEDevel.com: Open-source for Healthcare and Education

Collecting and validating open-source software for healthcare, education, enterprise, development, medical imaging, medical records, and digital pathology.

Visit Medevel

>Solution :

You can use the python subprocess module for that: https://docs.python.org/3/library/subprocess.html

Add a comment

Leave a Reply

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use

Discover more from Dev solutions

Subscribe now to keep reading and get access to the full archive.

Continue reading