Wednesday, October 07, 2009

Alli


Alli is a new over-the-counter drug that binds to the fat in your diet and prevents the body from absorbing some of it, so that people can carry on stuffing themselves and still lose weight.

In a world where people starve to death it strikes me as almost obscene to market a drug that encourages the rich to eat too much and then shit fat...

Thursday, October 01, 2009

Even more gloom


You know, I wouldn't have thought it possible for today to be worse than yesterday, work-wise.

But it managed.

We have a reasonably large order for a new project, for which I have already designed the hardware, and so I just need to write enough of the software to be sure that the hardware works so we can safely order the PCB's, etc, for manufacture. Though actually I suspect that once started I'd actually write the whole thing so that we can provide an early sample for the customer to evaluate.

So, I duly set up the project and start to write code. Or at least I would, except that for some unknown reason the thrice-damned compiler for one of the processors involved (a Jennic RF device) has stopped working. Yes, the software has rotted. Or, to be more accurate, something I've installed (some other version of gcc, probably) since last time I used it (a few months ago) has messed with the path, or the environment, or whatever, and killed it.

Not that it gives a helpful message, you understand, no, the only indication is an essentially meaningless error from the make process, emitted from one or other of the (slightly incompatible) versions of the fucking make utility I have to have on this system. So once more, if I can work up the energy, I'm going to have to delve into makefile hell, find out what the bastard thing is moaning about, why it has changed, and what to do to fix it. And this, no doubt, will fuck with something else on the system and make that stop working with some obscure problem I will trip over later...

Oh, gods, how I detest relying on other people's development tools. I'd say most of 'em were designed by arseholes, but the truth is that most of 'em weren't designed at all and are just the product of generations of open-sore bodging.

So, what to do? There's something to be said for the idea of using virtual machines to isolate each and every piece of third party garbage out there, but that's a real pain in the arse for people like me who create systems which involve multiple pieces of hardware/software using different CPUs, languages and so on and so forth...

[sigh] I guess I'm going to have to spend some time studying the more arcane details of make utilities and makefiles so I can debug this mess. It's a study I've been putting this off for quite some time. Far too many makefiles are childishly overcomplicated and seemingly designed by immature programmers who admire complex solutions to simple problems - baroque stupidity for the terminally anally retarded.

Christ, I sometimes wonder what it is about so many programmers that makes them incapable of grasping the fact that simple solutions are to be prefererred to complex ones, but such wondering's clearly a waste of time. The answer is, as it so often is, merely stupidity.

Grump, snarl.

[later]

After a lot of farting about I sort of cured the makefile problem... What I don't understand is what brought it on. The cure was to replace a couple of absolute paths with relative paths.

Like this:

Before:
BASE_DIR = c:\foo\bah\sdk
After:
BASE_DIR = ..\..\foo\bah\sdk

Now, the thing I don't understand is what changed on the machine to stop the first version working. The paths haven't changed, the relative paths just refer to the same directories as the static paths did. The static path makefiles still work on other machines, they used to work on this one, FFS, and without anything changing now they just don't. There are times when I hate computers...

Morose-looking sheep


"Research by scientists at the Free University in Berlin has shown a link between depressed farmers and vets and the infectious Borna virus which makes cows, sheep and horses behave weirdly. One good method of cheering yourself up during a depressive bout can now be to search your memory for contact with morose-looking sheep and blame it on them".

Try as I might I can't remember close contact with any sheep, morose or otherwise... Though I have shouted "mint sauce!" at them in the distance on occasion, so I suppose it could be delayed payback.

Bastards.

Wednesday, September 30, 2009

More gloom...


Today follows the recent miserable trend with a problem being reported in something I wrote a couple of years ago, so once more I'm dragged off what I'm supposed to be working on and have to screw about setting up a different project, because my old tools don't run well under Vista (thanks Bill) I have to port various old sources into my new development tools, which means I have to update the new assembler to add support for a long-forgotten pseudo-op I added to work around an Atmel fiasco where a batch of their damned AVR processors failed to read constants from memory reliably when operated at anything more than room-temperature, then I had to chase a problem uncovered while I was adding that, then having sorted out the original problem I had to update the product website, add a new version of the product to various configuration tools and programmers...

It was well after 8pm before I left work and all of the day spent dealing with some problem I didn't even know existed yesterday.

And tomorrow, guess what - I've got to stop everything and start working on a different design which also needs to be done right now.

You can probably tell from the shitty writing style that I'm so tired I can't really think straight. Not having fun here...

Monday, September 28, 2009

Disappointment



I use this (slightly modified) Roger Dean wallpaper as a desktop background, well, a reduced brightness version of it at any rate. Yesterday James, my five year old son wandered in and noticed it...

"Dad! Can we go there when I grow up? I want to go there!"

"Sorry, James, it's just a picture. Someone drew it."

His face feel. "Awww" he said and started sniffling. It was as if I'd cancelled christmas... There's something heart-breaking about the disappointments suffered by children.

Later it struck me that (barring disasters) there's a good chance he will get to go there, or at least to places every bit as imaginary, through virtual reality.

Saturday, September 26, 2009

F1


Gah, he's driving like a pillock so I have acted to ensure Button wins this year drivers championship.

How? I hear you ask. Well, 'twas easy - I placed a bet on Barichello to win it... At the moment one of the web betting sites have a promotional deal where your first bet is essentially free, and the odds against him were something like 6 to 1, so taking a free punt on him seemed like a good deal to me. I'd like Button to win but if Barichello beats him I win £130 or so, which would go some way to moderating my indifference - disappointment, I meant.

Now, I just need someone to nobble Red Bull...

Friday, September 25, 2009

Scribblenauts


Scribblenauts is a game for the Nintendo DS and it's the first game in a long time that has impressed me. If you've got an NDS I strongly suggest you download the rom, play it and then buy the bloody thing, as I will be doing - they deserve it. It's superb.

What? Describe it? Well, basically it's a platform style game where you have to solve problems but the amazing feature is that you can write the name of just about any object you can think of into the game and have it appear.

The guys at work failed to fox it, they suggested "table" and it understands tables. They suggest "brick" and it understands bricks. I tried "osmium" expecting nothing, but it understands osmium. It knows it's dense. "Elephant" doesn't phase it, nor does "Bazooka"...

I was showing it to Sarah, on a level where there is a tree that needs to be cut down. "What would you suggest?" I asked her. "Axe" was the obvious response, so I write "axe" and one appears. I give it to the waiting lumberjack and lo, the tree was cut down. No great surprises there I hear you think.

"Suggest some other objects" I say - "Sunglasses" she replies. The game duly produced sunglasses, which the player's character then wears

"Go on, think of something awkward" I suggest. There is a pause.

"Ball gown" says Sarah. Ha! She's got it - it can't possibly... But it does. I write ball gown, and a ball gown appears. We give it to the lumberjack, who is definately not impressed and who then grumps mightily... clearly not a fan of Monty Python.

I then play about a bit. I write "atom bomb" and blow the entire level up. I write "time machine" and (glurk!) one appears and whisks me off into the past, where there are dinosaurs.

Ha! I think, and write "meteor"... One duly appears, and wipes out the dinosaurs...

At this point Psi phones and I wax lyrical at him. "Think of something!"

"Kumquat!" He says. Guess what? It knows about kumquats.

Later on I found there's a level where you have to shift a cow out of the road without harming it. I'd already found that "UFO" is recognised and gives you a flying saucer you can fly about in, so naturally... yes... you can hover over the cow and have the flying saucer pull it up. I like the way their minds work...

Thursday, September 24, 2009

Garbage


I've been finding it harder and harder to motivate myself of late and the reason, well, one reason anyway, is that I'm working on an upgrade to someone else's design and the original is such complete and utter garbage that every time I have to refer to it I want to throw the whole project in the bin and walk away.

It has a large software component - far larger than it needs to be - which appears to have been written by a beginner as their first ever software project. Unfortunately he wasn't a beginner and it wasn't his first project. Be that as it may, this piece of crap is, without doubt, the worst piece of programming I've seen in over thirty years. It is shockingly poor, a combination of just about every bad practice known to programming merged together in an orgy of sustained idiocy. None of it, and I mean none of it, shows any sign of competence whatsoever... Programmers will get an idea of what I mean when I say that the C source, all in one file, is about seven and a half thousand lines long, and that six and a half thousand lines of it is all in the main() routine. It's not that it needs to be, it's just that the author doesn't appear to grasp the idea of abstracting out common code into subroutines (whatever they're called these days)... Oh, he does know about them - he even has a couple. I'd tell you what they do, but then you'd have to kill yourselves in despair...

Oh, to hell with it. I'm depressed :(

Later: And as much as I hate it, I'm sure the bastard thing hates me even more. Wasted a lot of hours tonight trying (and failing) to figure out why I couldn't readback some ADC values, which it now appears is some sort of obscure board fault and not a problem in my FPGA design... That's the story of this project, I take one step forward and then several steps backwards with every session. Not one single fucking part of it has worked without a struggle. Every deadline has come and gone while I struggle with some obscure piece of stupidity and I'm heartily sick of it now.

[gloom]

Monday, September 21, 2009

Windoze


I must put on record that I was being unfair to Herve today.

I accused him of being the flying dutchman of the laptop world, forever doomed to spend his time running Windows 95 - but he quickly corrected me - he actually runs Windows 98 SE and is proud of it...

You know, I'm not entirely sure that using Windows 98, even the second editon, accurately portrays the dynamic, thrusting and forward-thinking aspects of Design Design as a high-technology design company. Bet he still uses lead in his solder...

[Furtively crem returns to the assembler source for an FPGA processor he's tweaking. It is clearly a variation on a Z80...]

Wallander


I've been watching the original Swedish "Wallander" TV series recently, having been a fan of the books for a while, and I was depressed to find out that the actress who played Linda Wallander (and played her well) killed herself a couple of years ago. Strange that I felt so bereft at the loss of someone I'd never have met or had any contact with whatsoever...



Tuesday, September 01, 2009

Halls of the Things in HD


There are some talented people in the world, and some of them are mad. One such is a guy called Andy Stewart who (completely of his own volition) has written a version of Halls of the Things in C# and released it on an unsuspecting world... It's so faithful to the orignal that I took it upon myself to appoint him the fourth evil lord in honour of this evil deed; I'm sure Neil and Martin would approve.



He has created a web-page for this allowing it to be downloaded : http://www.whatisblueandfurry.com/hott/halls08.html

A thing of beauty is a joy forever; but those bastards are dynamite...

[For some bizarre reason the comment option doesn't always appear on this posting. If you want to comment, click on the title and then it does. Weird...]

Friday, August 28, 2009

Just google it


Google makes life far too easy. A friend is getting reasonably good at some of the facebook games, so naturally I decide to wind them up by quietly posting slightly better scores. In the good olde days this would take skill - I'd have to figure out how to play the game... Hang on, [shudder], that's not what I meant - I meant I'd have to figure out how the game worked, where the score was stored, what form it was stored in, if there were any security checks and so on before hacking it to score whatever I wanted [phew]. This could involve several minutes of amusement...

In the really olde days you'd have to figure out their tape encoding schemes and fight off some cunning anti-piracy checks, but the days when programmers were that skilled are long gone; anti-piracy these days just means spelling your variables so badly that nobody else can figure out what the illiterate sod of a programmer meant, and it all happens by accident, not design.

But that's all moot, because now you don't hack anything, just google "bejewelled blitz cheat" and find the answer. Gah - where's the fun in that?

Pity I can't get it to score "xxx and a half", mind you. I suppose I could fake an accomplishment message... hmmm...

[later: A few days ago I found out that the wind-up worked... ]

Tuesday, August 04, 2009

Panes


I've just put the finishing touches to some demo code for an ARM-based operator interface panel we've designed, and it's sitting in front of me as I type with a few windows bouncing about at frame-rate in the foreground and a Mandelbrot being rendered in the background. Every now and then another view of the Mandelbrot drifts past in a stately fashion (frame-locked, of course) and if I touch the screen it pops up another window that follows the touch about under my finger, with a ghostly lattice of lines being drawn overlayed on the background to show the outlines of the various regions of the screen that are being rendered as the window position changes... It looks beautiful, as graphics that change at frame-rate usually do.

I'd include a picture, but a static photo really doesn't do it justice and I can't be bothered to work out how to include video at my time of life.

The hardware is a Cirrus ARM processor that has a fair number of peripherals on chip, including the LCD display driver. That single chip and a couple of SDRAMs, a FLASH and some glue is all that's involved, hardware-wise. The software - a complete graphical windows system and enough of an OS to run operator interface style applications - (in total about 12,000 lines of C) was all written from scratch by yours truly in about five weeks...

Since all of this is written in C and compiled with GCC (unusually for me there's not a line of assembler in there, aside from the device boot code) and it still runs fast enough on a 200MHz ARM to look bloody impressive I find myself wondering how the hell programmers manage to take hardware like this and make it appear as slow and crappy as all the ARM-based personal organisers out there look.

What the hell are they doing to slow them down?

It's amazing how bloody awful the demonstration code that Cirrus supply for their own device is, it makes the thing look like a CP/M machine struggling to write to a terminal.

This particular chip has blitter and line-drawing hardware that I haven't used, since I wanted the graphics code to be pretty generic. The demo code from Cirrus uses the blitter and still manages to run like a slug that has overdosed on valium. Gah...

The incompetence that's endemic in this industry depresses me, it really does :(

Monday, August 03, 2009

"Hey, are your feet wet too?"



Saw this image on t'web ( http://static.panoramio.com/photos/original/20677595.jpg ) and thought that there just has to be an amusing caption in there somewhere... Buggered if I can think of one, though for some reason I can't get the idea that one of the penguins is singing "I'm peeing in the river" to the tune of Peter Gabriel's "I'm feeding the rhythm" out of my head...


(Photo is by LichtenHansen http://www.panoramio.com/user/2512952)

Sunday, August 02, 2009

Mid wife crisis


There is an evil in the world and it targets middle aged men. I feel I owe it to others to warn of this insidious peril... They're small, they're sexy, they're hard to resist. You see one and you have to have it, the urge is overpowering, after all - what's the harm? Your wife/lover needn't find out. She won't suspect - with luck you'll get away with it. So you have one, but it's not enough. The thrill doesn't last and you come crashing down. Then you have to have another, and another, and soon you're spending all your money trying to maintain your addiction. You think you can control it, but it's an illusion, they're far too complicated.

I'm talking about radio controlled helicopters. Avoid them... One is never enough...

Thursday, July 30, 2009

Crotchless chastity belt


I was aimlessly Googling about today when I came across... No, let me rephrase that - when I encountered the phrase "crotchless chastity belt"...

Now is it me, or is someone seriously missing the point there? Or is someone getting the point when they shouldn't? Either way the phrase "crotchless chastity belt" has replaced "chocolate teapot" in my vocabulary...

It's over, or should that be IT is over?


I was working with a chip today, doesn't really matter what it was, when I realised that we are well and truly into the aftermath of the n'th industrial revolution. It's over, bar the shouting.

What shows this is the number of designs I now see that are fundamentally flawed, and flawed in ways that show the designers really don't know what they are doing. They get the basics wrong. I think the problem is that the leaders of the silicon revolution, or whatever fancy phrase you want to use to describe it, are now dying off and their hard-earned knowledge is being lost - the problem is that the good guys were all too busy doing it, whatever their particular "it" was, to write about how they did it, and they are now being replaced by people who have not learned from the ground up but rather were taught complicated subjects by those who weren't all that competent in the first place...

Up to the biotechnology people to take up the baton now, I guess.

Tuesday, July 28, 2009

Stress

Stress is when you









[That was as far as I got before I gave up]

Monday, July 20, 2009

Ruminations...


Someone asked me recently what aspect of my time in the games industry I remember most fondly. My knee-jerk answer to this sort of question is "Halls" but for a change I thought about it and there really is only one thing (aside from Halls) that still amuses me every time I come across it, and it is this couple of sentences that Psi and I wrote for the story line of Dr Strangefruit:



Strangefruit removed a dog-eared, loose-leaf notebook from an inside pocket and placed it reluctantly on the desk, as if parting with an art treasure of great value. Pratt reached over and picked it up, holding it by one corner, as one might retrieve a piece of used toilet-paper that had missed the bowl. It was not in keeping with Pratt's idea of documentation and did not appear to merit being on such an executive desk. "Might I ask what this is about ?" asked Pratt, who didn't want to have to read it to find out.



Well, there you go. More fun contained in a single paragraph than some of my complete games. We don't write 'em like that any more...

Tuesday, July 07, 2009

Ouch


So, today I'm working on a new industrial input card for our logger family. Lots of 0..20mA inputs and some switched outputs, usual sort of stuff.

For added interest it has two AVR processors. A Mega128 sitting down near ground doing most of the work (handling the comms, multplexing inputs, driving the ADC and so on) and a Mega8 sitting up near the supply positive rail watching the current drawn on the outputs and turning them off if the current exceeds preset limits. These two talk to each other through a level shifting serial link.

Doing it with two processors is both the cheapest and neatest solution to the problem, the alternative would be to have lots of level shifting hardware for the various outputs and current sensing lines, which would involve much more hardware and be less accurate with it.

But - there had to be a but - it does mean that I have to simultaneously develop software for two processors that are running at different grounds, and also one of them needs a software emulated serial port because the hardware ones are busy doing other comms jobs, hence there is some slightly awkward software and the programming requires isolated AVR programming/debugging interfaces. Well, I have those, so no problem.

Hah. The gods don't like cunning designs.

I blow the first Mega8 up when the bloody ground clip of a 'scope probe unclips itself and wanders across the PCB, managing to touch one of the AVR I/O pins. Normally this wouldn't be a problem, but it picks the AVR that has its ground up at +20V or so. It doesn't like having one of its pins dragged down to -20V (as it sees things) so bye-bye and off to silicon heaven it goes.

Much gallic muttering ensues as Herve replaces it.

A few hours later I'm busy working on the serial comms between the two processors when the 'scope probe slips out of my hand. It misses the board and I have a moment of relief until I realise it's heading for the exposed PCB of the isolated AVR programmer... It lands on it and there is a very slight, but clearly audible, click as the earthed shield of the probe makes contact with some component or other on the programmer.

Of course, it doesn't do this with the programmer that's sitting at ground, it picked the programmer that was connected to the positive rail and which was sitting with its ground at +20V or so, and that click signifies the end of that particular programmer. And, of course, the end of the bloody AVR it was connected to as well.

This happened at 10:30 pm, and at about 11:30 pm there was even more gallic muttering as Herve (dragged back into work) replaced the Mega8 again. This was accompanied by a fair bit of my own muttering as I repaired the AVR programmer.

About an hour and a half later the other AVR, which had been sitting down at ground and minding its own business, stopped talking to the debugger. After a bit of investigation it turned out that one of its I/O pins was damaged at some point in the preceeding fiasco and had quietly rotted.

Think I'll wait 'till tomorrow before I tell Herve he's got to replace the Mega128 now.

I'm starting to think the gods really don't like this design...