Thursday, January 01, 2009


So... one of the big issues I had with upgrading to Vista64 is that a lot of my ( really, REALLY ) old tools stopped working. Now most I can actually do without, but theres one that I've actually been running under DOSBOX to keep. DO.EXE is a simple programmers calculator that I wrote back in the Shadow of the Beast days and does proper programmer calculations. That is it deals with HEX and BINARY as you'd expect, but also does AND, OR, XOR, NOT, Shifts and all the rest of it. In fact, I use it a lot just to convert numbers from BINARY to HEX since C/C++/C# doesn't take binary (its a crime I tells ya!). The old program was written in Turbo Pascal 7 and was very 16bit, and while I had the source there was no way I was gonna "update it".

Well, every since I started my debugger in C#, I had a brand new evaluator doing exactly the same thing, but in a processor (and machine!) nutral langauge! So I've finally pull out my logic prob, and blasted its little binary brains all over the back wall and updated it. Now, I know theres a million similar little programs out there, but I like the command line one, and I like that it takes the same format as C/C++/C# and even Java, and since I've always got a command line open, its ideal. CALC (and others like it) have just never cut it for me.

Anyway... I thought I'd be nice and release this into the wild and let others play with it. Its not hugely tested (so feel free to let me know any issues) but its an invaluable tool. Even simple things like getting bit patterns into HEX is a simple case of just typing it in.

Anyway...enough drivel...You can get it HERE. Shove it into your path somewhere then just type "do" on the command line for options. If theres any doubt in an expression, use brackets. I've not listed any expression order because it's different from all other compilers and that forces you to use brackets more to make sure the answers right. If theres anything else you think folk would like added, feel free to suggest it.

I hope some of you get some use out of it. It's the single most used tool I've ever written - period!


Anonymous said...

Nice homebrew utility. Just meat and no useless water. Maybe it will become handy for me.

But why it takes up few seconds before output result? This is bit annoying.

Mike said...

doesn't this end.. could be .NET loading up on your machine I guess. What speed PC are you using?

And is this the 1st time only? or everytime? (1st time is due to disk caching...)

Anonymous said...

Execution time seems to be exact everytime i do any operation. Somewhere near one second, i think. About speed i'm using AMD Athlon 64 x2 1.7 Ghz

Mike said...

MMmm... very odd. Just make sure you have the latest .NET installed (I'll assume your not using mono just now), and aside from that I don't see why it would take that long each time.

First time here, theres a small delay (<1sec). But after that it's instant.

Not sure what to suggest really... very odd. You could pre-compile it into the GAK I suspose... (You'd have to look that up on the net)

Anonymous said...

Anyway utility is still can be used just fine. Thank you.

KungFuFurby said...

Did you at least keep your old utilities?

Mike said...

Yeah, I've still got all my old utils. But they are all 16bit, which cause me no end of problems these days..

Iapetus said...

It seem to have no problems under ubuntu 64 bit

Thank you