We closed this forum 18 June 2010. It has served us well since 2005 as the ALPHA forum did before it from 2002 to 2005. New discussions are ongoing at the new URL http://forum.processing.org. You'll need to sign up and get a new user account. We're sorry about that inconvenience, but we think it's better in the long run. The content on this forum will remain online.
IndexProgramming Questions & HelpProcessing Implementations › Searching XML - Outputting Values
Page Index Toggle Pages: 1
Searching XML - Outputting Values (Read 2136 times)
Searching XML - Outputting Values
May 27th, 2009, 7:49am
 
Basic outline:

I want to download the latest tweets from Twitter, i'll be using the public timeline.I then want to search each tweet individually for certain words. depending on which words are in the tweet then it will out put a different value between 22- 53 and send it down the serial port to my Arduino. I've made a wall of light bulbs each with their own topic, each lighting circuit is connected to a pin on my Arduino (the pins go from 22 - 53). When I open each pin then it lights up the lightbulb on the circuit. SO the end effect is that i download the tweet, it searches it for key words, depending on what words are returned it will light up the appropriate bulb labels with the right topic.

What I need help with is importing the XML file, searching the file for the key words, and then outputting the right value.

I have no idea how to go about this and I have an extra problem of it needing to be finished by tomorrow morning, so if someone could help me I would be VERY VERY VERY grateful.



Thank you.
Re: Searching XML - Outputting Values
Reply #1 - May 27th, 2009, 9:02am
 
In what implementation? JavaScript (unlikely...)? Ruby? Python?
Code depend on the answer...

Showing how you get the feed, etc. might help too. What Twitter library are you using?
Re: Searching XML - Outputting Values
Reply #2 - May 27th, 2009, 9:25am
 
I want to write this in processing. I believe there is a way to import XML into processing already built in? & I want to search the XML using Processing.
Re: Searching XML - Outputting Values
Reply #3 - May 27th, 2009, 10:05am
 
If you mean regular Processing, you are in the wrong section of the forum...

Beside, you can search Twitter on the forum (remember to extend the time span), you will find lot of threads. Apparently most of them use some kind of Twitter library.

But yes, there is an XML library built in Processing.
Re: Searching XML - Outputting Values
Reply #4 - May 27th, 2009, 10:09am
 
Sorry, my bad. I've moved the thread Smiley
Page Index Toggle Pages: 1