corrected Scala Enum implementation and changed sensor state to Enum for compatibility reasons with Esper