473,396 Members | 1,940 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

How to write a programe that include both pipe(low speed system call)and signal

Hi,
I have know that signal will interrupt some kind low speed system
call like pipe. But how to design a program that both support signal
and pipe?

I have a mplayer.py to play movie via os.popen2() and mplayer
slave mode. And there is a mplayer_ctl.py send signal to mplayer.py to
trigger function from mplayer.py. Sometimes os.popen2() is reading or
writing when user run mplayer_ctl.py the bad things raise...

Is there some better way to design the programe? Thank you
--
LinuX Power
Feb 15 '07 #1
1 1337
On Feb 15, 2:51 am, Marco <m...@waven.comwrote:
Hi,
I have know that signal will interrupt some kind low speed system
call like pipe. But how to design a program that both support signal
and pipe?

I have a mplayer.py to play movie via os.popen2() and mplayer
slave mode. And there is a mplayer_ctl.py send signal to mplayer.py to
trigger function from mplayer.py. Sometimes os.popen2() is reading or
writing when user run mplayer_ctl.py the bad things raise...

Is there some better way to design the programe? Thank you

--
LinuX Power
Take a look at the subprocess module, which is meant to replace
popen[1,2,3...](). Also, please try to explain the problem again,
because I just can't decypher everything you're trying to do (and
say).

cheers,
Jordan

Feb 15 '07 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: M Herriott | last post by:
Hello to all - #1: I would have rather used an AND with the choice of newsgroups. I would like to talk to those who subscribe to comp.lang.c++ AND comp.unix.solaris - but I'm stuck with OR....
9
by: misaki | last post by:
Hi all! My name Hùng. I'm a new member. I'm from Viet Nam. I want to ask "How to write a service program that can call and run a script?". Please tell me about this. Thank you very much. ...
7
by: Gernot Frisch | last post by:
Hi, I want to have a representative information about the read and write speeds of a drive (cf-card, HDD and RAM-Disk). I think the buffering of the filesystem must be fooled somehow for my...
46
by: Steven T. Hatton | last post by:
I just read §2.11.3 of D&E, and I have to say, I'm quite puzzled by what it says. http://java.sun.com/docs/books/tutorial/essential/concurrency/syncrgb.html <shrug> -- NOUN:1. Money or...
30
by: Mike C# | last post by:
Hi all, anyone know if there are any Windows functions to retrieve CPU Fan Speed and CPU Temp? Or if it's a BIOS-level call, or something else? If someone out there could just point me in the...
8
by: svata | last post by:
Hello, as I'm new to python I've stumbled accros os.system and its not very well documented usage. I use Win XP Pro and Python 2.5. Here is the code snippet: ...
7
by: Udhay | last post by:
How to get the frequency of an audio file and how to separate the low and high frequency of an audio file
8
by: grikdog | last post by:
How to I capture stdout output from a system call and pipe it back into my running script? system "echo foobar"; # how to continue here with "foobar" in stdin ?? ... I can fake it with...
0
by: =?Utf-8?B?QnJ5YW4=?= | last post by:
Hello group. I've migrated from Win 2003 server to Win 2008 server. I've been banging my head agaist a wall for several days now trying to figure this out. I have the following script that will...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.