Midi Switch
MIDI / Channel Switcher
Version 2019
TT MIDI-Switcher - Version 2019
Content
Introduction................................................................................................................................3
General overview / inputs and outputs.....................................................................................3
Power-supply.........................................................................................................................4
BOM............................................................................................................................................ 5
Switching via MIDI commands..................................................................................................6
Program Change....................................................................................................................6
Controller Change..................................................................................................................7
Special functions...................................................................................................................7
Programming your own switching states.............................................................................8
Hints....................................................................................................................................... 8
Appendix 1 - schematic.............................................................................................................9
Appendix 2 – basic wiring.......................................................................................................10
Appendix 3 – Example, switching with 5V relays...................................................................11
Appendix 4 – Example, switching with 9 V relays..................................................................12
Notes for relay switching....................................................................................................13
Appendix 5 – Connection of external switches......................................................................14
AVR ISP
Tube-Town GmbH - [Link] -
Page 2
TT MIDI-Switcher - Version 2019
Introduction
The TT MIDI switcher is based on an ATMEGA 16 micro-controller and can be used as
switching central for channel switching and / or additional functions in guitar and bass
amplifiers.
The module does not necessarily have to be controlled via MIDI, but can also be operated
only with foot switches or switches mounted on the front of the amplifier. If a different
switching behavior than the standard configuration is needed, the use of external switches
is necessary.
General overview / inputs and outputs
If the TT-Midi-Switcher is operated with analog footswitches and panel mounted switches,
the following functions are available.
Footswitch inputs I1 - I4 are for channel switching. These are designed to work with the
usual cable lengths when footswitches are used. They correspond to the outputs A1 to A4
and output Z0, which is intended as a mute. Only one output can be active at a time in this
switching group, all other outputs are switched off automatically as soon as a new
switching state is initiated. Example: If input I2 is activated, then output A2 is set to ON
and outputs A1, A3 and A4 are immediately set to ZERO. In addition, output Z0 is set to ON
before the actual switching. This can be used to achieve a mute function (e.g., with an
optocoupler which switches the input signal to ground).
The inputs I5-I8 are for additional controls, e.g. panel mount switches on the front panel
and are assigned to the outputs A5-A8. These inputs have no added circuit to handle
longer cable lengths and are intended only for the use of control elements directly on the
amp, so the cable lengths should be kept as short as possible (maximum 0.5 m). The
purpose of these inputs is to control features like e.g. a "bright" or a "boost" feature. The
inputs or the assigned outputs work independently of each other. Thus, each of the
outputs A5 - A8 can be ON or OFF at the same time, or in any possible mixed combination.
The outputs A1-A8 are linked to a power driver ULN2803 (Darlington Transistor Arrays).
With the ULN2803, a maximum load of 500 mA per output can be controlled. Another
advantage is the internal wiring of the ULN2803, which makes it possible to control relays
directly without the need for an additional protection circuitry. Please note: it is always
switched to ground!
Tube-Town GmbH - [Link] -
Page 3
TT MIDI-Switcher - Version 2019
Input Z1 is designed as "store" to permanently assign the current switching states to a
MIDI program.
The output Z2 is intended for a LED, which signals the successful storage by briefly
flashing.
Power-supply
On the main pcb of the TT-Midi-Switcher are two power supplies available. The main power
supply is essential for the operation of the module, from an input voltage of 6.3 - 9 VAC or
VDC, it supplies the voltage of 5 VDC required for the module. The TT Midi Switcher is
designed for use with 5V relays or optocouplers in the basic configuration.
Important: before using the TT-Midi-Switcher, the total power consumption of the
switching elements must be determined and it must be ensured it does not exceed the
maximum current of 1,5 A the used 7805 can deliver. For higher current and / or different
voltages, the additional power supply must be used. It may also be necessary to passively
cool the 7805 with a heat sink.
The second power supply on the main board, labeled "Extra Power Supply", can be used for
voltages other than the supply voltage. As an example 12 V for the operation of 12 V relays
or 9 V for phantom power of a MIDI device. It is not necessary to use relays for channel
switching, the use of optocouplers or transistors is also possible, of course.
If the available supply voltages are too high it is also conceivable to connect them first to
the additional power supply for lowering and then connect them to the main power supply.
For example you could bring the voltage down from 15 V to 9 V and then feed it into the
main power supply, which further reduces the voltage to 5V. With regard to cooling, the
same requirements apply as with the main power supply.
Tube-Town GmbH - [Link] -
Page 4
TT MIDI-Switcher - Version 2019
BOM
Part Value
R10, R20, R30, R40, D51 1 kOhm
R11, R21, R31, R41 10 kOhm
R50, Rled 220 Ohm
LED 3mm, rot
C1 1000 µF / 25 V
C2 1000 pF / 500 V
C3 100n / 50V
C4 47 µF /35 V
C10, C20, C30, C40, C101 100n / 63 V
C102, C103 22 pF / 100 V
Oz1 7,372800 MHz
D1, D2, D3, D4, D50 1N4007
7805 LM7805
IC1 AVR Atmega 168-PU
IC2 ULN2803A
IC3 6N138
Tube-Town GmbH - [Link] -
Page 5
TT MIDI-Switcher - Version 2019
Switching via MIDI commands
The TT-MIDI switcher can also be switched via MIDI, of course. In the default setting, the
module expects the commands on MIDI channel 1.
To switch outputs A1 to A4, program change messages must be sent to the MIDI module,
followed by the program number. In the default configuration, PC 1 is assigned to output
A1, PC2 to output 2 and so on. So if PC 3 is sent to the MIDI switcher, the output A3 is
switched ON and the outputs A1, A2 and A4 are set to OFF (channel switching).
However, to address the outputs A5 to A8 directly, "Controller Change" commands must be
used.
The controllers are assigned to the outputs as follows:
Controller 85 to A5
Controller 86 to A6
Controller 87 to A7
Controller 88 to A8
To turn on output A6, a CC command must be sent on MIDI channel 1 to the MIDI switcher,
which addresses the controller 86 and includes a value greater than 64. Conversely, a value
less than 64 switches the output off.
Besides the standard ON / OFF switching, the controllers 89, 90, 91 and 92 enable a
"toggle" mode. The current switching state of the output is simply reversed: ON turns OFF
and OFF turns ON. The value sent to the controller change has no influence and can be
arbitrary.
Since firmware version 2.1, outputs A1 to A4 can also be switched via controller change
commands. The output is switched ON with a value greater than 64. OFF switching is not
provided.
The following overview shows all available commands, assignments and possible
parameters
Program Change
PC 1 - switches A1 ON - A2 OFF - A3 OFF - A4 OFF
PC 2 - switches A1 OFF - A2 ON - A3 OFF - A4 OFF
PC 3 - switches A1 OFF - A2 OFF - A3 ON - A4 OFF
Tube-Town GmbH - [Link] -
Page 6
TT MIDI-Switcher - Version 2019
PC 4 - switches A1 OFF - A2 OFF - A3 OFF - A4 ON
Controller Change
The first number corresponds to the controller:
81 - switches output A1 if value > 64 to ON, if value < 64 to OFF
82 - switches output A2 if value > 64 to ON, if value < 64 to OFF
83 - switches output A3 if value > 64 to ON, if value < 64 to OFF
84 - switches output A4 if value > 64 to ON, if value < 64 to OFF
85 - switches output A5 if value > 64 to ON, if value < 64 to OFF
86 - switches output A6 if value > 64 to ON, if value < 64 to OFF
87 - switches output A7 if value > 64 to ON, if value < 64 to OFF
88 - switches output A8 if value > 64 to ON, if value < 64 to OFF
89 - switches output A5: Toggle, value arbitrary
90 - switches output A6: Toggle, value arbitrary
91 - switches output A7: Toggle, value arbitrary
92 - switches output A8: Toggle, value arbitrary
Special functions
Since firmware 2.2 the following controller change commands are also available by means
of which further configurations and settings can be made on the MIDI module:
93 mute function
Switches output Z0 (Mute) with a value > 64 to ON, with a value < 64 to OFF
94 Mute toggle, ditto, but pure toggle, value is ignored
102 clear memory
with a value > 64 delete (Reinit, all settings are reset to default and the program memory is
deleted)
103 Set the MIDI channel
Value corresponds to channel 1-16
Tube-Town GmbH - [Link] -
Page 7
TT MIDI-Switcher - Version 2019
104 Store Preset
assign current switching states to the program currently set
105 change mute time
Value corresponds to new mute time, default setting: 80 ms
106 Mute I5-I8 ON/OFF
Activate / deactivate mute function for inputs I5-I8
Programming your own switching states
Of course, own switching states can be assigned to individual programs and be activated
directly by calling the respective program number (Program Change). Proceed as follows:
Set the desired program with the "Program Change" command. This must be done using
external MIDI controllers, i.e. PC 4.
Then set the desired switching states, either with external footswitches and front panel
controls or via the controller change commands listed above. Example: A2 to ON, A5 and
A6 to ON, remaining outputs all OFF.
The configuration is finally saved by pressing the memory key, or alternatively by controller
change 104.
Finished.
If you want to recall this switching state at a later time, simply send "Program Change 4"
command to the MIDI switcher.
Hints
Up-to-date information, additions and additional software (MIDI SEND), as well as sample
images of the build can be found on the project page. Here is also informations on the
separately available μC for a looper version available.C for a looper version available.
Tube-Town GmbH - [Link] -
Page 8
TT MIDI-Switcher - Version 2019
The actual link to the project page can be found on the product page of the article kit-
midisw.
Tube-Town GmbH - [Link] -
Page 9
TT MIDI-Switcher - Version 2019
Appendix 1 – schematic
Tube-Town GmbH - [Link] -
Page 10
TT MIDI-Switcher - Version 2019
Appendix 2 – basic wiring
Tube-Town GmbH - [Link] -
Page 11
TT MIDI-Switcher - Version 2019
Appendix 3 – Example, switching with 5V relays
Tube-Town GmbH - [Link] -
Page 12
TT MIDI-Switcher - Version 2019
Appendix 4 – Example, switching with 9 V relays
Tube-Town GmbH - [Link] -
Page 13
TT MIDI-Switcher - Version 2019
Notes for relay switching
Generally all switching is done on the ground side, so the ULN2803 switches to ground.
Not all inputs and outputs must be assigned or used. Unused inputs and outputs are
simply left unconnected.
If voltages other than 5 V are required for relays, the needed voltage can be supplied by the
“extra power supply” on the main pcb (components not included!). It is important that both
the main voltage and the extra supply voltage have the same ground reference, so both
grounds are referenced together. This is shown in appendix 4.
The relay boards shown on the pictures are not included, these can be selected as
required. Possible boards to use are e.g. the following articles:
tbez-010 (double relay PCB)
tbez-020 (single relay PCB)
tbez-057 (single relay PCB, PCB terminal blocks)
tbez-059 (double relay PCB MAXI, PCB terminal blocks)
tbez-058 (single relay PCB MINI, PCB terminal blocks)
Instead of relays, also optocouplers or transistors can be utilized for the switching tasks.
This may require additional circuitry, such as dropping resistors for optocouplers as
example.
Tube-Town GmbH - [Link] -
Page 14
TT MIDI-Switcher - Version 2019
Appendix 5 – Connection of external switches
Tube-Town GmbH - [Link] -
Page 15