Auto TOSLINK switch
Hardware architecture
The hardware has been designed to offer a cost-effective solution without sacrificing conviviality. Aside from the mini USB connector which can be somewhat tricky, all the parts can be soldered by novice solderers.
The PCB is 5cm by 10cm and can be send to most cheap fab houses
For added assembly flexibility, the maker can either solder in right-angled or "standard" tactile switches. Maker can also either solder in TOSLINK connectors with soldereable mounting pins or plastic pegs. To use connectors with plastic pegs, indicated holes must be manually drilled using a 3.2mm drill bit. Those holes are not pre-made by the PCB fab house because their unusual shape would require additionnal cost of fabrication.
The PIC18F25k50 microcontroller unit has been elected to be the brain of the device. Although they are far from being the most Open Source-friendly devices around, they are cheaply priced and are supported for very long time. They natively support USB 2.0 connectivity with minimal external parts requirement. The device also support capacitive sensing for a potential PCB revision with touch sensitive buttons intead of tactile switches. Finally, the programming/development tool used for initial programming is very cheap. You can buy/build a PicKit 2 clone for less than $10USD.
The PCB layout has been designed to attempt and place all cables on a single side of the PCB. Unfortunately, in order to keep the PCB from being over 10cm but not place connectors too close from one another, the secondary TOSLINK output has been placed on one of the side of the PCB. If the placement is problematic, it would still be possible to use a right-angle TOSLINK adapter with it. A user not needing a second TOSLINK ouput port could not solder the connector in question without consequence.
The board also has the dedicated microcontroller's SPI, I2C and UART buses are broken out on a header. These could be useful for interfacing potential addons, like a character LCD, a network of interconnected TOSLINK switchers or even IR receiver.
A third FUNC pushbutton has been added for future feature addition. Currently it isn't used and could be left unpopulated.