send JSON message to device