Cleaned up a lot of code and have a simple example working