Yesterday we were working on the switching on/off of the laser spot and on the module wich will ensure security. The features are written but not yet working well. We need modelsim to debug but it is only installed on the school’s computers which are, as you know, not available this week-end. So we decided to give up and focus on the Web part until Monday.
We can now fetch the last few tweets containing a given hashtag on twitter and put them into a database. Another program queries the database to get the newest message and then displays it letter by letter on the oscilloscope. Everything is written in C and working on the Armadeus board.
For twitter, we don’t use any library apart from libcurl, to query the twitter’s API, and jansson to parse the incoming JSON object returned by twitter.
Here a small video, you can see the latest (at this time) tweet on #rose2011, displayed leter by letter on the oscilloscope.
You can read « 75% students attendance during the vacation #rose2011″.
We can pack the result from a query to the database into a JSON object. Inserting values given by a JSON object into the database won’t be difficult.
Next step is to communicate with a client. As we don’t seem to be able to make Mongrell2 work on the Armadeus, we looked for an alternative. Yesterday we have quickly tried a library called libmicrohttpd to handle HTTP queries. We have only tested a simple GET command, but at least it works on the Armadeus, and it is written in pure C. Contrary to CGI, this library is able to manage multiple connections in only one process using Posix threads.
Sur le même sujet :