Appearance
Signal Switch
Two-way selector for double signals. Signal mode: out = in_1 while the integer control input is greater than 0, otherwise out = in_2. Time mode: out = in_1 until the switch time, then out = in_2 for the rest of the run (the ctrl pin is hidden). The change happens in one step with no blending, and the first sample at or after the switch time is already in_2. Drive ctrl from Relational Double, Relational Int, Hysteresis Comparator or any other int flag, or enter a simulation time for a scheduled handoff.
Category: Signal Routing
Ports
| Port | Kind | Signal | Notes |
|---|---|---|---|
in_1 | Control input | Real | |
ctrl | Control input | Integer | Shown when Trigger is Signal |
in_2 | Control input | Real | |
out | Control output | Real |
Parameters
| Parameter | Type | Default | Units | Description | ID |
|---|---|---|---|---|---|
| Trigger | Choice: Signal / Time | Signal | — | Signal: out = in_1 while ctrl > 0, otherwise out = in_2. Time: out = in_1 until Switch time, then out = in_2 for the rest of the run. The ctrl pin is hidden in Time mode, and any wire on it is removed. | trigger_mode |
| Switch time | Number | 1 | s (also ms) | Simulation time at which the output changes from in_1 to in_2. The first sample at or after this time is already in_2, and it stays on in_2 for the rest of the run. Time mode only. | switch_time |