Hi all,
We are happy to announce “I Know What You Are Going To Do This Summer
2010”,[1] a free (as in freedom), online (IRC-based) [2] training
sessions for wannabes to Free/Libre/Open Source Software at #dgplug on
irc.freenode. net [3].
If you are a mentor, or trainer, or prospective enthusiast who would
like to participate in this years’ sessions please go through last
years’ IRC logs:
http://www.dgplug.org/irclogs/</a><br><br>We will have a review or Q&A session on last years’ sessions before we
proceed into new topics, this year.
The session timings are mostly varying, usually after 1900 IST every day.
To participate you need a good internet connection and any latest
linux installed (Fedora 12⁄13 preferably ). Anyone can participate.
If you are interested in participating, please confirm your
participation by sending an off-list mail to me (kushaldas AT gmail DOT com).
URL: http://dgplug.org/intro/</a><br>Planet: <a href=“http://planet.dgplug.org/" target=”_blank” style=“color: rgb(42, 93, 176); “>http://planet.dgplug.org/</a><br>Wiki: <a href=“http://wiki.dgplug.org/" target=”_blank” style=“color: rgb(42, 93, 176); “>http://wiki.dgplug.org/</a><br>Mailing list group (for queries, discussions) :
http://lists.dgplug.org/<wbr>listinfo.cgi/users-dgplug.org</a><br><br>[1] <a href=“http://wiki.dgplug.org/index.php/SummerTraining10" target=”_blank” style=“color: rgb(42, 93, 176); “>http://wiki.dgplug.org/index.<wbr>php/SummerTraining10</a><br>[2] <a href=“http://en.wikipedia.org/wiki/Internet_Relay_Chat" target=”_blank” style=“color: rgb(42, 93, 176); “>http://en.wikipedia.org/wiki/<wbr>Internet_Relay_Chat</a><br>[3] <a href=“http://fedoraproject.org/wiki/Communicate/IRCHowTo" target=”_blank” style=“color: rgb(42, 93, 176); “>http://fedoraproject.org/wiki/<wbr>Communicate/IRCHowTo</a><br></span>
I am happy to announce the release of lekhonee-gnome 0.9.1 . You can download the source or check for koji builds for F12 or F13. New features are like:
Binary sketch size: 892 bytes (of a 30720 byte maximum)
/home/kdas/code/arduino/arduino-0018/hardware/tools/avrdude -C/home/kdas/code/arduino/arduino-0018/hardware/tools/avrdude.conf -v -v -v -v -patmega328p -cstk500v1 -P/dev/ttyUSB0 -b57600 -D -Uflash:w:/tmp/build6600949432041572401.tmp/Blink.cpp.hex:i
avrdude: Version 5.10, compiled on Feb 19 2010 at 10:03:26
Copyright © 2000-2005 Brian Dean, http://www.bdmicro.com/<br> Copyright © 2007-2009 Joerg Wunsch
System wide configuration file is “/home/kdas/code/arduino/arduino-0018/hardware/tools/avrdude.conf”
User configuration file is “/home/kdas/.avrduderc”
User configuration file does not exist or is not a regular file, skipping
Using Port : /dev/ttyUSB0
Using Programmer : stk500v1
Overriding Baud Rate : 57600
avrdude: Send: 0 [30] [20]
avrdude: Send: 0 [30] [20]
avrdude: Send: 0 [30] [20]
avrdude: ser_recv(): programmer is not responding
avrdude: stk500_recv(): programmer is not responding
avrdude done. Thank you.
Any clue how to fix this ?
I just released lekhonee-gnome ( desktop client for Wordpress ) v0.9. You can download the source from here or look for the rpm F-12 or F-13.
I want to plot charts like above (using gnuplot/ matplotlib / anything). I have my data in a text file. Can someone please point me to an example ?
The post is brought to you by lekhonee v0.8
After doing a huge yum update on my F12 box, I found
Running DKMS auto installation service for kernel 2.6.32.9-70.fc12.i686.PAE
usb-storage (1.0): Installing module. …….(bad exit status: 10) Build failed. Installation skipped. Failed.
The post is brought to you by lekhonee v0.8
This is small tutorial showing how one can do XMLRPC in Vala using libsoup. We will call a default demo.sayHello method in Wordpress, this will just return a string “Hello!”.
The code:
using Soup;
public void main(string[] args) { var message = xmlrpc_request_new(“http://kushaldas.wordpress.com/xmlrpc.php","demo.sayHello"); var session = new SessionSync(); session.send_message(message);
string data = message.response_body.flatten().data;
Value v = Value(typeof(string));
try {
xmlrpc_parse_method_response(data, -1,v);
}
catch(Error e) {
debug("Error while processing the response");
}
string msg = v.get_string();
debug("Got: %s\n", msg);
}
At the very first line we mention that we are using the libsoup, then using xmlrpc_request_new method we create a message. It requires the URL and method name strings. It also takes optional arguments to the method (which we will see in the next example). Then in the next few lines we are creating a SessionSync object and call the method using send_message method. The response stays in the same message object we created before. We get the response as string in the variable data.
xmlrpc_parse_method_response takes the response as a string in the first argument, next is the length(size) of the response (Note: I used -1 so that it will take the size of data, it comes handy when the response contains unicode chars) and 3rd argument is the Value where it will store the parsed result. string msg = v.get_string() gives us the final result , which we print using debug.
Now to compile the code I gave the following command
$ valac –pkg libsoup-2.4 –thread xmlrpc-test.vala
The output
$ ./xmlrpc-test
** (process:28319): DEBUG: xmlrpc-test.vala:17: Got: Hello!
In the next example we will try to add two numbers using another demo method given by wordpress. The code is given below
using Soup;
public void main(string[] args) { var message = xmlrpc_request_new(“http://kushaldas.wordpress.com/xmlrpc.php","demo.addTwoNumbers",typeof(int),20,typeof(int),30); var session = new SessionSync(); session.send_message(message);
string data = message.response_body.flatten().data;
Value v = Value(typeof(int));
try {
xmlrpc_parse_method_response(data, -1,v);
}
catch(Error e) {
debug("Error while processing the response");
}
int msg = v.get_int();
debug("Got: %d\n", msg);
}
Here while creating the message, we passed the required arguments to the method demo.addTwoNumbers, it goes as type and value pair, so we wrote typeof(int) and then the integer value.
Compilation and result
[kdas@d80 vala]$ valac –pkg libsoup-2.4 xmlrpc-test2.vala –thread
[kdas@d80 vala]$ ./xmlrpc-test2
** (process:28565): DEBUG: xmlrpc-test2.vala:17: Got: 50
A small tip: If you don’t know the return type , use type_name() to find out. Thanks to the people in #vala who are continuously helping me to understand more of it.
The post is brought to you by lekhonee v0.8
Testing the upcoming version of lekhonee-gnome frontend.
GNUnify2010 was the first for me. Started a bit early to the venue, Rahul was along with me. His talk was in top of schedule. I slowly moved to the lab where my python workshop was scheduled.
The main target of the workshop was to show/teach the basics of the python programming language. I hear mostly students asking “How to start working on a project?” but as the learning curve is not so easy in most of the things, they run away. The only students we have from India who are contributing to any FOSS projects are the people who came in their own interest. I found programming with python can be an easy entry point for the general students and they can become better programmer in life. This is the main reason behind my python workshops in different places.
No need to buy books, great online community, projects working on different dimensions, all of these can generate interest in the students.
Coming back to my workshop, I generally try to follow my own book (which I have to update). Slowly going through simple examples and showing that it is not difficult. I ask the students to solve the lab works they do in any programming lab in python. This will help them to understand the basics of the language. The workshop lab was supposed to have 30 students, but many more came so I had to ask them to seat in groups in the computers (most of them was running Fedora ). The basic feedback I got, states that it was easy, but how the students are going to use this, I have no clue. Btw, most of the students in my workshop were from Pune University Maths department, I told them to attend Ramki’s workshop in the second half as his workshop was about explaining how to solve mathematical problems.
At the end of the workshop I showed few applications written in python and talked about job opportunity in market. 2 students contacted me after the event.
Full set of the event photos can be found here.
Coming month, I will be in Durgapur, doing another python workshop , I will also conduct a Django workshop.
The post is brought to you by lekhonee v0.8
You can find the pics at here.
This work is licensed under a Creative Commons Attribution-Noncommercial-Share Alike 2.5 India License.
The post is brought to you by lekhonee v0.8