Asked
— Edited

Hi guys.
I need a little help with an RSS feed script and hoping someone can point me in the right direction.
Question one.
Is there a way to have an RSS feed to be spoken through the EZB4 instead of through the PC's sound card as I haven't seen a "SpeakRSSEZB() script function?
Question 2.
I am looking for a way to insert something similar to a "Sleep()" function in-between each RSS feed in the script below with a 2 second gap between each feed read.
SpeakRSS("http://feeds.skynews.com/feeds/rss/uk.xml",1)
SpeakRSS("http://feeds.skynews.com/feeds/rss/uk.xml",2)
SpeakRSS("http://feeds.skynews.com/feeds/rss/uk.xml",3)
SpeakRSS("http://feeds.skynews.com/feeds/rss/uk.xml",4)
The "Sleep() script function is not a viable option as the length of the feeds spoken change length from day to day (or hour to hour) so I need something like a "SayWait() but not sure what or where to put the correct function in to my script.
Many thanks.
Steve G.
Well I have spent some time and gone through the entire script command menu, but have not seen a command that will "speak" an RSS feed through the EZ-B v4's speaker, only through my PC's speakers. Is there a way to do this, and if not, can this be an ARC feature request? confused
Thanks.
That's because speak RSSEZB hasn't been added yet... Not sure if it will be added... Maybe it will at some point....
When I wrote "Speak RSSEZB()" it was just example of what I wanted to accomplish
. Hopefully DJ will consider adding this feature if there's no other way. It would be a great addition.
@EZ-Robot team.
Hi guys. I would like to mark this thread as resolved so can I ask, has adding the ability to have an RSS feed to be heard through the EZ-B4 speaker been added to the "to do" list for ARC for a future release?
@everybody else
Has anyone found a way to achieve this with some cleaver scripting? I have had a little play around with scripts but been unable to get it to work.
Thanks.
You could use scripting but the SpeakRSS() command doesn't save the results to a variable, you would need to use HTTPGet() and parse the returned results. Such a simple task is a fair amount of scripting (so I've not even looked at doing it).
I have written an exe In c# that gets all of my rss feeds for the day and places them into text files on my computer. It also strip out the characters that cause issues when reading the rss feeds. In ARC, I read these files into variables. I haven't tried it yet, but you should be able to then use the variable in a speakezb command. I am in the middle of a crisis at work right now. I will post the code for the exe later today when I have time to find it.
It has been a while since I looked at this, but here is a good sample to start with.
This build a file at "C:\rssfeeds\Bible.txt" and uses "http://feeds.feedburner.com/ESV-one-year-tract?format=xml" for the feed.
In ARC I have a script that reads the file into a variable called $rsstext and then uses the Say command to read the variable. This could be changed to the SAYEZB command.
After the reading is complete, it deletes the file and clears the variable to save memory and drive space.
This way allows you to call the exe, which then generates the file on the fly. I had thought about making this database driven to allow you to store the RSS feed locations in a database, and then call them by ID instead of calling the exe.
In any event, it works. Using this the way it is now, you would have to create an exe for each feed, but that isnt hard and keeps you from making it too complicated in the long run. I like to complicate things so I am sure at some point in the future, I will make this database driven and store the text to the database for that day, and then update the variable from the database.
Let me know if you have any questions.
I gave this one because it is impressive how much can be stored in a variable to be passed into the say command.
This part
allows the executable time to get the feed and parse it without the robot sitting and acting like it is waiting for something (which it is).