Refactored code base. Added services for accessing the API. Preload data in app.js before initialization of controllers.
Added states to device wizard.