Added all the code from Stumptown Miners, tweaked a bit to be more easily configurable.