Beefy Boxes and Bandwidth Generously Provided by pair Networks
Keep It Simple, Stupid
 
PerlMonks  

Remote Controlling Launchcast and with X-10?

by OzzyOsbourne (Chaplain)
on Jul 26, 2004 at 14:15 UTC ( #377422=perlquestion: print w/ replies, xml ) Need Help??
OzzyOsbourne has asked for the wisdom of the Perl Monks concerning the following question:

Long, long ago, I figured out a way to control winamp via an X-10 remote control (Old Post). Recently, I have been contemplating using pieces of this code to control Yahoo's Launchcast, so I don't have to sit in front of the PC to listen. I'd like to rate, skip, play, pause, etc. by sending commands to the Launchcast window.

As the X-10 code *should be* reusable, the only issue, my dear monks, is that I am at a complete loss when it comes to sending commands to the Activex controls in the Launchcast window. Can you suggest anything that may kick this project into gear?

Thanks in advance.

Comment on Remote Controlling Launchcast and with X-10?
Re: Remote Controlling Launchcast and with X-10?
by Corion (Pope) on Jul 26, 2004 at 14:24 UTC

    Depending on how this Launchcast thing works, there are several approaches:

    1. The easiest approach is to use Win32::GUITest and automate the application (your web browser?) by sending keyboard commands and mouse clicks. This is very fragile, but will always "work" in the sense that the application doesn't have much in the way of detecting whether there is an actual user or a program supplying its input.
    2. A little bit less fragile would be the approach to extract the actual ActiveX embedding-HTML into its own page so you do not have to cope with all the clutter surrounding the player control, or alternatively looking at the various ActiveX hosting applications (Excel, wxPerl) and to host the ActiveX control within that container.
    3. An even more elegant way might be available if the ActiveX actually installs and registers itself with Windows so you can automate it through its COM IDispatch interface via Win32::OLE. The easiest way to check is to open the Excel script editor (Alt-F11) and check the Tools->References for any suspicious control you might be able to link in. This would give you full control over all exported hooks of the ActiveX, provided that there are such exported hooks in the first place.
    4. The hardest way is to sniff the network connection with Net::PCap and then to manually decode the data stream yourself. This will be lots of hard work but in the end you will be liberated from Win32 and the ActiveX control and can connect to Launchcast from wherever you have network and Perl.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: perlquestion [id://377422]
Approved by Corion
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others having an uproarious good time at the Monastery: (8)
As of 2014-09-20 13:21 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    How do you remember the number of days in each month?











    Results (159 votes), past polls