Removed most of the configuration logic (to streamline/simplify the project).
Moved EMS logic towards the EMS controller.