If programming languages were music instruments…
This post is inspired by this blog post by Nathan Rice . Wich talks about if programming languages were cars .
Me and my friends from work liked it very much , and we have imagined , how will programming languages look like if they were musical instruments ?
In our toughs we tried to capture the spirit of the language and the instrument itself , also just for our entertainment .
Assembler :
Very basic stuff , but experienced players can do pretty serious things with it … Damn you can even play it with a pair of spoons and an empty pot .
C
Sticks to basics , still needs experienced pair of hands ..
C++
Basics x2 …
C#
Tries to give a modern look to the old ideas ..
Java
Some older musicians may find it fun to play on concerts … but me , home ? really ??!
Basic
Keeps it simple with very pleasant music in the right hands…
VisualBasic
Yes i will buy this game to play it …
JavaScript
Had a feeling of a game , but people started doing pretty serious things with it ..
Perl
Gives a feeling like the angels them selves have been playing on it .
Erlang
You need to be pretty serious motherf*er to play on that .. but once you know how to play , its gorgeous .
Haskell
Where did you get this thing ? How do i play it ?
PHP
Does the job with many fancy stuff …
Python
Nice and elegant , can play snake music !!! 🙂
Ruby
Some find it more romantic …
Shell Scripting
Very simple .. but some people find it to be a very spiritual instrument …
Go
This one is taking an interesting approach .
Brainfuck
Well this makes some noise , but i want to see you playing music with it !
This were the languages that we are familiar with , so we cannot judge on other languages that exist .. Feel free to post your comments , i will add your suggestions to this list to make it complete .
Remember , this is only our point of view as we see the things . you may feel that some instruments represent their related languages wrong .
Gnome-Shell Extensions Manager
I am really a fan of Gnome Desktop , have been using it for years now . Last year the Gnome-Shell was introduced and i love it very much , i think that the developers of the project did a great job . I have tried to use Unity as part of Ubuntu distribution but it doesn’t feel as natural to me as Gnome-Shell does it . I know that there are many opinions on this subject , but it’s not what i want to talk about . I want to talk about Shell Extensions .
Since introduction of Gnome-Shell there are hundreds of extensions have been available at the new extensions page . There are many great extensions coming up lately . But , sadly there is no nice GUI tool for extension management , lets say i want to disable or enable an extension : the first way is to install gnome-tweak-tool and use it every time you want to change extension state , or you could open up a terminal and manage extensions with “dconf-editor” . That’s just doesn’t seems right to me .
So i thought to write some simple Python GTK script to deal with my problem , but instead i found myself writing an extension that does that for me in simple way . When i began to read about Gnome-Shell Extension System i found that extensions are written in JavaScript with Gnome Bindings ( Gjs ) . That was very tempting , because i never really got a chance to write JS .First i wanted to make an extension App written in Gjs so i wrote an extension manager class but then i decided to make simple extension to make it easier to use . From here it was a matter of days and a lot of Source reading from Gnome-Shell Git repository . Sadly for the moment there are no proper documentation available regrading Extension Development . If you want to start developing new extension i suggest to check this blog first , the guy has a lot of really usefull information to use as a starting point .
There is a screen-shot of the first version :
As you can see it is really simple and easy to use . I have uploaded it to gnome extensions site , so if anyone is interested here it is . After uploading it , i got some user feedback emails and i think i should add some features to it, because now it looks really basic and does only what it intended to do for me ( only user extensions are visible , and i should add a scroll for maniacs with 30 extensions 🙂 ) . I hope that i can make some free time to continue the work on it , but the source is there .. so anyone is welcome to contribute , thats the beauty of linux.
I really hope that the Gnome team will work on some Documentation soon , it will make work much easier for people to make contributions in future .
Installing CadSoft Eagle 6 on Ubuntu x64
Version 6 of the popular PCB and Schematics editor is out in the wild and i decided that it is time make a test run of it .
After downloading a Linux version of the installer i ran into a problem . When trying to run the installer it gave me back this error message : “error while loading shared libraries: libpng14.so.14: cannot open shared object file: No such file or directory”.
After a quick search i realized that Ubuntu only has libpng12 in their repo’s . Well i thought that it’s not a big deal since i can build the latest version from source , after downloading and building from ftp://ftp.simplesystems.org/pub/libpng/png/src/libpng-1.4.8.tar.bz2 i ran into another problem , because my Ubuntu 11.10 system is 64-bit the installer where complaining about wrong ELF type . That made me a little nervous , but after another quick search i found slackware libpng 32-bit binaries . You can download if from here : http://slackware.osuosl.org/slackware-current/slackware/l/libpng-1.4.8-i486-1.txz . Then after downloading and unpacking the archives go to “/libpng-1.4.8-i486-1/usr/lib” and link “libpng14.so.14.8.0” to “/usr/lib/libpng14.so.14” .
That made the trick for me and Eagle installation went ok from here .
(Bus)Pirate Arduino

Usually i make a lot of small projects like this led blinking and play with some sensors but i have never documented the process only YouTube uploads of some to share with close friends , but from today i will start doing it and i will post each project on my blog .
I realized that with all of my projects i find myself googling a lot for piece of information and almost all the time i find the info i need on Forums or Blog’s of other people that decide to share . Now i think it is a time to stop only using the machine and start contributing to the whole thing .
I sincerely hope that this information will come handy to anybody or just be interesting material to read , thats my first attempt to write a blog about something , so wish me luck on this 🙂
In the first post i want to show you how i got Breadboard Arduino assembled . i was thinking about it for a long time , because i want to make a finished project and put it in my collection but buying an Arduino board for each one is not an option for me . Also before switching to Linux only i dropped the PIC programming deal and started a new clean page with Atmel chips . What i liked about Pic is that i could stick this one chip to breadboard and start messing with a lot of wires , its just seems more right to me , i don’t know why .
Anyway as i decided to stick Atmega 328P to my breadboard i realized that i didn’t have any programmer on hand and lucky me , i bought a Bus Pirate from SparkFun about year ago .Great tool that another time proved to me how great it is .
The Bus Pirate 5.10 is fully supported by AVRDude from version 5.8 and could be used to load Arduino bootloader to my chip .
After some breadboarding as described on Arduino site i got it assembled and it was time for Bus Pirate connecting .
As i found earlier there are two types of ribbon cable used by SparkFun and Seeed Studio . Mine was purchased from SparkFun so the cable colors are backwards from the Seed Studio arrangement . Adafruit probe set has identical colors to Seeed .
Here are the color codes for both of them :SparkFun Cable , Seeed Cable .
I dont have any ISP headers on hand so i just connected it with jumper wires directly into the Bus Pirate’s cable . The connections for Arduino ISP are as following :

After all connections are set its time to program a bootloader using AVRDude . New Arduinos come with Optiboot bootloader that you can get here , i have downloaded but you can choose the right one for you .
It’s time to check if the connections are right and i have not messed anything . To do this i am running a command from a terminal : “avrdude -c buspirate -p m328p -v -P /dev/ttyUSB0” .
If everything went ok we should see output something like this :
avrdude: Version 5.10, compiled on Jun 29 2010 at 21:09:48
Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/
Copyright (c) 2007-2009 Joerg WunschSystem wide configuration file is “/etc/avrdude.conf”
User configuration file is “/home/rapt0r/.avrduderc”
User configuration file does not exist or is not a regular file, skippingUsing Port : /dev/ttyUSB0
Using Programmer : buspirate
AVR Part : ATMEGA328P
Chip Erase delay : 9000 us
PAGEL : PD7
BS2 : PC2
RESET disposition : dedicated
RETRY pulse : SCK
serial program mode : yes
parallel program mode : yes
Timeout : 200
StabDelay : 100
CmdexeDelay : 25
SyncLoops : 32
ByteDelay : 0
PollIndex : 3
PollValue : 0x53
Memory Detail :Block Poll Page Polled
Memory Type Mode Delay Size Indx Paged Size Size #Pages MinW MaxW ReadBack
———– —- —– —– —- —— —— —- —— —– —– ———
eeprom 65 5 4 0 no 1024 4 0 3600 3600 0xff 0xff
flash 65 6 128 0 yes 32768 128 256 4500 4500 0xff 0xff
lfuse 0 0 0 0 no 1 0 0 4500 4500 0x00 0x00
hfuse 0 0 0 0 no 1 0 0 4500 4500 0x00 0x00
efuse 0 0 0 0 no 1 0 0 4500 4500 0x00 0x00
lock 0 0 0 0 no 1 0 0 4500 4500 0x00 0x00
calibration 0 0 0 0 no 1 0 0 0 0 0x00 0x00
signature 0 0 0 0 no 3 0 0 0 0 0x00 0x00Programmer Type : BusPirate
Description : The Bus PirateBusPirate: using BINARY mode
BusPirate binmode version: 1
BusPirate SPI version: 1
avrdude: AVR device initialized and ready to accept instructionsReading | ################################################## | 100% 0.06s
avrdude: Device signature = 0x1e950f
avrdude: safemode: lfuse reads as FF
avrdude: safemode: hfuse reads as D2
avrdude: safemode: efuse reads as 5avrdude: safemode: lfuse reads as FF
avrdude: safemode: hfuse reads as D2
avrdude: safemode: efuse reads as 5
avrdude: safemode: Fuses OK
BusPirate is back in the text modeavrdude done. Thank you.
if returned an error check your connections and try again . if everything was ok then you should unblock bootloader section on the chip by entering this command :
“
avrdude -c buspirate -p m328p -P /dev/ttyUSB0 -U lock:w:0x3f:m"
After the chip is unlocked you should set the fuses and burn the bootloader :
"avrdude -c buspirate -p m328p -P /dev/ttyUSB0 -U efuse:w:0x05:m -U hfuse:w:0xD2:m -U lfuse:w:0xFF:m -U flash:w:optiboot_atmega328.hex"
Now you must lock the bootloader section again :
“
avrdude -c buspirate -p m328p -P /dev/ttyUSB0 -Ulock:w:0x0F:m"
Thats it , now you can burn arduino sketches to the chip . Also worth mentioning that for Fuse bits you can use this Fuse Calculator if you plan to make changes in this design or just burning a blank atmega chip for the first time .
Also i would like to mention that after doing this i found another way of burning the bootloader but this time from Arduino environment itself . You can choose the way that looks right to you . As i said earlier i just like to mess with stuff 🙂
To do this you must make some changes to Arduino IDE configuration files . First go to your arduino folder , usually it can be found at “/usr/share/arduino” if not there just type “whereis arduino” in terminal window . From there you should go to “ARDUINO_FOLDER/hardware/arduino” and you will find 2 files there that we will need to make changes to : boards.txt and programmers.txt . First lets edit the boards file , open the file with your favorite text editor , i just use Gedit for this kind of stuff . Also make sure that you have a permission to write to this file .
After the file is open just add the following lines :
#############
jkdBP32816.name=Bus Pirate Atmega328 16MHzjkdBP32816.upload.using=buspirate
jkdBP32816.upload.maximum_size=30720jkdBP32816.bootloader.low_fuses=0xFF
jkdBP32816.bootloader.high_fuses=0xDA
jkdBP32816.bootloader.extended_fuses=0x05
jkdBP32816.bootloader.path=atmega
jkdBP32816.bootloader.file=ATmegaBOOT_168_atmega328.hex
jkdBP32816.bootloader.unlock_bits=0x3F
jkdBP32816.bootloader.lock_bits=0x0FjkdBP32816.build.mcu=atmega328p
jkdBP32816.build.f_cpu=16000000L
jkdBP32816.build.core=arduino
#########################
jkdBP32808.name=Bus Pirate Atmega328 8MHzjkdBP32816.upload.using=buspirate
jkdBP32808.upload.maximum_size=30720jkdBP32808.bootloader.low_fuses=0xFF
jkdBP32808.bootloader.high_fuses=0xDA
jkdBP32808.bootloader.extended_fuses=0x05
jkdBP32808.bootloader.path=atmega
jkdBP32808.bootloader.file=ATmegaBOOT_168_atmega328_pro_8MHz.hex
jkdBP32808.bootloader.unlock_bits=0x3F
jkdBP32808.bootloader.lock_bits=0x0FjkdBP32808.build.mcu=atmega328p
jkdBP32808.build.f_cpu=8000000L
jkdBP32808.build.core=arduino
#############
This should add the ability to select Bus Pirate board from boards list in Arduino IDE . You can use Bus Pirate to program your Arduino chip or connect a FT232 USB to Serial if you have it on hand , i prefer to use it over a Bus Pirate for everyday programming , but if you don’t have any of these on hand you can program it with bus pirate only , i find the speed to be little slower but it should do the job fine .
next you should edit the programmers.txt file and add the following lines :
########################
buspirate.name=Bus Pirate Real
buspirate.communication=serial
buspirate.protocol=buspirate
#########################
Thats it save the file and go to your Arduino IDE to check if everything works as it sould , Select Bus Pirate Atmega 328 from The Tools > Boards menu , set the Serial port and Burn a bootloader with Bus Pirate option .
Here some Photos from the actual setup : Image1 , Image2 .
It is too late now so i am going to think what to do next with the board tomorow . stay tuned .

















