Can you put this up on the wiki for posterity's sake?
--
Jerry
If anyone is interested I can post the details here
Hi all
I have created a series of tasks that result in a lovely voice
greeting me in the morning and announcing my first appointment and
todays weather. I thought I'd share the process.
Here’s how I did it:
I created three separate tasks which I will explain in detail below:
Weather, Calendar, and Daily Announcement
Create a task
Weather:
1.HTTP Get
Server:Port rss.wunderground.com/auto/rss_full/global/stations/
02635.xml?units=metric
Mime Type text/xml
(02635 is my location, to find yours go to www.weatherunderground.com
and search for it,
you can also set unit type there. If you click for the RSS feed you
will get the correct URL
and can also use the feed in your browser window to easier identify
splitters in the next steps)
2. Variable Split
Name: %HTTPD Splitter: Forecast for
3. Variable Split
Name: %HTTPD2 Splitter: as of
4. Variable Split
Name: %HTTPD3 Splitter: as of
5. Variable Split
Name: %HTTPD22 Splitter: <description>
6. Variable Split
Name: %HTTPD32 Splitter: <description>
7. Variable Split
Name: %HTTPD222 Splitter: &
8. Variable Split
Name: %HTTPD322 Splitter: &
9. Variable Split
Name: %HTTPD2221 Splitter: :
10. Variable Split
Name: %HTTPD3221 Splitter: :
11. Variable Set
Name: %DAYCOND To: &HTTPD22211
12. Variable Set
Name: %DAYTEMP To: &HTTPD22212
13. Variable Set
Name: %NIGHTCOND To: &HTTPD32211
13. Variable Set
Name: %NIGHTTEMP To: &HTTPD32212
14. Variable Clear
Name: %HTTPD
(Repeat clearing the different %HTTPD variables until all the junk
variables are cleared I have a total of 15 variable clear commands but
I can't find a better way)
This task is now complete and I have four variabes (depending on
forecast of course):
%DAYCOND: Mostly Cloudy. High
%DAYTEMP: 25
%NIGHTCOND: Chance of Rain. Low
%NIGHTTEMP: 17
Create a new task
Calendar:
1. HTTP Get
Server:Port
www.google.com/calendar/feeds/Username%40gmail.com/private-*****************/full?singleevents=true&futureevents=true&orderby=starttime&sortorder=ascending&max-results=1
Mime Type text/xml
(This is your private Google Calendar feed and ofcourse Username and
the ****'s are replaced by your unique value. To get this URL go to
Calendar settings, Calendars, and click on the calendar you want- on
the bottom you will find your private XML address You must replace the
"basic" at the end of the URL with
"full
singleevents=true&futureevents=true&orderby=starttime&sortorder=ascending&max-
results=1"
because you only want the next event and you want them sorted a
specific way etc.(You can of course tweak this as you wish))
2. Variable Split
Name: %HTTPD Splitter: <title type=text'>
3. Variable Split
Name: %HTTPD3 Splitter: </title><content type='text'
4. Variable Split
Name: %HTTPD32 Splitter: startTime='
5. Variable Split
Name: %HTTPD322 Splitter: T
6. Variable Split
Name: %HTTPD3222 Splitter: :
7. Variable Set
Name: %NEXTAPT To: %HTTPD31
8. Variable Set
Name: %NEXTAPTSTART To: %HTTPD32221
9. Variable Clear
Name: %HTTPD
(Repeat clearing the different %HTTPD variables until all the junk
variables are cleared)
This task is now complete and I have two variabes (depending on
calendar of course):
%NEXTAPT: Meeting with John
%NEXTAPTSTART: 09 00
Create a new task
Daily Announcement:
1. Say
Text: Good morning Chris, Your first appointment is %NEXTAPT at
%NEXTAPTSTART.
Todays forecast is %DAYCOND %DAYTEMP and tonight %NIGHTCOND
%NIGHTTEMP. Have a great day.
2. Variable Clear
Name: %DAYCOND
3. Variable Clear
Name: %DAYTEMP
4. Variable Clear
Name: %NIGHTCOND
5. Variable Clear
Name: %NIGHTTEMP
6. Variable Clear
Name: %NEXTAPT
7. Variable Clear
Name: %NEXTAPTSTART
In cleartext this says: "Good morning Chris, Your first appointment is
Meeting with John at 09 00. Todays forecast is Mostly Cloudy. High 25
and tonight Chance of Rain. Low 17. Have a great day.
This task is now complete.
To tie it all together I created a time context named "Fetch Info"
I set the Context to: Time, From 06:00 Til 06:02 and added The tasks
"Calendar" as an entry task and "Weather" as an exit task. This causes
the phone to grab the info and set the variables at 6am while I'm
sleeping since the tasks take a while to run.
You can then add any context you wish as a trigger to run the "Daily
Announcement" task and read you the info.
Try it out and tweak it to your pleasing :)
Calendar (119)
A1: HTTP Get [
Path: Attributes: Cookies: User Agent: Timeout:10 Mime Type:text/xml Output
File: Trust Any Certificate:Off ]
abc being my gmail, a...@gmail.com
xxx being my private key
I get a Input/output Error
java.io file not found exception
Any idea what that is please ?