Initial commit from working code.