I would like to share my scenario with you, i am willing to connect more than one android device to remote gateway through exosite cloud to control devices connected over zigbee with the gateway.
these devices which are connected over zigbee with the gateway are various such as sensors and lighting devices, so they are controlled by the gateway using command protocol developed by me, now my idea to control these devices using the android devices connected to the cloud is to create a device which represent the gateway and add data to it which are 2 variables command and command_state and send the command to and from the gateway and android devices by passing the command to these variables.
The problem is that how to send a command from gateway to the all the controlling android devices and make sure that they all will receive the reading for examples, or if 2 devices for example read and write at the same time from the device what would be the case.
What would be the best approach if not using these 2 variables to control the devices??