Windows Server 2008

April 15th, 2008 No Comments

Windows Server 2008This is what Vista should have been.

Granted my experience with Vista was limited to a notebook which ran it for a few weeks before re-installing with server 2003. Over the years working with internet properties served on Microsoft platforms I’ve always had the best luck running the same operating system on my workstation as is running in production. You learn the quirks, which helps you design and troubleshoot, and you’re also eliminating differences between your development environment and your production environment, which helps smooth out the surprises that pop up during releases.

So I more or less have gone from windows server 2003 to windows server 2008 on my development workstation. I have to say I love everything about it so far.

Read the rest of this entry »

Another topic which is near and dear to my heart is database access technology. Linq for SQL for example is very interesting, almost too interesting. :) One of the problems is that it can be used as an argument against using the ActiveRecord or NHibernate libraries you may already be taking advantage of in your Castle Project based solutions.

So I was delighted to see some posts relating to this topic from Ayende Rahien and Ken Egozi. Based on their excellent work it was simple to construct a Castle.ActiveRecord.Linq library which allowed you to build Linq expressions against a set of ActiveRecord classes as easily as you can build them against a set of Sql DataContext classes.

And all due respect to Microsoft, the designer of their data context still leaves a little to be desired as far as reducing the effort it takes to make tables based on fairly standard assumptions. Yes, it is graphical, but in a basic primary-key one-to-many relationship I was still left manually adding and configuring all of the properties of the columns. And still manually selecting which columns are involved on either side of the relationship.

They’re making great strides but the convention-over-configuration philosophy needs to sink in a little deeper.

And I do agree with Ayende’s when he said, “Of course, I still think that who ever designed Linq was mad.” One of the things that bothers me the most is how it could lead you down a path that returns to the days where you had raw SQL statements distributed throughout your software.

But it is cool.

If you create software and need to perform durable processing of long-running activities, one of the things you can use is the Workflow Foundation libraries from Microsoft.

And if you’re using Castle Project you might want to take a look at the workflow integration facility. It’s recently had a demo website added to the solution, and documentation has been built up on the Castle Project wiki.

Putting it together was a very gratifying experience. Hopefully there are some people out in the world that will find such a thing useful. :)

Latest news from the iPod (love it by the way) while watching comedy central (Brian Posehn).

So on the electronics front that’s going well. The ADC got wires up a treat - ended up using the builtin pwm on the rabbit to drive the clk pin and used the 8 port D pins to read in a byte at once. Numbers came out - written to stdout once a second - but it’s made it pretty clear the actual integration will need to be on wire wrapped perfboard. It’s too easy to jar a wire loose and too much hassle to figure out where to stick it when that happens.

Sooooo… Ah! Also contributed a logger implementation to castle project which directs output to the system.diagnostics.tracesource. So that’s nice to have built in when the next bits hit the streets.

Going to the Dells this weekend.

Finally got started doing some real work on the electronics project I’m taking part of with my friend Kevin. A number of parts were picked up today at ABC Electronics and a few a/d converter chips were picked up at AEI Electronics. I have to say AEI/Acme isn’t what it used to be when it was on Washington… The wall of IC chips was nowhere to be seen - it’s become more of a high-end home audio gear shop or something.

In any case! First thing first was wiring up the rabbit so it can be worked on. That meant soldering a 50 pin header on the development board in the array of holes provided. This is essentially a direct connection to all of the lines coming out of the rabbitcore daughter board itself.

Then I was looking at the main prototyping area. A lot of what I’m going to be doing a very work-in-progress and I didn’t want to commit to a particular chipset yet, so I decided to leave the developer board and jump onto a breadboard.

Rabbit project

The breadboard had a convenient locking edge normally used to connect multiple boards together. In this case I used it as a “stand” for the rabbit development board.

Next is the issue of getting lines down to the board. I have some wire-wrapping sockets used to prototype on perf-board, so I stuck one in from the bottom up. I was originally thinking of doing point to point wiring of lines as I needed them, but it occurred to me it would be more organized and useful in the long term to wire the lines from the header to the socket in a one-for-one pattern.

Wire wrapping

Ain’t that pretty? This way the silkscreen printing that labels the rabbit lines on the header both sides of the board can be used when grabbing the same lines from the socket.

So on the “bottom” of the dev board there’s a socket which is the right size to jam standard gauge solid wire to drop connections down to the breadboard.

Breadboard

If look at the large size on this one you’ll see this socket has brought forward PA0-PA7 and PB0-PB7. Inside the micro those are port A and B you can read/write as entire bytes. To test the work so far I’ve put some LEDs and flashed a program which wrote different byte values to port A, which came through just great once I realized I had the LEDs in backwards. (Sort of rusty :).)

The chip you see punched down there is the analog to digital converter. That’s what all those pins are going to be needed for because it’s a monster for i/o lines - it needs 4 lines to select input and 8 lines to read data back, and handful of others to latch, clock, and signal. Bit of a pain really - we’ll probably switch to a serial ADC at some point - but this one has some advantages right now. It’s easy to work with because it’s the old-school 10 pins per inch, it’s got 16 analog lines in which is huge, and it was a part the store had on hand.

So yeah. Hook that bad boy up next.

New toy in the mail

March 22nd, 2008 2 Comments

rabbitcore 4400WYay! A development kit for the rabbitcore microprocessor board showed up today! Usb connection to interactive debugger and editor. Tcp wifi stack. All out-of-the-box with a prototyping board. The thing is the size of a credit card (1.84” × 2.85” × 0.50”)  and runs on 3.3v. Amazing what people out there in the world are accomplishing.

I mentioned a little earlier I was going to be contributing to the castle project. That’s done now - it’s a facility which can be added to the Inversion of Control Container to integrate the Workflow Foundation into your castle based application. I know it’s sort of a niche need. Just like when you’re developing rails and mvc apps you should always go for the least code possible to implement a feature. (But no less.)

However there may be times where you’re doing significant after-page processing, or when you’re interacting with a long-running living workflow. In those cases the various calls into the web app are touching on an instance of a complex activity to see it’s progress or status, provide additional information as you go, or have different people of different roles moving things along.

The Workflow Foundation is one of the ways you can skin that cat. Depending on the specifics of the situation (and how you use it) WF can be a pretty attractive option. Of course something like using active record to manage activity state relationally is also perfectly fine. As always though it’s something you want to take a look to see if it makes sense or not for your use case.

TDDThis is a post about what by now is a very old subject. At the place where I work test driven development was first introduced by some colleagues of mine who were also some of the first advocates at the office of the scrum methodologies. Doug Swisher and John Murphy if memory serves, though I apologize in advance if that’s not correct.

I mention this now because I was reminded again about how it has permeated the development culture. Microsoft has also brought many of these practices in house in different areas and it shows. For example they’re working with a guy making Moonlight, and open source implementation of Silverlight for Linux, by providing documentation and the code for their full unit test suite. The MVC demo from Scott Hanselman also demonstrated unit testing and advocated some practices such as using a mock library. If you catch his presentation online at five minutes into it he’s showing the new MVC project template which includes a test library option selected by default, as well as an “I suck” option (his words) to omit any unit test library in your new solution.

He’s funny. Ah! I see he’s looking into various inversion of control containers. That’s a cool topic, but not what I’m talking about at the moment.

TDD is one of those things that’s a good habit, and one to constantly strive to reinforce, but one that’s also very easy to abandon when your project enters the grind to the finish line.

It’s something I’m thinking about because I’ve also been working on a small contribution to the open source castle project.  I’m a huge fan of that group’s work and I’d like to give a little something back. But since it’s going out to  that community I want the code to make a good impression for me - so I’ve been especially careful trying to follow conventions including providing a nunit lib.

I’ll post something more about that once it’s committed. How exciting.

Everything’s back to normal again finally. I’m not a big travel fan.

Here’s a simply awful picture from a blackberry of Ballmer from where I was sitting.

Ballmer

He’s really energetic. It was a great interview.

Final session of the final day coming up. Definite signs of fatigue showing in the crowd, and already not looking forward to the taxi airport dash coming up.

That said, the content is still compelling and interesting today as it was yesterday. Loved the chance to talk to some of the engineers building the things I use to build things. Met interesting people during the breaks and at the events in the evenings.

The possibilities stretching outwards are endless and exciting, as always, and seeing the collection of vision and potential from the presenters and attendees is all very energizing. It’s a shame there are only so many hours in the day and only so many things you can accomplish. I think I’ll have to give up on sleep for a while to explore the things I’ve seen the past three days. :)

As always no time for details on the road,  but I believe you can expect the posts to come to be more web-dev for a while.

Or in Ballmer’s words, Web developers! Web developers! Web Developers!