Twitch Mix #4

50 Min Indie Disco/Noise/Electro

Tracklisting

The Presets: This Boy’s in Love (Lifelike Remix)
Pryda: Rakfunk (Original Mix)
Alex Metric: Deadly on a Mission (Alex Metrix Remix)
The Presets: My People (D.I.M. Remix)
Bonsai Kat: Bla Bla (Original Mix)
Shirley Lites: Heat You Up (Melt You Down) (Gard’s 4lux Edit)
Parsa Vahid: Morning Sun (Original Mix)
Ali Wilson, Lee Osborne: Armageddon (Original Mix)
Boys Noize, Erol Alkan: Lemonade (Justin Robertson’s Deadstocks 33′s Remix)
Punks Jump Up: Get Down (Alex Gopher Remix)

Posted in Music | Leave a comment

How do I store long strings with Firebird, NHibernate and NHibernate.Mapping.Attributes?

Yes, I know, it’s the hot question of the moment which everyone is asking.

Anyway, I figured that someone else might want to know this, since Firebird is a supported database for NHibernate, and the embedded version is very handy.

This is what the declaration for a member called “Detail” should look like (I think you can omit the “Name” attribute if you want):

[Property(0, Type="StringClob")]
[Column(1, Name="Detail", SqlType = "BLOB SUB_TYPE 1")]
public virtual string Detail { get; set; }

So the SqlType bit is Firebird-specific, and I don’t think it was very obviously documented anywhere in the Firebird docs. It feels a bit nasty to write code like this because it means I’m locked in to one database backend FOREVER.

For a fun bonus rant, the NHibernate page seems to be down at the moment. You can say what you want about Java, but the open-source tools and community are so much richer for Java than they are for C#. In fact, I’d say that C# is at around the Java 1.2 level on this basis.

Posted in Uncategorized | Tagged , | Leave a comment

Twitch Mix #3

One Hour Eclectic Mix

Tracklisting

Metronomy: The Bay (2 Bears Mix)
Gossip: Standing In The Way Of Control (Tronik Youth Remix)
Dave Clarke: No One’s Driving (Chemical Brothers Remix)
DJ Sneak: You Can’t Hide From Your Bud
Fedde Le Grand: So Much Love (Original Club Mix)
Paolo Mojo: Wasted Youth (Original Mix)
Booka Shade: Scaramanga (Dusty Kid Remix)
Michael Calfan: Resurrection (Axwell’s Recut Club Version)
Sarah Vaughan: Fever (Adam Freeland Remix)
Fatboy Slim: Tweaker’s Delight
Faithless featuring Blancmange: Feel Me
Oliver Koletzki: Music From The Heart (Original Mix)
Felix da Housecat: What Does It Feel Like? (Röyksopp Return To The Sun Remix)
Crystal Castles featuring Robert Smith: Not In Love

Posted in Music | Leave a comment

Twitch Mix #2

How’s Your Evening So Far?

Indie Disco / Electro Mix (tracklisting below)

Tracklisting

Wink: How’s Your Evening So Far (Filtered Mix) [Intro]
Metronomy: The Look (Fred Falke Remix)
Chris Lake: Changes (Main Mix)
Felix da Housecat: Silver Screen Shower Scene (Chuckie & Silvio Ecomo Dirty Acid Remix)
Yeah Yeah Yeahs: Heads Will Roll (A-Trak Club Mix)
Basement Jaxx: Where’s Your Head At?
Röyksopp: The Girl And The Robot
DJ Tiësto & Ferry Corsten: Gouryella (Rawdirt Remix) [Outro]

Posted in Music | Leave a comment

Twitch Mix #1

The first in a series of my Twitch Mixes, 50 minutes of progressive house and trance, on my Novation Twitch with Serato Itch.

Some of these mixes are hosted on SoundCloud, but I’ve only got limited space on there, so the complete lot are hosted here.

Tracklisting

Nick Warren: Buenos Aires (Original Mix)
Way Out West: The Gift (Michael Woods Remix)
Tom Blench: Third Interval (WIP)
Simian Mobile Disco & Beth Ditto: Cruel Intentions (DJ Pierre Remix)
Adam Freeland: We Want Your Soul (Infusion Mix)
Jerome Isma-Ae / OT Quartet: Hold That Sucker Down (Instrumental)
Inner City: Big Fun (Simian Mobile Disco Remix)
Adonis: No Way Back
The Temper Trap: Sweet Disposition (Evil Nine Mix)

Posted in Music | Leave a comment

Richard Stallman’s Rider

Thanks to The Register, whose story linked to an email which details RMS’ rider and requirements for making speeches in tedious detail.

Honestly, this stuff makes “a bowl of blue M&Ms” look trivial. We learn that he doesn’t like dogs, can’t sleep if the temperature is higher than 22°C, and that “I like some wines…but I don’t remember the names of wines I have liked”.

Even if I thought this guy was the messiah of free software (I am an avid emacs user), I don’t think I would want to host such a fussy and childish person.

Posted in Uncategorized | Leave a comment

Small change: the economics of charging for trivial things

I got thinking about this subject because Fred Baker Cycles had the temerity to charge me 50p for the use of their bike pump.

This was definitely adding insult to injury as I was confronted with a flat tyre after having visited the dentist. No problem, I thought, I’ll just go to a local friendly bike shop and at least be able to ride the damn thing home.

Maybe I’m too sensitive to petty things, but charging 50p for this service (I grudgingly handed over my equilateral curve heptagon – I had no other choice) generated a huge amount of badwill (the opposite of goodwill) towards this shop.

Contrast this approach with Orange retail stores (disclaimer, I once worked for them), who will charge your mobile phone, gratis – you don’t even have to be a customer.

Maybe it’s something specific to bike shops. So many of them have a reputation for being rude and unhelpful, and if these Google reviews are anything to go by, this one is no different.

Posted in Uncategorized | 1 Comment

Emacs: how to search and replace newlines

I can’t remember where I learnt this, but I use it all the time and it’s not at all obvious.

When in the minibuffer (at the prompt for replace-string or replace-regexp, for example), enter C-q C-j for a newline (0x0D, NL).

Depending on the coding system for the buffer (DOS mode for example), you may also need to use C-q C-m for carriage return (0x0D, CR) – suddenly it makes sense where all those ^Ms come from!

Posted in Uncategorized | 3 Comments

C++: Mixing containers and inheritance

This is the sort of thing in C++ which catches me out as a recovering former Java programmer.

Amongst the very good advice I was given whilst learning C++ was:

  1. Use the STL containers
  2. Only use pointers when you really need to

The first point is sound advice, after all, why re-invent the wheel? There are plenty of useful containers like std::vector in the library.

The second point is about memory management. It’s much better to let scoping and destructors do the work for you, rather than keeping track of pointers and calling delete().

With this in mind, here’s a sample program:

#include <iostream>
#include <vector>

class Animal
{
public:
    virtual void hello();
};

class Dog : public Animal
{
public:
    virtual void hello();
};

void Animal::hello()
{
    std::cout << "<Generic Animal Noise>" << std::endl;
}

void Dog::hello()
{
    std::cout << "Woof" << std::endl;
}

int main()
{
    // store the object directly
    std::vector<Animal> animals;
    animals.push_back(Dog());
    animals[0].hello();

    // store the pointer
    std::vector<Animal*> animalPtrs;
    animalPtrs.push_back(new Dog);
    animalPtrs[0]->hello();
}

What’s it supposed to print? Well I thought it should print

Woof
Woof

but instead it prints

<Generic Animal Noise>
Woof

I was genuinely surprised by the result – the lesson here is to use pointers if you don’t want your class to lose its identity.

This was also discussed in this forum post and (in great detail) in “STL and OO Don’t Easily Mix”.

Update: Apparently this behaviour is called slicing. Well I really have learnt something today.

Posted in Uncategorized | Leave a comment

Fame at last!

Check out this review of Sacha’s Morbid Atrophy album Grist ‘n’ Grind (warning: contains Flash).

My favourite excerpt: “‘A Porter Too (Blench mix)’ is seriously an amazing piece of work”

Posted in Uncategorized | 2 Comments