News : The level of daily SPAM has reached insane proportions, all registrations are now manual. I ask you to send me an e-mail (john (at) murga (dot) org), to confirm that you want me to create an account for you.


Post Reply  Post Thread 
Controling mpg321 with murgaLua.
Author Message
mikshaw
Senior Member
****


Posts: 522
Group: Registered
Joined: Apr 2007
Status: Offline
Reputation: 5
Post: #1
RE: Controling mpg321 with murgaLua.

You can probably ignore what I posted originally. I misunderstood your question.
It seems that mpg321 has to have some sort of symbiotic relationship with its interface? The documentation mentions remote commands, but doesn't say how to send them.

After looking at mpg321 -R abc, it appears to create some strange interactive shell of some sort. That seems an odd way to remotely control an application through a gui. If you consider xmms, for example, the program runs remotely by sending commandline options with the xmms command. Maybe you'll need to change the default output of murgaLua in order to speak with the mpg321 interface, but that's just a wild guess. This sounds like an interesting project.

Original post:

Use os.execute("mpg321 -R") or io.popen("mpg321 -R")
The latter provides a way to directly grab the output of the command, bypassing the need to read and write a temp file.

I don't know a way to monitor continuous program output while keeping control of the interface. I assume it would require a coroutine, but I know nothing about that. It might work using the new murgaLua timer, though.

This post was last modified: 08-16-2007 12:18 AM by mikshaw.

08-16-2007 12:02 AM
Find all posts by this user Quote this message in a reply
Post Reply  Post Thread 

Messages In This Thread
Controling mpg321 with murgaLua. - dvw86 - 08-15-2007, 03:40 PM
RE: Controling mpg321 with murgaLua. - mikshaw - 08-16-2007 12:02 AM

View a Printable Version
Send this Thread to a Friend
Subscribe to this Thread | Add Thread to Favorites

Forum Jump: