Bunch of changes and bug fixes.
Major overhaul due to upgrading to new version of pipelib.  Much easier to use now.