News
home-server: Yamaha DX7 and Linux
So, after spending some time setting up my PC yesterday, I wanted to work with it and my Yamaha DX7. When I got it, default sounds were not there, and there were lots of duplicate sounds. What you would need for this tutorial is simply a midi interface (with in and out) and 2 midi cables.
Back in 1983, the DX was one of the first synth to have a midi interface, though it’s not 100% complete and has some limitations. I won’t tell a lot about this since it has already been widely covered. But that means when you turn up qjackctl and any synth software like QSynth , you can already use your DX as a master keyboard.
First thing I wanted to do was making a backup of my sounds and loading the defaults. Second thing I wanted to do was being able to preview the sounds before loading them into my DX.
So, to load and receive sounds on the DX7, you need a software that’s able to handle sysex files. That’s where I found Simple Sysexxer .
It’s quite easy to build, and I’ll probably make a package for it for mageia. Simply type
qmake SimpleSysexxer.pro make
and that’s it (provided you have the dependencies installed).
when you launch it, it appears in qjackctl so you can connect it like in the picture shown below. Start receiving on simple sysexxer.
Now to the DX. By default, sysex are not sent from the DX, so type “function” and button 8. go to Midi Ch=1, type button 8 again and make sysinfo available.
From now on each time you change sound, sysex data will be transferred. So you can start changing to every sound, internal or cartridge and sysex will get through midi. Turn sysinfo unavailable and stop receiving data in simple sysexxer.
In simple sysexxer, you can then save this file and load another one, like rom1a.syx, which is the default bank on the DX.
Turn sysinfo available again, and disable memory protect on internal on the DX:
then you can start emitting the data and the DX will tell you it has received it. That’s it ! Huge kudos to Christoph Eckert for his simple yet very useful software !
Now, there are hundreds of patches for the DX but the DX can only hold 32 internal sounds (later versions could have 64, but mine is a first generation one)
So, what I wanted was to be able to preview sounds before transferring them to the DX7.
Fortunately, there is a DX7 emulator for linux, it’s called hexter . It can load sysex files and use these sounds. It does not sound as good as the original, but that may also be because my PC speakers are nowhere near as good as my keyboard amplifier. It uses a gtk2 interface, so be sure you have the devel dependencies installed to build it. Simply type
./configure make su #type in your root password make install
Then again, I’ll probably build a package for mageia for this one too. You can then launch it with the following command
DSSI_PATH=/usr/local/lib/dssi/ jack-dssi-host hexter.so
and voilà ! connect your DX7 to it and you can play with it.
I still need to figure out how to load sounds to the cartridge but I fear I’ll have to take sounds one by one and save them into the slots of the cartridge.
Hope this will be useful to someone, to conclude this article, here is a small demo of it (coming soon…)
home-server: Migrating to unicorn
It’s been a veeeeery long time since I didn’t wrote anything in this section.
But my tiny little home server is doing really well :-)
Over time I added more and more services to this machine and now it does a whole lot of useful stuff. The downside is that having a server at home is quite risky, especially if you have cats and children !
Anyway, this time I’m going to talk about the webserver part of it.
For two years I’ve been running redmine on it, with phusion passenger, and either apache or nginx. During that time I also used ruby enterprise edition. The problem was that none of these were packaged in mandriva. So it was a bit painful to update it regularly.
Now, I packaged everything :-)
First, I upgraded to Mageia, and the upgrade was flawless.
Then I packaged chiliproject for Mageia, but I was still using passenger, which I installed via gem. Since there are serious issues about passenger which makes its packaging a hard task, I decided that I didn’t want to deal with that.
So I packaged unicorn, and it’s now running here with nginx :-)
I will see over time how it performs, especially regarding memory consumption, but anyway, setting up unicorn was really easy, thanks to this guide .
Now there is finally an alternative to the good old fcgi method in Mageia. I also plan to package thin in the following days, and since we are close to version freeze, I think I won’t import lots of other package for now. At the moment, there are about 200 ruby modules in Mageia, some of which need to be polished a bit I think.
awesome: Awesome 3.4.9 available in Mageia
I’m very glad to announce that awesome is available in Mageia since last week :-)
I finally found a way to solve the cairo-xcb issue. Basically I just duplicated cairo’s package and created a cairo-xcb one. But then I had to ensure the standard cairo would be prefered over cairo-xcb, which turned out to be quite easy, by adding it to /etc/urpmi/prefer.vendor.list.
So now, I’m not sure this section of my website will be very active wrt awesome packaging, it will just hold my config in case you’re interested :-)
I keep older versions of awesome for reference, but you’re encouraged to use the packaged one !
I also took that opportunity to package shifty and vicious for Mageia, the latter one being suggested when you install awesome.
awesome: Moving to zsh (1 comment)
I won’t debate over the advantages of zsh over the other shells, this has always been said multiple times
What I wanted to show is my first steps with this shell.
To begin with, I wanted to customize my prompt and make it VCS aware :)
(You can see an screenshot here)
I’ve found several documentations about zsh prompts and vcs implementations
and I wanted to build my own prompt, and to understand some of what I call zshism, though the intro doc already gives a good overview.
My whole configuration is available on this repository, which turns out to be not only my awesome configs but also my public dotfiles :)
so let’s explain what I did (not that clean, but its usable):
setopt prompt_subst autoload colors colors
This is mandatory for the prompt to work. The first line allows variable to be interpreted and the other two allow the use of colours
# define some colour variables to avoid cluttering the command prompt
for color in red green yellow blue magenta cyan white
do
eval C_$color="%{$fg[$color]%}"
eval CB_$color="%{$terminfo[bold]$fg[$color]%}"
done
C_reset="%{$terminfo[sgr0]%}"
# define a reset var
fSep="$CB_blue:$C_reset"
The syntax here is a bit different from bash, but I like it better, because you can have access to the escape sequences through an associative array which is just way better than putting directly your escape sequences or using tput.
# define brackets oBr="$CB_cyan—$C_reset$C_magenta($C_reset" cBr="$C_magenta)$CB_cyan—$C_reset"
This is just decorative, but I like it
autoload -Uz vcs_info
zstyle ':vcs_info:*' check-for-changes true
zstyle ':vcs_info:*' unstagedstr "$C_red" # red color indicates unstaged changes
zstyle ':vcs_info:*' stagedstr "$C_green" # green color indicates staged changes
zstyle ':vcs_info:*' formats \
'%u%c' '%s' '%b' '%S'
This is the interesting part: zsh has built-in support for many vcses, see the online doc for more information
The first command just loads the module
The next three allows to gather information about your tree, beware, it can be slow, disable it if you work on large repositories (the doc explains how to achieve this)
The last part takes a list of formats and returns it in ${vcs_info_msg_N_} (see below)
precmd () {
# declare local variables
typeset fsScm=""
# revrieve info from vcs
vcs_info
# get status
cSt="${vcs_info_msg_0_}"
This part starts the precmd function and you see an example of the use of the variables you can get. This part just returns the status of your tree (dirty, staged changes). You’ll see below why I need this in my prompt
# set a prompt character according to the used scm
fsScm="${vcs_info_msg_1_}"
case $fsScm in
Here I get the vcs in use in the directory where I am.
"git")
vBr="${vcs_info_msg_2_}"
pCh="$cSt±$C_reset"
;;
"hg")
vBr="${vcs_info_msg_2_}"
pCh="$cSt∂$C_reset"
;;
"svn")
vBr="${vcs_info_msg_2_}"
pCh="$cSt∫$C_reset"
;;
as you can see, I set a different char that reminds the vcs logo.
This character is colorized differently according to its state (works great for git, not for mercurial :/)
*)
vBr=""
pCh="$C_reset%%"
;;
esac
and this is to set up the standard % if I’m not in any of the previous vcs.
# set different colours according to user/host
case $USER in
"root")
aUsr="$C_red%n"
;;
"shikamaru")
aUsr="$C_green%n"
;;
*)
aUser="$C_yellow%n"
;;
esac
case $HOSTNAME in
"nibi"*|"sanbi"*)
aHst="$CB_yellow@$C_red%m"
;;
*)
aHst="$CB_yellow@$C_green%m"
;;
esac
This part is a bit less interesting, I just like to have different colours for my different user/machines :)
vcsPWD=${vcs_info_msg_3_:-.}
}
And finally I get the subdirectory part if I’m in a repo. If for example I’m in /home/shikamaru/repo/awesome/config/ it returns awesome/config, see below why.
Let’s set up the prompt !
# PROMPT # (retval:Branch:PromptChar) PROMPT='$oBr%(?..$C_red%?$fSep)$C_cyan$vBr$fSep$pCh$cBr '
The
%(?..$C_red%?$fSep) returns the exit code of the last command if it’s not 0 ($?). I find it useful as I often used to use echo $? to know it :)$vBr is the branch on which I’m working on, we already had that in Mandriva for bash, but it used some bash-completion functions which can make your shell painfully slow when for instance you run urpmi a-local-package.rpm because it tries first to complete it to the available rpms in the repositories :/
And finally, we display our pretty prompt character. You shouldn’t have problems displaying it if you’re using an utf-8 system, which is the case for most linuxes nowadays, and I chose symbols from the mathematical symbols, which are normally available for you.
pwdMax=$(($COLUMNS-80))
RPROMPT='$oBr$aUsr$aHst$fSep%$pwdMax<…<${PWD/$vcsPWD/$C_yellow$vcsPWD}%<<$cBr'
Now, we display the right part of the prompt. It’s nice to use it because it disappears when you type a longer command than the available place you have, using the left prompt exclusively would make it too long I guess.
We first display the user and hostname and then we’re going on more crazy stuff :)%$pwdMax<…<${PWD/$vcsPWD/$C_yellow$vcsPWD}%<<
This command just displays the path, but truncates it to leave at least 80 columns for the left prompt+commands, which was calculated in the variable $pwdMax. On top of that we colorize the vcs part of that path.
More on this:
The construction number<replace<string<< truncates the string to number characters and adds a replace string for the truncated part (here an ellipsis). This is just insane, AFAIK that’s not something you can find in bash, but it’s very useful in that case :)${PWD/$vcsPWD/$C_yellow$vcsPWD} is another construction that allows substitutions. basically it substitutes the 2nd part of the variable with the third part.
The actual solution is not optimal though, I should also add another substitution to replace the $HOME part of the current directory with ~/, this won’t require much work though :)
I also need to fix a little issue that occurs if my terminal is smaller than 80 columns
awesome: Tidying the repository
Tidy might not be the right word actually, since redmine is a bit confused now :)
For those of you who cloned it (I wonder if there were any actually), I’m sorry.
For now the repo is still as big as it was, since everything has not (yet) vanished.
home-server: Tuxdroid is just awesome
I’d never thought I would get a tuxdroid but I guess my girlfriend couldn’t have given me a better gift :)
So at start I was trying to make a rpm from the software but it will take me some more work because the actual installation script is quite ugly. I’ll try to clean this up.
Still I couldn’t resist to show how it looks like and I must say I’m really impressed !
This is just a small video of the tuxdroid reading planetmandriva’s rss feed, the last item being a post of Adam Williamson’s blog
I’m amazed by how nice it is when the tuxdroid speaks ! The voice is really understandable and expressive, though it’s a bit strange sometimes to hear it say “slash” or “dash”. However I guess I could hack it a bit, because not everything works so well.
Firstly, it doesn’t handle atom feeds contrary to my regular feed reader, canto but that might not be hard to add support to it since both are written in python, maybe it just lacks bindings to python-feedparser. I also have to make it mark feeds as read, cause at the moment it reads the same entry at each alert.
Secondly, it seems like it doesn’t like my mail server, probably because it has a self-signed certificate, but it works with free’s imap and pop server, I might have a look at it too :)
It also speaks french quite nice, gives the weather forecasts and some other nice things like twitter’s messages.
home-server: 10 years of Free Software
Yes, I’m blowing my 10th candle, so I think it would be nice to summarize a bit what I’ve been doing over this period. As wobo interviewed me at the fosdem, and as I never thought of what I could say to introduce myself, I’m taking this occasion too. So this post serves two purposes : It’s a way for me to keep some memories here, and it will also allow people to know better who I am, though I’m not very keen on speaking about myself, but you should prepare for a veeeeeeery long post :)
Ok so let’s start from the very start. I had my first computer in 1996, and at that time I was 11 years old. It had Windows 95 and we didn’t have access to the internet, so no chance for me to discover anything else than DOS games like street racer or some pinball games and such. But the turn was in 1999, when my brother and I went living with my father. I just got to a high school called “Collège Jean-Jacques Waltz” and this is where things start to be interesting. 2 days a week, I went to a club at noon called “Club Internet”. I remember that room pretty well, at that time we had celeron 333 in the machines, 15” displays and we could discover what we could do with computers. No internet, the club’s name is quite misleading, but we could do music on dance eJay 2, making wonderful wallpapers with terragen, and making our first webpage with staroffice. Too bad I lost my floppy where I put these precious memories :/
It was our physics teacher that animated the club, Philippe Richter, a nice guy that allowed me to discover free software. Once in a class, I asked him what was that nice screensaver running on the computer we had in the class next to the internet club, and where to get this. Actually, the computer was not running windows, it was running…
BeOS ! hehe yes the first alternative to windows I saw was not linux :)
At that time, cd burners were starting to get common, so he burned a collection of free softwares on a cd and gave it to me, and I owe him a lot for this. I’m feeling really lucky to have had him as a teacher, and I think education has a great role to play in free software, tell kids that there isn’t only one way to do it.
The next year, we moved to another region with my father, and as I didn’t get on well at all with my stepmother, I spent as much time as I could in high school at the CDI (that’s more or less like a library). The guy who was in charge of it was running Linux too and that’s where I really discovered it. Once, I bought a magazine called planete-linux and it included the first linux distribution I tried, Mandrake 7.2 :)
It was fun to launch it and discover kde. As I helped my father building the 2nd floor of the house where we lived, I got a 10 GB hard drive that eventually allowed me to install it aside windows 98 on my 166 MMX computer :)
As we didn’t have internet apart from a slow 56K connection that was quite expensive depending on how much time we spent on it (free) I could not download additional packages, but free software magazines I bought with my pocket money allowed me to get them because they were often providing a bunch of various softwares !
But… It was a bit frustrating. There were source tarballs, but I could rarely get them running cause I didn’t even know what to do apart from
./configure make make install
Of course, I didn’t catch the issues, and I barely knew what dependencies were, and I couldn’t even search for help at that time ! This is quite ironic now that I’m into the packaging world, you could say it took me almost 10 years to figure it out :D (though that’s not exactly the truth). At that time, I also started developing a website for my father which had a little company of train models. I learned some bits of php, added to what I knew of html, css and image editing.
Later on, I could get updates from that guy from the library, and could get mandrake 8.0, 8.1 et cætera.
At that time I was just a newbie, and didn’t try to see what was under the hood, it was just an alternative, free of charge, running well and stable, and my computer wasn’t just fast enough to run games like Max Payne :)
When we moved again with my father, I could upgrade my machine, and I discovered other languages, I used to program games with QBasic (under windows) like those I programmed with my pocket calculator.
When I got my A-levels, I got into a preparation school for 2 years and that took me off free software for some time, but after that, during summer 2005, we first got a DSL connection, and that’s when I could start contributing to the free software world :))) As I had no advanced knowledge of the system, I started translating and proof-reading french translations, that was a bit tedious, as I was used to translate full sentences with a completely different lexical field and that was sometimes a bit hard to figure out what it was all about in package descriptions.
And then I entered a business school in bordeaux and I didn’t manage to give me spare time to contribute, though I was still using mandriva, I even tested compiz when it was on alpha stage :) Feeling business wasn’t my cup of tea, I decided to give up, perhaps the hardest decision I had to take up till now (business schools is quite an investment, and the ROI was just uncertain if I did !) but still that’s where I took the bull (or the gnu) by the horns and spent all my time acquiring some knowledges about programming languages, the system, and answering people on the french forum, and that’s also when I began to go on IRC on a regular basis.
The same year, with some friends at the business school and a friend at the ENSEIRB, I organized an install party where I first met friends on the french forum, while I was working half-time. That was a great moment, I tried to show the installation as a conference, so that it would give time to make other presentations while people’s computers were installing stuff. Thanks to this and some of these people, I managed to find a job and I still tried to contribute, learning how to make RPMs. And last year, after sending patches or packages here and there, I got my contributor account.
All in all, the learning process spans over a large period of time with ons and offs, but from another point of view it was quite quick.
But what made me most improve is the people I’ve met. Every time I saw one of these people, it gave me a boost, the energy I needed to cross the next step. That’s the most precious thing we have in the mandriva community: people rarely said me to RTFM, this would have made me slow down, and I can assure you I read many docs and am still doing (that’s obvious you have to do that). Once you have the motivation, go ahead.
Now, I’m really happy to have been able to help someone else being a contributor, I can feel his motivation, that’s really awesome, and I think this is the best thing I could do to thank the people who did it for me.
Well, I guess I couldn’t tell this in 30 seconds, I’m a bit too talkative :)
awesome: Awesome RPMS and organizational changes
I’m sorry I’m a bit late but awesome 3.4.2 RPMs are available in the files section !
At the moment only i586 RPMs are there, I’ll put x86_64 RPMs once I’m home, stay tuned :)
I’m also proud to announce that I’ve been able to get awesome on the gdium for the first time \o/
Not everything works though. For some reason I cannot get rid of lxpanel because then I get no input from the keyboard and mouse, I don’t really know what’s going on there. Also, the modkey sends you back on the tty, that behaviour is also there without awesome, but I couldn’t fix it yet. What’s more, I need to update some other package, because atm it’s only awesome 3.2.1.
You may know download awesome rpms in the files section. I’ll clean the repo in the next days, it’s not really suited for binary files, but I just discovered a nice feature of redmine that allows you to make subsections in the files section. That also means you’ll be able to clone my config without having to download unuseful things :)
On the other hand, I’ll put more dotfiles in this repo, I just need to clean it before.
I just finish this announce with a screenshot
I’ve just discovered a nice patch for mutt that allows you to set up different colours for the different parts of the index, I think the result is pretty nice :) It’s been a bit of work to adapt it because other patches applied to mutt in mandriva caused it not to be applied properly.
I’ve also made a custom theme for irssi so that its appearance is consistent with my theme, and you can also see ncmpcpp running, it’s a nice mpd client I’ve imported not so long ago in mandriva.
Cheers.
awesome: Awesome 3.4.1 rpms and some other stuff
These rpms are now working fine on both my desktop (x86_64) and laptop (i586) but as usual, please let me know if you encounter some difficulties with these.
I've also changed some things in my config
Now there's a specific branch for my desktop config, as I don't need some of the widget I usually use on my laptop.
I'm also very pleased to say that I got my patch accepted by anrxc for the scrolling helper function in vicious. You can now use it for your mpd or mbox widget for instance :)
as you can see I also added my kde4 colorscheme, and I'll probably add some more dotfiles on this repo.
Cheers :)
home-server: My new toy
you might have noticed (or not) that a new section appeared on this website, but I didn't take time to write about it up till now.
Setting up a home server has always been in my head for the past 2 years, , though I didn't do much about this up till now.
This sets up the path to many experiments, sometimes reaching the limits of what's achievable with it.
Let's first describe what the machine look like. Well for now, it looks like this :
(yeah not quite what you were expecting huh? ^^)
and this :
This is a shuttle case I found for just a dozen of euros. It's a flex-atx case so I still got some things to do to get everything in its place. As you can see I had to cut the back panel to have the mainboard ports reachable. I still need to adapt things, the power supply is a micro-atx one, but my case takes atx PSU so I'll need to add something to attach it. Now to the core components :
this is a point of view mainboard with an atom 330 and an nvidia ION for the graphic part (who cares about graphics on a server?), and you can also see an OCZ Agility SSD drive. The point of choosing them is that the server will be up 24/7 so I chose some low-consumption components.
And this gives birth to sanbi :-)
Second part : Core software¶
As usual, I run mandriva on it, and to make things funnier I run cooker on it.
It runs pretty nice so far, but nothing special runs on it yet... except one thing : xen.
It may sound crazy to run a virtualization software on this kind of machine, we'll see how it evolves in the next news.
For now, my dom0 runs fine, I had it set up pretty quickly, but concerning my first domU things were a lot more tricky for me !
With the help of erwan and guillaume I could troubleshoot an annoying kernel issue, and now we have non-lzma kernels for kernel-server in cooker that's good news, thanks herton ! I also misconfigured some things, and decided to forget about libvirt to set up vlans, I'll come back to this later.
I'll give some tips about this in another post, because I think one shouldn't have to read all my blablabla to get these, that's all for now :)
Also available in: Atom