Writing Network Drivers in C#

Somebody had to do it. Maximilian Stadlmeier did:

User space network drivers on Linux are often used in production environments to improve the performance of network-heavy applications. However, their inner workings are not clear to most
programmers who use them. ixy aims to change this by providing a small educational user space network driver, which is gives a good overview of how these drivers work, using only 1000 lines of C code.
While the language C is a good common denominator, which many developers are familiar with, its syntax is often much more dicult to read than that of more modern languages and makes the driver seem more complex than it actually is.

For this thesis I created a C# version of ixy, named ixy.cs, which utilizes the more modern syntax and additional safety of the C# programming language in order to make user space network driver development even more accessible. The viability of C# for driver programming will be analyzed and its advantages and disadvantages will be discussed.

The actual implementation (with other programming languages as well) can be found here.

Apparently it’s not as slow as you might think:

I/O Is Faster Than the CPU

I/O is getting faster in servers that have fast programmable NICs and non-volatile main memory operating close to the speed of DRAM, but single-threaded CPU speeds have stagnated. Applications cannot take advantage of modern hardware capabilities when using interfaces built around abstractions that assume I/O to be slow. We therefore propose a structure for an OS called parakernel, which eliminates most OS abstractions and provides interfaces for applications to leverage the full potential of the underlying hardware. The parakernel facilitates application-level parallelism by securely partitioning the resources and multiplexing only those resources that are not partitioned.


serve live interactive Jupyter notebooks

The Jupyter Notebook is an open-source web application that allows you to create and share documents that contain live code, equations, visualizations and narrative text. Uses include: data cleaning and transformation, numerical simulation, statistical modeling, data visualization, machine learning, and much more.


Voila serves live Jupyter notebook including Jupyter interactive widgets.

Unlike the usual HTML-converted notebooks, each user connecting to the Voila tornado application gets a dedicated Jupyter kernel which can execute the callbacks to changes in Jupyter interactive widgets.


Earth, Moon, Spaceship.

As you might know humans are going to go “back to the moon“. At least when you ask a certain eCommerce mogul.

We have been there already. 40+ years ago. And since then we have unlearnt how to do it.

Just to give an impression of what we as humans where capable to achieve 40 years ago:

Moon (below), Apollo 16 Command Module (left), Earth (right)

There’s a whole collection of these photos freely available for further digging. Go there and spend a day!

Imagine: Humans flew there and back. With 60s tech. What can we do now when we want it?

Of course. The important bit is not really flying there and back. The most important thing for me is perspective.

Look at that small blue-white marble. We should reset our perspectives regularly.

Digital Daily Routine as an Experiment – “Digitaler Alltag als Experiment”

Last week we were approached by Prof. Dr. Nicole Zillien from Justus-Liebig-University in Gießen/Germany. She explained to us that she currently is working on a book.

In this book an empirical analysis is carried out on “quantified-self” approaches to real life problems.

With the lot of information and data we had posted on our personal website(s) like this blog and the “loosing weight” webpage apparently we qualified for being mentioned. We were asked if it would be okay to be named in the book or if we wanted to be pseudonymized.

Since everything we have posted online and which is publicly accessible right now can and should be quoted we were happy to give a go-ahead. We’re publishing things because we want it to spur further thoughts.

It will be out at the end of 2019 / beginning of 2020. As soon as it is out we hope to have a review copy to talk about it in this blog once again.

We do not know what exactly is being written and linked to us – we might as well end up as the worst example of all time. But well, then there’s something to learn in that as well.

a scientific paper a day

I am long-time subscriber to a service that is delivering a curated choice of scientific papers to your inbox every morning.

And even better: On top of the choice and link of the paper you also get a great summary with additional links and hints on the topic.

The Morning Paper: a short summary every weekday of an important, influential, topical or otherwise interesting paper in the field of computer science.


Depending on your specific interests the papers chosen will give you deep insights into certain topics. Recently a lot of AI related topics show up there.

The papers are delivered by eMail, by RSS feed of by just reading the blog.

active noise cancellation does not suck on your eardrums

If you ever traveled on a train or plane with good active noise cancellation headphones you might agree how much more pleasant the trip was with much less noise reaching your ears.

When I tried active noise cancellation for the first time I had that weird sensation as if the pressure around suddenly changed. Like being in a very fast elevator or going for a quick dive. It felt weird but luckily it went away and the aww of joy replaced it. Quietness. Bliss.

Now there seem to be people for whom that feeling won’t go away. They get headaches and cannot stand the feeling when using active noise cancellation.

I’ve never had any explanation to this phenomena – until now. I ran across an article on SoundStage describing that in fact the feeling is not caused by actual changes of pressure but…

According to the engineer, eardrum suck, while it feels like a quick change in pressure, is psychosomatic. “There’s no actual pressure change. It’s caused by a disruption in the balance of sound you’re used to hearing,” he explained. 

eardrum suck – the mystery solved

Aha! The brain gets confused by signals reaching your ears that naturally would not exists. Those signals make no sense so the brain tries to make sense of it. And voilá something is sucking your ear drum!

“making your home smarter”, use case #11 – money money money

The Internet of Things might as well become your Internet of Money. Some feel the future to be with blockchain related things like BitCoin or Ethereum and they might be right. So long there’s also this huge field of personal finances that impacts our lives allday everyday.

And if you get to think about it money has a lot of touch points throughout all situations of our lifes and so it also impacts the smart home.

Lots of sources of information can be accessed today and can help to stay on top of the things going on as well as make concious decisions and plans for the future. To a large extend the information is even available in realtime.

– cost tracking and reporting
– alerting and goal setting
– consumption and resource management
– like fuel oil (get alerted on price changes, …)
– stock monitoring alerting
– and more advanced even automated trading
– bank account monitoring, in- and outbound transactions
– expectations and planning
– budgetting

After all this is about getting away from lock-in applications and freeing your personal financial data and have a all-over dashboard of transactions, plans and status.

“make your home smarter”, use case #7 – hear that doorbell ringing!

We love music. We love it playing loud across the house. And when we did that in the past we missed some things happening around.

Like that delivery guy ringing the front doorbell and us missing an important delivery.

This happened a lot. UNTIL we retrofitted a little PCB to our doorbell circuit to make the house aware of ringing doorbells.

Now everytime the doorbell rings a couple of things can take place.

– push notifications to all devices, screens, watches – that wakes you up even while doing workouts
– pause all audio and video playback in the house
– take a camera shot of who is in front of the door pushing the doorbell

And: It’s easy to wire up things whatever those may be in the future.

How many space missions are exploring our solar system right now?

The number is 27!

CC-BY-SA Olaf Frohn

Right now there are 27 different missions ongoing to explore our solar system. A high number for something that is not part of our daily news cycle. Those missions currently concentrate on the sun, mars, mercury, venus, the earth moon and some asteriods.

Source: http://www.raumfahrer.net/news/raumfahrt/01052013213936.shtml

A lot of Whisky videos – and a tutorial how to cut videos on the command line

For just shy of 2 years I am a fan of whisky. After I got the hang of the processes, tastes and smells around this spirit I started collecting them – collecting to drink them eventually.

Now there are a number of shops you can buy good quality whisky from anywhere in the world. One of which happens to be located in germany. This shop is not only offering a huge choice but also a cross-sellers dream: tasting and explanation videos beneath many of the whiskys in which a very talented Mr. Horst Lüning tastes and explains all things whisky.

Now this shop hosts all videos on YouTube. Since I am a big fan of podcasting and internet based entertainment it’s a great thing that because if my little tool called “YouTubeFeast” all new episodes and tasting videos get downloaded automatically. Till today this way I’ve got well over 650 whisky tasting and explanation videos downloaded.

Bildschirmfoto 2013-03-01 um 20.46.32

As a matter of fact this is a really entertaining and educating series I even would pay to get access to. But that aside every video which got automatically downloaded usually looks like this (german audio):

As you can see there’s a short intro (8 seconds) and an outro (29 seconds) which every single video starts and ends with. Under normal circumstances there are two occasions when I have those videos played.

  1. When I want to look for a particular whisky and get an overview of how it’s going to be like.
  2. For over 12 years I happen to have a “nights playlist” – a playlist of things that are played back during the night – every night. For this it’s important that it’s mainly speech, very normalized audio and of course it needs to be interesting.

So for the second reason it’s important that there are not too many audio bumps and breaks. Unfortunately as much as I like the intro and outro music it’s actually very bass heavy and as such sleep interrupting sometimes… So just like when a good newmake spirit is distilled the start and end run need to be separated by the heart that makes up the spirit.

Every 4-6 months I take all newly added videos and cut them down and add them to the nights playlist folders. The process is like this:

  1. Rename them: Remove the following things from the filenames
    “Whiskey Verkostung – “, “Whiskey Likör Verkostung “, “Whiskygläser “, “Whisky-Verkostung – “, “Whisky Vorstellung “, “Whisky Verkostung “, “Whisky Verkosten “, “Whisky Tasting – “, “Whisky Tasting “, “Whisky Likör Verkostung “, “Whiskey-Verkostung – “, “Whiskey Verkostung “, “Whiskey Tasting – “, “- ”

    To rename the files I am usually using the freeware tool Rename Master – it’s awesome!

  2. Cut the intro away.
    This best done with a simple ffmpeg command:

    ffmpeg -i $inputfile -ss 00:00:08.0 -acodec copy -vcodec copy $output

  3. Cut the outro away.
    Using a little shell script it’s fairly easy to first get the full length of each video file and then using another tool to substract 29 seconds from each length and cut the heart out until that length is reached.

    To get the length the following short line is doing a great job:

    ffmpeg -i “$1” 2>&1 |grep Duration | cut -d ‘ ‘ -f 4 | sed s/,//

    In order to then cut the video before the outro starts it basically is a another call to ffmpeg:

    ffmpeg -i $infile -t $calculatedlength -acodec copy -vcodec copy $output

That way you get just the tasting videos without intro and outro – ready to be enjoyed. For the end of this article I want to stress the fact how awesome I think those whisky videos from Mr. Lüning are. It’s awesome to watch and learn. I hope that those videos will be available for more years to come! Cheers!

Source 1: http://www.joejoesoft.com/vcms/108/
Source 2: http://www.whisky.de

der letzte Flug des Space Shuttle Endeavour

Am kommenden Freitag soll das Space Shuttle Endeavour zum letzen Mal und ein Space Shuttle zum vorletzten Mal abheben. Da will man dabei sein :-)

Ich habe glücklicherweise gerade die Herren (und Damen?) von SpaceLiveCast entdeckt. Offenbar machen die schon eine ganze Weile Livestreams zu den verschiedenen Raumfahrt-Events.

P.S.: Wenn ich einen Wunsch frei hätte, wäre das, dass die Seite einen Video Podcast Feed anbietet….(wird Hilfe benötigt?)

Source 1: http://spacelivecast.de/
Source 2: http://www.raumfahrer.net
Source 3: http://spacelivecast.de/2011/04/29-04-ab-1900-uhr-sts-134-letzter-endeavour-flug/

winter 2011 hacking project: Home Automation

In the last 10+ years I was fiddling with different home automation concepts. Mostly without broad use cases because at that time no one seemed to be interested in having sensors and actors like crazy at home. In fact not that many people seem to care these days.

Having more and more hardware and software around us creates the use cases for a broader audience people like me have for 10+ years. Mainstream is a bitch for nerds Smiley

That said I found a nice plastic box I want to use in a winter project. This plastic box is called “EzControl XS1”. It comes with several visible and “invisible” interfaces.

The visible and obvious ones are: power, 100 mbit ethernet, sd card slot. So it takes some power and does something on the network. The not so obvious and therefore “invisible” interfaces are the most interesting ones: the EzControl XS1 comes with the ability to send and receive on 433 Mhz and 868 Mhz.


Yes that are the ranges used by switchable and dimable power sockets, temperature sensor and AMR. The EzControl XS1 is not that cheap (coming at 189 Euros for the base version and additional 65 Euros per upgrade option). I do not own one yet so it’s the plan to acquire at least one and start of with dimable power sockets and add more sensors and actors on the way

One great feature of the EzControl XS1 is the embedded WebServer with which the users application (the one I want to write) can interact using a HTTP/JSON Protocol. Oh dear: Sensor data and Actor control using JSON. How great is that!

There is some example code available (even a proprietary iPad/iPhone client) but since I want to have some custom features I do not currently see to be available in software I am going to write a set of tools which will get and protocol sensor data and run scripts to controls actors. Oh it’ll be all available as open source (license not yet chosen).

P.S.: If some one from Rose+Herleth is reading this and wants to help – send me a test unit Smiley

Source 1: http://www.ezcontrol.de (in german though)
Source 2: http://en.wikipedia.org/wiki/Automatic_meter_reading
Source 3: http://www.ezcontrol.de/content/view/12/31/

Hail Eris! All Hail Discordia!


I was in desperate need for an DDate equivalent running on Windows. DDate is an unix implementaion of date accoridng to the erisian calendar described in the principia discordia.

I only found some C Implementations. And since it’s fun to do I ported the original Discordian Date C code to C#.

You can download the C# sourcecode, licensed under CC-BY-NC here.

I also created a web page which displays the current discordian date and offers you to convert any gregorian date into discordian date representation.

This page can be accesses here. You can call another page with parameters and you only will get the ddate output back:

for example: http://ddate.schrankmonster.de/DiscordianDate.aspx?year=2009&month=6&day=9

Source 1: http://ddate.schrankmonster.de/
Source 2: http://dropbox.schrankmonster.de/dropped/SharpDDateLib.zip