Subsequent addition of the stream

Hello everybody,
I’m writing a simple app such that the device A transmits its stream (audio,data,video) to B. Now I need to turn off/on A’s camera through the dataChannel. Therefore the command that will be transmitted must guarantee that the camera is turned avoiding improprer battery drain.
Well, I’m trying to make a point.
The two devices negotiate and establish the connection correctly, the dataChannel as well, but when B tells A to turn on the stream, A then gets a microphone and camera with getuserMedia and then adds the stream and sends the new offer to B, what is transmitted is only the audio. So .onaddstream is not triggered on B. How should I handle the subsequent addition of the stream after the connection has already been established?
How should I handle the subsequent addition of the stream after the connection has already been established?

Do you complete the SDP O/A cycle without any errors?

Sorry for the delay in the response, but I solved it. t wasn’t a package problem, but a problem in my code.
Thanks anyway. Goodbye !

@ValentinoG If its for personal use and not for a project or company work, can you provide a simple example with your implementation?

Thanks in advance.