Polished/Updated the library and changed the example codes accordingly.