Cleaned up coding, added ability to invoke multiple instances with their
own configurations