Just found this new blog application "blogilo" which is part of the upcoming KDE4.4. So if you can read this the app works.
KDE4 rocks !!!
To use blogilo install KDE4.4, or take a look at http://blogilo.gnufolks.org.

Just found this new blog application "blogilo" which is part of the upcoming KDE4.4. So if you can read this the app works.
KDE4 rocks !!!
To use blogilo install KDE4.4, or take a look at http://blogilo.gnufolks.org.
After I’ve read an interesting article about Arduino I obtained an “Arduino Nano V3″, which contains already the newer AVR Atmega 328p micro processor. The starter kit contained also a 3 axis accelerometer (ADXL330), a bread board, an LED, push button and so on.
See www.arduino.cc for more information about the arduino itself.

The nice thing about arduino nano is, that it comes preinstalled with a USB plug so you don’t need to solder yourself. It’s just plug & play and you even do not need a power supply, because it’s powered over USB (external power supply is possible too of course).
The seconds nice thing is that there exists an Open Source IDE, also called “Arduino” which make programming really easy also for people without great programming skills. This IDE is written in JAVA, and so is portable. Underneeth the GUI it uses the AVR-GCC toolchain to compile C and C++ programs and links against AVR-LIBC. The most complicated thing to get it running is building a working AVR toolchain, but Gentoo has this nice “crossdev” script which can generate complete toolchains including compiler, binutils and libc
Installing the AVR Toolchain
To use crossdev you should add the line ‘PORTDIR_OVERLAY=”/usr/local/portage”‘ to your /etc/make.conf.
crossdev -t avr -s4 --without-headers ln -s /usr/i686-pc-linux-gnu/avr/lib/ldscripts /usr/avr/lib/ldscripts emerge avrdude -av
There first line executes the crossdev script which compiles the toolchain for AVR (See crossdev –help for more info). The second line creates a missing symlink due to bug 147155. The third line installs avrdude, a tool for downloading programs to the AVR.
If everything succeeded you should be able to run “avr-gcc –version” to check the compiler version. You need at least avr-libc 1.6.4 to support the Atmega328p, but this is already default meanwhile.
Now you can simply download the Arduino IDE from www.arduino.cc, unpack and run it. For compiling you should select the “Arduino Deumilanove w/ Atmega 328″ via the menu Tools->Board. The normal nano configuration has no Atmega 328.

For downloading you have to select your serial port via Tools->Serial Port. This is /dev/ttyUSB0 normally if it is the first connected tty device.
If you don’t see this device when you plug in the cable you probably don’t have the FTDI driver compiled into your kernel.
Configuring the FTDI USB serial converter
You can activate it via the kernel menu config (you must know how to compile a kernel for that):
Device Drivers -> USB support -> USB Serial Converter support -> USB FTDI Single Port Serial.
To get access to the tty device file you should be in the uucp group. Use “sudo usermod -a -G uucp ” to add the group to a user. This change requires you to relogin to get active.
Before you ask, I did this just for fun
I’m annoyed that the MS sites doesn’t work probably in any browser but IE – what a wonder. I need the site sometimes because I’m developing portable software that also has to run on Windows, and so I often need to figure out the problems where the MS C++ compiler is not standard conform, but that’s another story…
So I asked myself how bad is that standard compliance really. So I put one of the API reference sites into W3C’s markup validator…
The result: 98 Errors, 10 warning(s)
You can recheck that your self using that link Recheck MSDN Site
We cannot loose anything so lets check also the CSS
The result: Sorry! We found the following errors (18)
I’m reading so much at the moment about the new “exploitable” kernel bug that I need to clarify some things, because many things with this exploit are represented in strange ways that give a wrong impression.
1.) First of all it’s stupid NULL pointer deference. A stupid bug that no programmer should made, but shit happens. The good thing with such a bug is that it is easy to fix, and the bug was already patched on 6th of July by Mariusz Kozlowsk which shows how fast the community reacts on security issues.
diff --git a/drivers/net/tun.c b/drivers/net/tun.c
index a1b0697..bcbb25e 100644
--- a/drivers/net/tun.c
+++ b/drivers/net/tun.c
@@ -482,12 +482,14 @@ static unsigned int tun_chr_poll(struct file *file, poll_table * wait)
{
struct tun_file *tfile = file->private_data;
struct tun_struct *tun = __tun_get(tfile);
- struct sock *sk = tun->sk;
+ struct sock *sk;
unsigned int mask = 0;
if (!tun)
return POLLERR;
+ sk = tun->sk;
+
DBG(KERN_INFO "%s: tun_chr_poll\n", tun->dev->name);
poll_wait(file, &tfile->read_wait, wait);
2.) The bug gets exploitable due to some compiler optimizations. But this is really not a problem in GCC. The optimization makes sense, and the problem occurs only because of this bug. Without this bug the optimization is no problem.
3.) How dangerous is the exploit? Despite some articles I’ve read it’s really hard to use this exploit in reality.
So this is exploit is interesting from an academic point of view, because two different things, a programming bug and a compiler optimization lead to an exploit, but it’s really minimum danger for all us normal Linux users.
When you install GIT you should also install the GIT bash completion with it. (On gentoo you just need to set the bash-completion USE flag when emerging git). This makes your life much easier. This can complete git commands like “git stat[TAB]” to “git status”. Additionally it offers the GIT bash function __get_ps1 for your command prompt. You can integrate this into your “PS1″ variable to show the current branch of your working dir on your command prompt. That’s just great, isn’t it?
Add this to your ~/.bashrc to activate the GIT bash completion and the new command prompt.
# load git bash completion source /usr/share/bash-completion/git # Cool trick to show current git branch in the command prompt in gentoo colors. export PS1='\[33[01;32m\]\u@\h\[33[01;34m\] \w$(__git_ps1 " (%s)") \$\[33[00m\] '
If you enter your working dir the prompt will look like this.
gergap@lt_gergap ~/work/helisim (master) $
If you are wondering what this “\[33...]” is for, this is just to set some nice colors for the prompt. You can remove that if you don’t like colors.
I was annoyed by the file name completion in VIM. It completes the whole name of the first match, even if there are a lot of possibilities. That feels like DOS
so that you need a lot of <TAB> to iterate to the correct file.
I wanted to behave like the BASH to complete only the longest possible part and then show a list of possible completions with the second <TAB>.
No problem in high configurable VIM. I found out that this two settings do what I want.
set wildmode=longest:full set wildmenu
I expect there are a lot of opinions to this questions
KDE4 is another Open Source success story. So why should a user be interested in running it on Windows, when there are free alternatives like Linux? Is it not one step back? By only supporting free operating systems this would be another reason for Windows users, that want to use the cool KDE apps, to switch to free operating systems like Linux. So why are Open Source developers are interested in porting it to Windows?
A lot of good questions, and in my opinion all this is right, but there is this KDE4 Windows port and a lot of Windows users are already using it. So for some users it seems to make sense. One reason I heard is that some users are forced to use Windows in their job and so have no choice. With KDE4 for Windows they can now use all the cool KDE applications, that they are used to use from home and are not limited to the applications that come with Windows.
Open Source means to be free. Let you do with it whatever you want, as long as the result of your work offers the same freedom to all other users. Thus it allows you also to port it to Windows and let it run on a proprietary operating systems.
So at the end – if people like it or not – KDE4 on Windows is also part of the freedom of Open Source.
This scripts can replace file headers from C/C++/JAVA header and source files. Often it’s necessary to replace the license conditions in multiple source files, update the copyright year, or simply make all file headers consistent. This can be a lot of work, so that’s why I wrote this scripts.
How it works: The BASH script replace_header.sh is a simple wrapper that executes the AWK script remove_header.awk which implements a basic state machine for recognizing C/C++/JAVA comments (“// …”, “/* … */). All comments at the beginning of the file – also when spanning over multiple lines – are ignored until the first line without comment is reached. The AWK file ignores all this comments, and prints the rest of the file unchanged. The BASH script creates a new file with your new header.template and adds your code without the old file header to the newly created file. Afterwards it copies the new file over the old one.
Example:
find . -name "*.h" -exec ~/rh/replace_header.sh {} \;
Download replace_header_scripts.tar.gz
I normally put my code from VIM with syntax highlighting and line numbers turned on on my blog. This is good for readability, but bad if you want to copy paste it from the web site. With vim it’s easy to remove these line numbers from pasted code. Here is how to do that.
I found this nice GVIM color scheme from Lars H. Nielsen called “wombat”. I wanted to use this also in normal vim, because I prefer working on the console over the graphical vim. For that I needed to convert the scheme to work in 256 color mode of xterm or KDE’s konsole. I found this site very useful to understand why and how to convert the color schemes.
Here are a screenshot and the scheme “wombat256″. To include it store the wombat256 scheme in ~/.vim/colors and add this lines into your .vimrc.
" turn syntax highlighting on set t_Co=256 syntax on colorscheme wombat256

Wombat256: