startCommunicationChannel abstract method
If the device is already connected, it does not mean that you can send and receive data.
There is a separate function for this in NearbyService - communication channel. You need to call startCommunicationChannel before using send. A communication channel can only be created if you are connected to some device.
You can monitor changes in communication channel state using the communicationChannelState getter.
Implementation
FutureOr<bool> startCommunicationChannel(
NearbyCommunicationChannelData data,
);