UPDATE AUG2020: Info about encoder pins have been added to help people wanting to use alternative firmwares.

UPDATE JUL2020: Termination series resistor have been added on the 3 SPI lines. Only the brain is updated (1.2). Control board is unchanged.

UPDATE  APR2020: If the module doesn’t seem to start after programming, try programming the MI bootloader first then re-program with the firmware from this page.

UPDATE  MAR2020: Some testers had to add a 22R on the MOSI between the pill and the DAC, that involves cutting the trace on the PCB.

UPDATE  FEB2020: new Blue Pill batches in 2020 have the expect 64kb, so you’ll need the Robotdyn board (choose STM32 NO SOLDER option).

Braids through-hole is a 12 bits through-hole adaptation of the iconic Mutable Instruments Braids digital oscillator. It’s a 100% non-commercial effort developed purely for the fun. In 2017-2016 I worked a lot with the “Blue Pill” a small STM32F103C8T6 dev board. I noticed that 100% of the boards from a specific Aliexpress seller had enough program space to fit the Braids firmware and so it began.

Please note this is working but still a work in progress, I’d love to hear your feedback after you built one unit so I can improve the files.

Motivation:
My drive for this project was to be able to give something back to the DIY community and pay homage to the most fascinating woman in Eurorack. I was also a member of some DIY eurorack groups on Facebook and read posts about failed DIY Mutable modules on a daily basis. Some really brave/crazy people out there were starting those complicated SMD projects without any experience. I love SMD and all SoundForce commercial products are SMD. But I wanted to work on something anybody could make and that would be affordable for a greater group of people.

The catches:
EDIT: All 2020 blue pills seem to have only 64kB, so order the recommended Robotdyn board below. You need to get exactly the right Blue Pill. Most of those chinese boards are populated with a clone of the STM32F103C8T6. Nevertheless, the clone is working perfectly. The F1 was introduced in 2007 and is still extremely popular on the chinese market. Braids was using an original STM32F103CBT6 with 128kb. The Aliexpress seller recommended in the BOM always delivered me with STM32F103C8T6 that had 128kb. Stick to that one and you should be good, I had 100% working boards with 128kb out of 150 as I used that board in the previous generation of my MIDI controllers. You can also buy a STM32F103CBT6 board from RobotDyn, the quality is usually better. But I think it’s not worth paying 5/6 times more, especially when the module is not using the voltage regulator on the blue pill.

The DAC (MCP4822) resolution is only 12 bits, which means that for sounds that are not 10V peak-to-peak, the signal to noise ratio is inferior compared to the original design. Think about the drums sounds or anything that has an decaying envelope. However in my opinion, this tradeoff is not a deal breaker as the 12 bits DAC is DIY-friendly and half the price of the original DAC8551 16 bits DAC. I was not interested into making breakout boards of that original DAC or selling them for that matter.

Encoder pins
The encoder pins had to be changed because there were not free on the blue pill boards. ENC_A is PA0, ENC_B is PA1 and the switch PA2. If you want to use any alternative firmwares with the hardware from this project you will need to change the pins in “encoder.cc” in the folder “drivers”, replace the 4 lines (lines 36-38 in the original firmware) with hose:

gpio_init.GPIO_Pin = GPIO_Pin_2 | GPIO_Pin_0 | GPIO_Pin_1;
gpio_init.GPIO_Speed = GPIO_Speed_10MHz;
gpio_init.GPIO_Mode = GPIO_Mode_IPU;
GPIO_Init(GPIOA, &gpio_init);

Super rough demo video:
Just to show that it actually works. If you want a complete demo, check the divkid demo.

Update 2019:
Please note that the design has been slightly updated since the pictures were shot. The PCBs can be held together with spacers and screws. There is also a capacitance mutliplier to filter the analog 3.3V a little better.

The hardware:
I kept the front panel layout exactly as the original, as I needed plenty of space and after-market front panels are easy to find for the original layout. The brain PCB is smaller than 10x10cm to fall in the super-cheap category at your main PCB manufacturers. I wanted to keep the circuit as close as possible to the original (to avoid editing and debugging the firmware too much) and kept the part numbers as much as possible the same. All the analog and digital pins used on the STM32 are exactly the same. The analog-to-digital section is using the same circuity with through-hole variants of the TL074, MCP6004 and MCP3204. I know that digital noise would be a potential problem with only 12 bits, so I added a second voltage regulator for a dedicated analog 3.3V that powers the DAC and ADC. I also connected the STM32 ground directly to the Eurorack power connector and isolated it from the PCB ground pour. The ADC, DAC and Vregs are decoupled with 100nF and 10uF. I haven’t AB’ed with and without but those small things are known to help fight noise.

Firmware:
Only the DAC.h (Write function) has been edited to fit the SPI commands for the MCP4822. See line 43. I compiled the firmware and the hex file is available for the DIYer’s convience. There is 1 variant with the encoder rotation direction inverted. To compile the firmware yourself, the best is to follow Mutable Instruments guide and simply replace DAC.h with this one before running make.

PCB build up:
For convenience during the layout process, I kept both the control and brain PCBs in the same Eagle file. To order the PCBs at a factory, I separated them in their own Eagle files.

Files:
All the files are available for download and adapations/remixes are welcome! A better through-hole DAC might be good, let me know if you have recommendations. It will go on github when I have time for that.

Eagle files: Both PCBs, Control PCB only, Brain PCB only.
Schematics: PDF
Silkscreen PDFs: Control PCB, Brain PCB
Gerber files: Control PCB only, Brain PCB only.
PCB front panel (by Julien from alpesmachines.net): Braids_THT_fp (order in 2mm)
Firmware: Firmare file with normal encoder rotation, inverted encoder rotation.
For assembly: BOM, Assembly recommendations

Programming the board:
You can program the blue pill either with a ST-link programmer or a USB to UART (serial) adapter (I recommend the CP2102 for its good drivers). You will need few jumpers wires female-female to connect the necessary pins. If you have already another serial adapter (FTDI or so) or a ST nucleo/discovery boards you can use that as well. There are few software options. The STM32 cube programmer is cross-platform and usually works better with the UART route on my MAC. On Windows, the old ST-link utility is still working great. You can also program the board through Mutable’s environment, but it is not mandatory.