Client/Server Question

diffuser78 at gmail.com diffuser78 at gmail.com
Thu Aug 10 14:32:22 EDT 2006


The subprocess module didn't work here. I tried using os.popen(), that
won't help it either.


What I am trying to achieve is that the server daemon is sitting and
listening to command from the client. As client send "MaxSim" it
launches MaxSim.exe and then again waits for subsequent commands.
Support client sends "DrivingSim" it should launch DrivingSim.exe etc.
It does till client sends a "SHUTODWN" message upon which it shuts down
itself.

Any pointers to achieve this more seamlessly.

Every help is greatly appreciated.

Thanks


Dennis Benzinger wrote:
> os.system() blocks until the called program has finished. Use the
> subprocess module <http://docs.python.org/lib/module-subprocess.html>:
>
> <untested_code>
>
> import subprocess
> 
> subprocess.Popen("notepad")
> 
> </untested_code>
> 
> 
> Dennis




More information about the Python-list mailing list