Added comment describing the need for the device state

enum to live in a separate header.

Refactored motor controller state to its own separate header and created
a helper function which converts the state into an aJson object. I
expect this pattern to replicated for each of our Arduinos moving
forward.