Custom Shruthi Firmware: Visual Sequencer

Hi everyone! This is my first post here, I hope it’s in the right place.

I recently built a Shruthi XT, which has gotten me totally hooked on SDIY, especially the old MI desktop stuff (I’m definitely planning on building an Anushri, Ambika and another Shruthi in the near future!).

I made a small change to the Shruthi firmware, changing the sequencer view to a visual representation of the sequencer data when the mixer operator is set to seqmix:

The lines represent, from bottom to top: osc2, osc1, sub, noise. The display is unchanged when the mixer operator is anything but seqmix.

Here’s a ZIP with the .hex and .syx files for flashing:

More detailed explanation, quoted from my blog post about the change:

I spent an hour or so trawling through the synth code, and documentation for the LCD module, before managing to create a version of the software which, when the mixer operator is set to seqmix, replaces the 0-f step sequencer view with a two-line visual step sequencer, where the four lines from bottom to top represent osc2, osc1, sub and noise*

The controls for the view are exactly the same as before, i.e. pretty unintuitive, but this visualisation of the sequence data makes designing patterns way easier than before.

I originally wanted to have this view all on one line, by creating sixteen custom characters, one representing each combination of sound sources by a bar of pixels. Unfortunately, the HD44780 LCD module only supports eight custom characters, and the Shruthi already defines all of them. I got around this by spreading the display over two lines, reducing the number of characters needed to four, and taking advantage of the “=” default character as the “11” character, and the blank space as the “00” character. I then replaced the two decorative custom characters used on the Shruthi splash screen with single bar characters based on the “=” for “01” and “10”. Finally, in the Editor::DisplayStepSequencerPage function in, I made a conditional block based on the state of part.patch().osc[0].option (the non-intuitive location of the mixer operator setting), displaying the two-line visual view if it’s set to OP_PING_PONG_SEQ.

This is the first of several UI upgrades I plan on making to the Shruthi firmware, depending on how much I can tolerate working on old embedded code in a language I barely know!

*according to the shruthi manual, osc1 and osc2 should be the other way round, but that’s how it ends up working so I accepted it as it is.

1 Like

Did you remove anything from the firmware to make it fit into the flash? From my experience the memory is so crammed that even compiling with the wrong compiler version would make it overflow.

I would absolutely enjoy if you uploaded a *.patch file or made a repository fork so that we can incorporate your changes into the YAM alternative firmware.

1 Like

All I removed were the two decorative special characters for the splash screen, not due to flash size issues but because the HD44780 driver only supports 8 special characters, so I had to sacrifice the decorative ones to fit mine in. I downloaded CrossPack with avr-gcc 4.3.3 to get around the flash size issues, and the little code I added doesn’t seem to have caused any problems there.

Since then I came up with some more ideas for both controller sequencer value views which would get around this hardware limitation by swapping out the special character list when you enter and exit the view. I’ll probably try implementing that next.

Here’s a patch file for my changes: (2.6 KB)

I didn’t know about YAM, sounds like a lot of good changes! I’ll try it out and fork it for my future UI improvements if the sound improvements sound as good as they, er, sound.

1 Like

Yes, I think it would be great to have these improvements together with the other changes (improvements) in YAM. Ditching the special characters for your improvements is a no brainer, but I find backwards (patch) compatibility is of great value. At least I prioritized that in the YAM developments. With YAM for Shruthi there’s actually some memory left for improvements. (It’s worse with YAM for Ambika, at least for the central controller.)

@Bjarne amazing work on YAM, I’m playing through all the new and improved sounds now and it’s awesome! I’m definitely going to fork the repo and use that as the basis for the changes I want to make, all of which are really only minor UI things which won’t affect patch compatibility. In no particular order, my plans are:

  • Implement custom character map swapping to get a better visual seqmix view
  • A graphical view for the controller sequencer view for other operator settings (like a 16-step bar chart instead of 0-f values, which will still be visible on the main sequencer editor page if people want to see them)
  • Limiting the circumstances in which the full-screen parameter editing view is entered to: if there are possible parameter values which are longer than 3 characters; or if the parameter being changed isn’t on the currently visible screen (i.e. on a Shruthi XT)
  • Continuation of the above: getting rid of the full-screen modulation preview when scrolling through modulations (personally I find it extremely distracting and much prefer the values just changing)
  • In snap mode, a visual indication of how far away and in which direction a knob is from its stored value (as on the anushri but using the screen rather than LEDs, probably)

I don’t have an Ambika (yet! gonna build an Anushri then start on a 6x SMR4 Ambika) but when I get one I’ll definitely put Ambika YAM on it and see a) if I want to make any similar UI changes there and b) if they fit on the remaining flash…

1 Like

Sounds great! Glad you like YAM :slight_smile:

Great, thank you for the work on the UI!

While we are talking about further improvements: A huge improvement for Ambika could be a MPE mode.

One major challenge is the space left for the Ambika controller code. Personally, I think polyphonic aftertouch covers a lot of ground (and I use it extensively), and I’d rather like to prioritize support for higher resolution CC to reduce stepping when modulating filter cutoff with high resonance etc.

Well this is going off on a bit of a tangent, but, agreed, I would love to have higher resolution CC, at least internally, especially on the VCA/envelopes and filter cutoff. Having an analogue VCA/VCF is lovely, but it’s spoiled a little by audible stepping — although there’s probably a very good reason why it was made this way, and it’s not something I’m yet skilled enough to want to attempt changing.

MPE on the Ambika would be awesome!

Regarding the flash space, I’m probably talking nonsense here, but I remember reading a thread about potential chip upgrades to the 644p with a 1284p (1284p instead of 644p?) which wouldn’t work because of a hardware issue in the DIP version, but not the SMT version. I wonder if it would be possible (or indeed worth it) to use the SMT version with an adapter board — or alter the PCB layout to use an SMT footprint for that part?

I was hoping that something like this would work but the pin layout is wrong, so we’d need a custom board. It would be easy to design though.

I’ve been thinking about that to but my electronic noobness has prevented me from pursuing this adventure further.

@Bjarne if I designed an adapter board, ordered a small batch and put a couple together for testing, would that be enough to get around the noobness, i.e. could you then handle any software changes necessary for getting the firmware to work on the 1284p?

If you think the possible improvements would be worth it, and could paypal me the costs of a board, 1284p and shipping (probably not more than €15-20 if I ordered from dirtypcb) then I’d be happy to put a couple together for you, and anyone else who wanted to experiment with them. It’d be good board design and QFN soldering practice before I try DIYing any MI eurorack modules :slight_smile:


I’d be interested in a couple (2-4) of these for experimentation. The reason I’ve hesitated with this is not the firmware but (a) making the PCB, and (b) SMT soldering. I’m sure I’d be capable of the small modifications needed to get the firmware running, but I’d not be able to give any kind of timeline since everyday life has prevented me from firmware developments lately. On the other hand I’m sure many people would be capable of the small changes needed.

1 Like

One adapter board! A bit squashed but it should work out I think. I’ll order a pack of 10.

1 Like


Hi Guys , i think also interesting is to use another CPU fot the filterboard so that we have Ambika with a 16 bit sound.
Do you think that it is possible ??
If somebody prog a chip , i will make the analogue technic - filterboard , VCA and so on …

As discussed many many times that is interesting but it’s a much bigger project. Essentially the whole firmware has to be rewritten from scratch. It will basically mean developing a new synth from scratch. Just my two cents.

Not completely unlike the Hansy1010

The adapter boards finally arrived (cheap shipping from China takes about a month, apparently.) I have 44 of them in total! @Bjarne , I’m going to put three together and send them to you as a donation for your existing work on YAM, I’ll message you about that.

I’ll keep some of the boards for myself and offer to give the rest away, or assemble them for a few euros, for anyone interested in using them for work on Shruthi/Ambika development. I’ll make a new thread for that.

1 Like

That’s extremely generous of you! I consider it an unexpected x-mas present (or if it’ll be in time for the Chinese New Year) :smiley:
Big thanks in advance!