FAQFAQ   SearchSearch   UsergroupsUsergroups   RegisterRegister   ProfileProfile    Log inLog in   RSS Feed

Re: EyeTV Control script

 
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    Salling Software Forums Forum Index -> Archives
View previous topic :: View next topic  
Author Message
Guest






PostPosted: Sat Apr 26, 2003 9:22 am    Post subject: Re: EyeTV Control script Reply with quote

Here's the first draft of the EyeTV control script. Everything works,
but it's a little ragged and not very user-friendly.

Here's a keymap since I haven't made one yet for the phone.

^ - channel up
v - channel down
< - skip backward
> - skip forward
u - volume up slider
d - volume down slider
s - channel chooser by number
1 - slow backward
2 - pause/play
3 - slow forward
4 - fast backward
5 - mute
6 - fast forward
7 - start recording
8 - stop recording
9 - quit
* - enter full screen
0 - (unassigned)
# - exit full screen

Comments are welcomed. Gently, please... I'm a rookie :-)

Larry

Back to top
Guest






PostPosted: Sat Apr 26, 2003 3:28 pm    Post subject: Re: EyeTV Control script Reply with quote

Perfect! And it's at least as user-friendly as any other remote I've had to spend time
getting used to. The only fixes I had to make (and maybe it's because I copied and
pasted instead of dragging and dropping or something), but your script for me came
up as:

else if keyCode is "<" then
tell application "EyeTV 1.2"
skip backward
end tell

else if keyCode is ">" then
tell application "EyeTV 1.2"
skip forward
end tell

where I had to change the "<" to a < and the ">" to to >

A couple things I'm going to try working on for the empty "0" key is to open the
programming list and bring it forward or figure out how to close the virtual remote (it
seems to pop up regularly on its own accord). The latter I'm not so sure about, since
it doesn't work like a regular window.

Thanks for your time on this, Larry. Be sure to inform the EyeTV people of this.


--- In ericssonclient@yahoogroups.com, Larry Arnold wrote:
> Here's the first draft of the EyeTV control script. Everything works,
> but it's a little ragged and not very user-friendly.
>
> Here's a keymap since I haven't made one yet for the phone.
>
> ^ - channel up
> v - channel down
> < - skip backward
> > - skip forward
> u - volume up slider
> d - volume down slider
> s - channel chooser by number
> 1 - slow backward
> 2 - pause/play
> 3 - slow forward
> 4 - fast backward
> 5 - mute
> 6 - fast forward
> 7 - start recording
> 8 - stop recording
> 9 - quit
> * - enter full screen
> 0 - (unassigned)
> # - exit full screen
>
> Comments are welcomed. Gently, please... I'm a rookie :-)
>
> Larry


Back to top
Guest






PostPosted: Sat Apr 26, 2003 5:23 pm    Post subject: Re: EyeTV Control script Reply with quote

Since I never use EyeTV in full-screen mode, I changed "*" to show the programs
window and the "#" to show a live TV window. But I still want to use the "0" key to
close the EyeTV's virtual remote control. It's referred to as the "controller window" in
EyeTV's Applescript dictionary, but every control command I've come up with so far
has no effect on it or brings up an error. Ideally, EyeTV should include an preference
option to supress the controller, but would anyone know how to control it with SEC in
the meantime?

Thanks again, Larry. This is working out great.


--- In ericssonclient@yahoogroups.com, Larry Arnold wrote:
> Here's the first draft of the EyeTV control script. Everything works,
> but it's a little ragged and not very user-friendly.
>
> Here's a keymap since I haven't made one yet for the phone.
>
> ^ - channel up
> v - channel down
> < - skip backward
> > - skip forward
> u - volume up slider
> d - volume down slider
> s - channel chooser by number
> 1 - slow backward
> 2 - pause/play
> 3 - slow forward
> 4 - fast backward
> 5 - mute
> 6 - fast forward
> 7 - start recording
> 8 - stop recording
> 9 - quit
> * - enter full screen
> 0 - (unassigned)
> # - exit full screen
>
> Comments are welcomed. Gently, please... I'm a rookie :-)
>
> Larry


Back to top
Guest






PostPosted: Sat Apr 26, 2003 6:27 pm    Post subject: Re: EyeTV Control script Reply with quote

As per below, shouldn't this accomplish what I want to do with the controller:

else if keyCode is "0" then
tell application "System Events"
tell process "EyeTV 1.2"
click menu item "Hide Controller" of menu "Window" of menu 1
end tell
end tell

But...it doesn't.

--- In ericssonclient@yahoogroups.com, "Daniel" wrote:
> Since I never use EyeTV in full-screen mode, I changed "*" to show the programs
> window and the "#" to show a live TV window. But I still want to use the "0" key to
> close the EyeTV's virtual remote control. It's referred to as the "controller window"
in
> EyeTV's Applescript dictionary, but every control command I've come up with so far
> has no effect on it or brings up an error. Ideally, EyeTV should include an
preference
> option to supress the controller, but would anyone know how to control it with SEC
in
> the meantime?
>
> Thanks again, Larry. This is working out great.



Back to top
Guest






PostPosted: Sat Apr 26, 2003 7:43 pm    Post subject: Applescript Error (see log for more info) -> but where..? Reply with quote

Where can I find the log file that SEC Helper Message points to..?

trabi12


Back to top
Guest






PostPosted: Sat Apr 26, 2003 7:48 pm    Post subject: Re: EyeTV Control script Reply with quote

Nebbermind...

This one works:

else if keyCode is "0" then
tell application "EyeTV 1.2"
activate
end tell
tell application "System Events"
tell process "EyeTV"
tell menu bar 1
click menu item "Hide Controller" of menu "Window"
end tell
end tell
end tell


--- In ericssonclient@yahoogroups.com, "Daniel" wrote:
> As per below, shouldn't this accomplish what I want to do with the controller:
>
> else if keyCode is "0" then
> tell application "System Events"
> tell process "EyeTV 1.2"
> click menu item "Hide Controller" of menu "Window" of menu 1
> end tell
> end tell
>
> But...it doesn't.
>



Back to top
Guest






PostPosted: Sat Apr 26, 2003 7:50 pm    Post subject: Re: Applescript Error (see log for more info) -> but where.. Reply with quote

> Where can I find the log file that SEC Helper Message points to..?

In the SEC menu in the menu bar.


Back to top
Guest






PostPosted: Sat Apr 26, 2003 9:34 pm    Post subject: WebRadio script now working Reply with quote

For anyone interested:

Here is the SEC script that brings me 7 Dutch Radio stations.

Regards,

Trabi12


-------------------script-----------------------------
global station_URLs, station_names


set URLstrings to "http://www.omroep.nl/Radio1/live20.asx
http://www.omroep.nl/Radio2/live20.asx
http://www.omroep.nl/Radio2/live64.asx
http://www.omroep.nl/Radio3/live20.asx
http://www.omroep.nl/Radio4/live20.asx
http://www.omroep.nl/Radio4/live64.asx
http://www.omroep.nl/747am/live20.asx
--[live20 en live64 staat voor een 20k of 64 kbits-verbinding]"

set fApp to ""
set the station_names to {}
set the station_URLs to {}
repeat with i from 1 to the count of paragraphs of URLstrings
set thePar to (paragraph i of URLstrings)
if "--" is not in (thePar) then
set the end of the station_URLs to thePar
if "20.asx" is in thePar then
set the end of the station_names to word 3 of thePar & " [20 kB]"
else if "64.asx" is in thePar then
set the end of the station_names to word 3 of thePar & " [64 kB]"
else
set the end of the station_names to word 3 of thePar
end if
end if
end repeat

try
tell application "SEC Helper"
enter list mode title "Select station:" items station_names
end tell
on error
beep
end try

on item_was_selected(itemIndex)
set the station_name to item itemIndex of the station_names
tell application "SEC Helper"
show screen message station_name
end tell
set the station_URL to item itemIndex of the station_URLs
my doIt(station_URL)
end item_was_selected

on doIt(station_URL)
if "Radio" is in word 3 of station_URL then
set station_URL to text from word 1 to word 2 of station_URL & "/r"
& text from character 23 to last character of station_URL

set theURL to station_URL
try
tell application "Finder" to set Asbak to (path to trash folder) as
string
on error
tell application "Finder" to set diskz to (the disks)
set disk1 to name of (item 1 of diskz)
tell application "Finder" to set Asbak to disk1 & ":.Trashes:501:"
end try

set tStr to time string of (current date)
set tPart to word 1 of tStr & "." & word 2 of tStr & "." & word 3 of tStr

tell application "URL Access Scripting"
set strName to Asbak & "streampie " & tPart
download theURL to (strName) replacing yes -- .smil
set the_file to the result
end tell

tell application "Windows Media Player"
launch
open the_file
end tell
end doIt

on menu_was_dismissed()
try
tell application "SEC Helper"
show screen message "No station selected..."
end tell
on error
beep
end try
end menu_was_dismissed


Back to top
Guest






PostPosted: Thu May 01, 2003 6:39 am    Post subject: Re: EyeTV Control script Reply with quote

Daniel, you sed:

> This one works:
>
> else if keyCode is "0" then
> tell application "EyeTV 1.2"
> activate
> end tell
> tell application "System Events"
> tell process "EyeTV"
> tell menu bar 1
> click menu item "Hide Controller" of menu "Window"
> end tell
> end tell
> end tell

Haven't got it to work for me and I wonder if it's because you have Applescript
extensions installed and I don't. I tend to keep my system "showroom stock".

I did contact El Gato and let them know what's going on. They replied, "Cool!" & gave
me permission to use their logo on my web page... which is nearly ready for the
masses. I'd like to include this "Hide Controller" module if we can sort out the glitch
and with your permission, of course.

Haven't had time to work on a menu for the phone yet. I will at some point.

Larry


Back to top
marook
Hero


Joined: 30 Jul 2004
Posts: 336
Location: Copenhagen

PostPosted: Thu May 01, 2003 7:49 am    Post subject: Re: Re: EyeTV Control script Reply with quote

Hi...

On torsdag, maj 1, 2003, at 06:39 Europe/Copenhagen, Larry Arnold wrote:

>
> > tell application "System Events"
> > tell process "EyeTV"
> > tell menu bar 1
> > click menu item "Hide Controller" of menu "Window"
> > end tell
> > end tell
> > end tell
>
> Haven't got it to work for me and I wonder if it's because you have=20
> Applescript
> extensions installed and I don't. I tend to keep my system "showroom=20
> stock".

He's using GUI Scripting!

____________________________________________
Jakob Peterh=E4nsel
Technical Engineer
Tel: +45 7022 1014
Fax: +45 7022 1013
Mob: +45=A040 16 38 06
jp@n...
www.NetPoint.com

Back to top
View user's profile Send private message Visit poster's website AIM Address MSN Messenger
Guest






PostPosted: Thu May 01, 2003 2:53 pm    Post subject: Re: EyeTV Control script Reply with quote

Larry,

As Jacob noted, I'm using GUI scripting. The hide controller script is a variation of a
script ("Selecting a menu item") that I found here on Apple's site:

http://www.apple.com/applescript/GUI/#1001

A link to the UI Scripting bega software can be downloaded from the above page.

I can assure you the script works if you still want to include it in the finished product
and still keep your own system clean. But I've had no problems with having installed it
and it opens up a lot of possiblities for scripting.

But yes, feel free to use it and good luck on adding a help menu for the layout. I tried
putting one in myself but didn't put my whole heart into it, since it would have
required an empty key that I couldn't spare. So maybe you'll just want to include it in
a readme (although I can't imagine "slow motion reverse" being used very regularly
over some more important functions).

Two functions I did change for my own personal viewing habits was to change two
keys to switch back and forth between "Normal Size" and "Half Size" (which also
require GUI scripting).

Daniel

--- In ericssonclient@yahoogroups.com, "Larry Arnold" wrote:
> Daniel, you sed:
>
> > This one works:
> >
> > else if keyCode is "0" then
> > tell application "EyeTV 1.2"
> > activate
> > end tell
> > tell application "System Events"
> > tell process "EyeTV"
> > tell menu bar 1
> > click menu item "Hide Controller" of menu "Window"
> > end tell
> > end tell
> > end tell
>
> Haven't got it to work for me and I wonder if it's because you have Applescript
> extensions installed and I don't. I tend to keep my system "showroom stock".
>
> I did contact El Gato and let them know what's going on. They replied, "Cool!" &
gave
> me permission to use their logo on my web page... which is nearly ready for the
> masses. I'd like to include this "Hide Controller" module if we can sort out the glitch
> and with your permission, of course.
>
> Haven't had time to work on a menu for the phone yet. I will at some point.
>
> Larry


Back to top
Display posts from previous:   
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    Salling Software Forums Forum Index -> Archives All times are GMT + 2 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group