MATLAB: Is the output signal of a Manual Switch block shown with an incorrect legend in the scope in Simulink 7.2 (R2008b)

blockslegendmuxnamescopesignalsimulinkswitchviewervirtual

I have a manual switch block in my model. I inserted scope to view the output signal of this block using the Tools->Signal and Scope Manager Editor. The legend for this signal is always shown as "Switch Control" independent of the name of the signal.
This is very inconvenient as I have multiple manual switch blocks whose outputs are all sent to a single scope and all of them are shown as "Switch Control" in the legend.

Best Answer

This has been fixed in R2009a due to the changes made in the way scope legends are determined. For earlier releases read the following:
This is expected behavior in R2008b and earlier releases. The Simulink->Signal and Scope Manager always displays the output signal of the Manual Switch block as "Switch Control" in the legend of the scope.
The reason the legend shows this name is because the Manual Switch block is virtual and so the legend code traces back to find the actual source of the signal. In this case, that happens to be a block called "SwitchControl" (look under the mask of this block and you can see it).
The way the legend is designed, it attempts to trace back to the actual source and displays that signal label or if no label exists, it displays the block name.
One way to avoid this behavior is to name each of the signals in the Signal and Scope Manager. The attached scope_namesignals.mdl demonstrates this tactic.