https://nl.mathworks.com/help/driving/ref/matlab.system.addobserver.html
addObserver - Add observer to scenario simulation - MATLAB
An observer is a type of actor that you can create and add to the MATLAB cosimulation client in addition to the main actors participating in a scenario.
addobserverscenariosimulationmatlab