Twitter tutorial

Anyone interested in completing this

Handling twitter with NETMF has been done many times but it would be great if we can have it documented on wiki please.

I will keep you in mind next time GHI sends gifts out :slight_smile:

Yes, twitter info would be great!
I tried it before, but the authorization was not working correctly and cranking up the sockets somehow. :smiley:

Twitter uses OAuth now which requires authorization and redirects in the browser. I don’t think it’s possible to do anything more than parse feeds.

EDIT: It can be done.

Hmmmm… My Internet of Things kit I got as part of your last random act of kindness has a connect shield that I haven’t cracked the seal on yet. Plus I’ve been wanting to play with connecting a Panda to the web. Sounds like a fun weekend project.

Why not Josh? If a PC can do it then FEZ can do it :slight_smile: (Slower but it should be able to)

@ Gus - What exactly do you envision “Twitter with NETMF” doing? Just tweeting? Tweeting with data tags that are somehow post processed (aggregated)?

I have seen a few (non MF) projects where twitter was used as the data aggregator, but they never really seemed to gain much steam. As an aside, I’ve had success using pachube and ThingSpeak for “Internet of Things” projects.

I would love to see projects for these as well.

As for twitter, it is our job at GHI to empower the community with technologies they didn’t know they could use before. I see how pachube or thingspeak can be a better fit but someone in the community may want to use twitter. I was just going through the tutorials page with Josh and saw how we have everything on there except twitter…and you now reminded me of pachube and thingspeak :smiley:

This looks like it should do the trick…

Like I said earlier, twitter has been done many times for NETMF but the goal is to make this page full of everything a newcomer needs.

What I propose to do is create a tutorial there that would use a Panda + Connect shield + some sensor to send a tweet using the MicroTweet software every time the sensor is tripped. Does that sound sufficient or are you wanting something without using any 3rd party library?

Update OAuth is single user only, and xAuth requires specific permission from Twitter. I’ll go through the work of submitting a request for it, since I’d like to have Twitter on Gadgetos (Pyxis 3) anyway.

Twitter client is alive and well! :smiley:

While this still currently only works for a single user (need to have a complete app w/ video and screen shots before Twitter will give me xAuth access) I can already do the following:

Post Tweets
See Friends
See Followers
Get Tweets from Friends/Followers

Are you going to be updating the Wiki tutorial? I’ve been communicating with the developer of MicroTweet. Currently, it only works with netduino but I’ve offered to port it to FEZ. Waiting on a reply to see how he wants to move forward. Otherwise, I was planning to branch off. If you’re going to post your work to the wiki then there’s not much reason for me to continue.

I dream of a day when all NETMF devices speak the same language… :frowning:

MicroTweet is flawed. I started with it as a base and fixed a few issues. I’ll update the tutorial with oAuth when it’s done; obviously you’ll need your own key though.

Ok. Great! I’ve got my own key already. Eager to try it out.

Hello, I’m the developer of MicroTweet. Unfortunately I ran into the same problem when I tried to get access to xAuth but I was able to authorize additional accounts with the out-of-band/PIN code method. The code for that wasn’t added to the public repository but I could clean it up and add it to the project if it would help. I think most NETMF Twitter applications only need to be single-user though.

Skewworks, if you noticed some specific problems with MicroTweet I’d appreciate if you could provide any more information. Or if you already have working code I could take a look at that as well :slight_smile: I haven’t noticed any issues but so far I have only tested it on a Netduino Plus – Ian is the first person I’ve heard from who has tested it with other boards.

Anyway, let me know if you have any other input. Thanks,

Hey Matt the issue I found was the timestamp. Not sure if it was something you fixed and then didn’t upload but you’re getting GMT and then converting it to local when GMT is what you need. So I was constantly getting time errors from Twitter until I stripped that protion of your code.

I have pretty much all the commands needed for a full client now; all I need to do is put it together in a nice clean application. Time is a bit short for me right now trying to work on 3 pieces of software and get hardware out but I’ll get it out as soon as I can.

Good catch, thanks for pointing that out. That particular code was adapted from a blog post (link is in the source) so I guess I just missed that when adding it in. The issue never appeared for me since my Netduino’s time zone was set to 0.

Thanks for your post, I will get that fixed.

Work in progress…this is the twitter home timeline running on Gadgetos. Lots of cleaning up to do yet.

Is there anything that Gadgetos can’t do? :slight_smile: