Android app - connecting 2 devices

I’m wanting to build an android app using meteor that will simply record accelerometer and gyroscope data. Importantly, I want a second app on a second device that I can use to control the first app. For example, the second device would be used to start and stop sensor recording on the first device. Or send data to the first device to save on that devices’ database

Is there an easy way to achieve this? Any tutorials or documentation that you could point me to that would provide some insight?