One of my current works-in-progress is a slightly modified version of the CORE_STM32 microcontroller board found at the uCApps.de website. [It’s a frame-based site so that first link won’t give you the site’s navigation links.] A number of years ago I started thinking about building a digital step sequencer, i.e. something that looks and feels like an old analog step sequencer like this one but equipped with modern conveniences like preset storage and recall, MIDI, endless encoders, etc. This project has occupied varying amounts of my spare time over the last five years. I finished most of the electronic design some time ago, but bogged down when it came to writing the firmware for the thing. This problem was fairly predictable: it’s my job to write software, and while I love writing software I do like to take a break from it when I’m not working (“working” in the sense of writing software that Audio Damage pays me to write). Hence I’ve done very little at all with the project for the last couple of years.
However, it seems that I’m not the only one obsessed with building digital sequencers. Thorsten Klose, owner of the aforementioned site, has put an astonishing amount of time and effort into his MIDIbox system. The pinnacle of his efforts is version 4 of his sequencer, which he calls MIDIbox SEQ V4, appropriately enough. You can find it about halfway down the left-hand navigation column on the uCApps.de website. When I first started thinking about my sequencer project, the MIDIbox system was far less sophisticated and hence I didn’t pay much attention to it. Also, Thorsten based his system on a PIC microcontroller which wasn’t powerful enough to run the software I envisioned. Since then he has switched to a much more powerful STM32 microcontroller and his sequencer design, while not entirely similar to my own, implements almost all of the functional ideas for a digital sequencer that have occurred to me and quite a few more that haven’t occurred to me. Since he’s kind enough to share all of his source code, schematics, and so forth with the rest of the world, I decided to adopt his system as the basis of my own.
This brings me back to the point of this entry. Rather than using his PCB layout for the STM32 core as-is, I decided to design my own PCB from his schematics. I replaced most of the through-hole components with surface-mount packages, dropped the CAN port because I don’t expect to use it, and added headers for almost all of the STM32 I/O pins. The result looks like this:
The components on the board represent the minimum necessary to determine whether the STM32 runs: the STM32 itself and its clock crystal, a USB socket from which +5V can be drawn, a 3.3V regulator, a connector for a JTAG interface, and an LED that demonstrates that the STM32 is able to execute code. It didn’t seem to work at first but after a bit of head-scratching I figured out that one of the JTAG settings in my IDE was set wrong. (I changed the “nTRST Open Drain” property from Yes to No, whatever that means.) I was then able to succesfully install the MIOS32 bootloader. This made the LED blink in a most gratifying manner. I added the components for the USB interface and MIDI ports and was able to use the MIOS Studio to verify that the STM32 was running the bootloader. This was all very pleasing since this is the most complex PCB I’ve laid out and aside from one incorrect footprint for the voltage regulator it seems to have no flaws. (The footprint problem proved to be due to a mistake made by the makers of my PCB software.)
The next step is to finish stuffing the board and hook up an LCD to see whether the LCD interface works. I ground to a halt at that point because I couldn’t find the ribbon cable for the LCD, and the local electronics shop isn’t open on Sundays. I think my Mouser shopping list is now long enough to meet their $25 minimum so I’ll order the necessary connectors this week. I’ll post a photo of the completed PCB next week.
If you’re wondering about the white blob on the resistor SIP near the top of the board, it’s silicone glue. The board needs a 4-resistor 10K SIP for the JTAG, I had only larger SIPs on hand, and the local shop didn’t have any of the right size either. I ended up cutting down a larger package with wire cutters and put the glue on the end to seal it back up. Works fine.
why not use the stm32f4discovery and a custom baseboard ? offers more features (like dsp capability)
Look at the date on my post–it was nearly three years ago. The STM32F4 Discovery board didn’t even exist when I made that PC board.