implements updated protocol for single sensor sketch
implements updated protocol in multiplex sketch