Archive for December, 2008

Update to Store Locator Project

I had a real rookie JavaScript mistake in my Store Locator project that was causing some people some grief. I had no idea this project was actually being used by many people for real live stores and companies. That’s kind of cool (until it breaks).

Anyway, something changed (somewhere – probably the Google Maps API) and people had issues with the map showing up when it shouldn’t have. Oops.

Anyway, I just fixed it and posted a new release to CodePlex. Get it here.

Sometimes you just have to burn one

This is really old news to some blogger’s,but I’m posting it again because a lot of people I know are just starting off in the blogging space. 

If you have a blog you’re probably wondering how many people are reading it. You can get some decent statistics from your feed (RSS/ATOM, etc). However, most blog engines do not provide a way for you to get at the really good statistics of your blog.

For a lot of people your RSS feed is your interface into your blog. Personally, I NEVER go straight to a blog from typing in the URL. I use Google IG as a feed aggregator. There are tons of other tools for this, but I personally like Google IG. I set it to my home page and I can read stuff as I encounter it and I don’t have to open ANOTHER program to read WEB items.

Ok, so you already have an RSS feed. So what? Do you know how many people subscribe to it? Do you know what types of browsers they use? Do you know how many people you had 1 month ago? Probably not.

 

Would you like to know?

 

feedburner If so, then Feed Burner could be of some use.

Benefits of Feed Burner include:

  • Less bandwidth pull on your RSS feed. Hanselman (among many others) have stated that their RSS bandwidth is crazy huge. Moving it to Feed Burner can remove that bandwidth polling.
  • Statistics on how many subscribers you have to your feed.
  • If you move locations your feed stays the same. Just update the location of your blog in Feed Burner. This is especially useful if you are part of a community such as Blogspot and then decide to move your blog to your own domain or another community. You don’t  loose subscribers when you move (muy importante).
  • Ping Shot – Notifies feed reading services that your blog has been updated.
  • Email Subscriptions – Allow people to get updated via email when your blog is updated.
  • Stats… graphs, and pictures… :) as shown below ….
  • And a lot more ….

 

The best part is… its free.

 

So what’s the downfall?

Single point of failure. If Feed Burner goes down, your blog is down to readers. I think I’ve only see this happen ONCE in the years I’ve used it. It was only down for maybe an hour or so. This could have been scheduled, who knows.

 

Also, no, I did not get paid to write this … I actually like the service so much that I wanted to write about it.

 

 

Subscriber Reader Type Break Down

FeedBurner_without_Google2

 

Feed Dashboard – See what’s happening and when

image

New Dime Cast: Migrating from .asmx web services to WCF web services

Woo hoo! I created another Dime Cast and its up and running today!

Learn how to migrate from your old asmx web services to new fancy WCF web services.

Check it out here

dynomite 

 

Beginning Programming Audio: ASIO4ALL Is Picky

I’m delving into some audio based development with Mark Heath and the NAudio library for a side project. This is a ton of fun and I hope to make a good presentation out of it for some code camps and eventually larger venues.

Everything was going good until I started playing with the MIDI controller. The set up was fine, however whenever I plugged in a MIDI controller into the laptop I’m using I would get that hiss/pop/crackle sound when I hit the keys on the controller (I use an AKAI MPD 24 for a MIDI controller). This is caused by buffer under-runs to and from the software from the controller. Basically, the sound buffer has to be full and ready to play when I hit a key. The lower the latency setting, the more buffer under-runs I got – the more snap-crackle-pop. Not good.

Here is a screen shot from FL Studio with the number of under runs:

image

Well… bump up the buffer length then, right? Well, not really. When you bump up the buffer length this bumps up the time that the software will return from a key hit. In music, if you hit a key, you expect a sound immediately. So if you have 100 millisecond latency to fill the buffer that’s 1/10 of a second off. THAT IS A LIFETIME between key hits. Imagine playing a piano and hitting a key and the sound doesn’t emit until 1/10 of a second later. When it comes down to it, this makes playing/recording music impossible and really crappy.

 

Welcome ASIO4ALL

ASIO4ALL Helps solve this problem. ASIO stands for “Audio Stream Input/Output” …

ASIO bypasses the normal audio path from the user application through layers of intermediary Windows operating system software, so that the application connects directly to the soundcard hardware. Each layer that is bypassed means a reduction in latency, the delay between an application sending sound to the sound being reproduced by the soundcard. In this way ASIO offers a relatively simple way of accessing multiple audio inputs and outputs independently. Its main strength lies in its method of bypassing the inherently high latency of Windows audio mixing kernels (KMixer), allowing direct, high speed communication with audio hardware. Unlike KMixer, an unmixed ASIO output is “bit identical”, that is, the bits sent to the sound card are identical to those of the original WAV file, thus having higher audio fidelity. [Source]

ASIO4ALL is a free driver that you can download to get this improved speed:

ASIO4ALL is a hardware independent low latency ASIO driver for WDM audio devices. It uses WDM Kernel-Streaming and sometimes even more sophisticated methods to achieve its objectives. [Source- Project Brief]

 

It Works, Sometimes

I installed the driver, set it up in my audio software (FL Studio) and got to town with some sound development. Sounds simple? Right? Well, you sort of need a little luck to get it running sometimes. I had some problems with the driver working intermittently. It took a few hours to figure out what was going on.

The problem had to do with streaming media such as You Tube. I would watch something on You Tube and then my ASIO4ALL driver would stop working.

 

The Fix

imageAs soon as I closed FireFox or IE (which YouTube was running in) the driver would start working again. It looks like something in FireFox or IE grabs a hold of the sound driver it needs (not the ASIO one), forces itself to be the primary and kills all other drivers (I think, maybe – I’m sure someone on ‘teh internets’ knows more about this than me – so please chime in).

So the fix? Close all other windows/apps that play sound while working with something that utilizes ASIO4ALL.

Now, when I have my buffer length set to 7 milliseconds, the under-runs are absolutely ZERO and my latency is gone – well, its 7ms, but that’s virtually nothing.

The a screen shot with ASIO4ALL shows it all.

I can now hit the keys on the MIDI controller, have an effective response and actually play music as it is meant to be played.

Prism Drop 8 Breaking Changes

The Prism team dropped another version of Prism last Friday at the usual spot: www.codeplex.com/compositewpf . This is Drop 8 of their product.

Breaking Change #1 – Cannot Find CompositeWpfEvent

However, there is not note of a breaking change in this drop that is not noted in the release notes.

The type “CompositeWpfEvent” has now been changed to “CompositePresentationEvent”. I had to hunt around in reflector for a few minutes to find what they had they had changed it to. Update your composite events to inherit from that new class name and you’ll be good to go.

Example:

Pre Drop 8:

public class CustomerAddedEvent : CompositeWpfEvent<Customer>
{

}

 

Post Drop 8:

public class CustomerAddedEvent : CompositePresentationEvent<Customer>
{

}

 

Breaking Change #2 = ModuleCatalog.Groups.Add Not Found

Here’s what the previous code looks like:

var catalog = new ModuleCatalog();
catalog.Groups.Add(
	new ModuleInfoGroup {InitializationMode = InitializationMode.WhenAvailable}
		.AddModule(typeof(MyTestModule).FullName, typeof (MyTestModule)));
return catalog;

 

here’s what it looks like now:

var catalog = new ModuleCatalog();
catalog.AddModule(typeof (MyTestModule), InitializationMode.WhenAvailable);
return catalog;

They changed the catalog so that the Modules and Groups return an Enumerable of the modules or groups. You cannot “Add” to an Enumerable return value. You can only get the enumerator on it and iterate through it (and then do some other stuff etc).