Add example project, fix bug