Jellybeans - Diatonic Quantizing Arpeggiator for Daisy Patch

Hey folks :slight_smile:

I’ve finished my first Daisy project! It’s a diatonic quantizing arpeggiator (similar to WMD Arpitecht). There are still some bugs to fix and features to implement, but it’s in a good place for a public release.

The source code is available here.

In order to create this, I’ve implemented a couple libraries that you might find helpful:

Some of you may take particular interest in rhythm, the tempo keeping library; it uses deltas between timer ticks on Patches’ TIM_2 to keep tempo. It can also detect BPM from an external clock via trigger signal inputs.

This is my first time making anything in embedded, Daisy, and C++ so I’m sure there are plenty of mistakes and sub-optimal implementations. I’d certainly appreciate anybody’s advice on how to improve my code (or pull requests). In particular, the source code takes up a lot of space (~96% of Daisy’s 128kb flash) and I’d like to reduce its size so that I can implement more features without running out of space.

Bug reports and feature requests are also welcome, I’d love your feedback on how I can improve it.

Thanks for reading :slight_smile:

9 Likes

Wooooow that’s awesome! Great video guide aswell!!!

There will be always someone who has you’re bqck on the daisy forum haha
I safed uü for a long time and purchased the xaoc devices leibniz binary subsystem, mainly for rhytmic purposes but also wanned to use it for generativ cv sequences and was looking for a quantizer. I thought yeah maybe someone made one for daisy and looked up here and bääm on the same day you puplished this masterpiece.

I will try it out the next days but the video looks so promising. I guess I can use CV out 2 for simple quantizing purpose if I use bass ovtace set at 0 or?

And on top I have a really great arp in eurorack aswell. And I can change the cordtypes with cv at ctrl 2 or? If that is correct, do you maybe have a table of relations between incoming voltage and the chord type? I means that you can say from 0 to 1v it’s playing triad, from 1 to 2v triad+… and so on.
And for Inversions as well? Because I have the Westlicht performer and can dial in Voltages really precicly.
I guess I could look that up in you’re code, but I have no idea about coding in c++. Used daisy only in max gen till now.

But either way, great great project! May you wanna share what future feautures you wanna add?
Maybe if you want some input, you could add a mode where you could stop the arp and use both cv out’s as pure quantizers, with then options to set an quantized offset to the cv out 2, so that you get two notes out simultaneously and can controll the offset via cv input, maybe choose between the nodes off the selected chord. So you could have one cv input to controll the chord type and then for this spexial mode it gets rid of the cv input for inversion and let’s you instead choose the offset or the node in the chord for the second output. That coppled with a second time division for the second cv out you could basicly create two sequemces at once, but yeah you would loose the arp in that mode. Haha have no idea how hard to code that would be but it came to my mind when I saw the video.

But again thanks awesome app for the daisy patch!!!

1 Like

I thought yeah maybe someone made one for daisy and looked up here and bääm on the same day you puplished this masterpiece.

You picked a good time to look this up, I only made this post an hour ago :stuck_out_tongue:

I guess I can use CV out 2 for simple quantizing purpose if I use bass ovtace set at 0 or?

Yep! Currently it only supports quantizing in one octave but fixing that is pretty much the first thing I had planned after public release. Give me a few days and your wish will come true :slight_smile:

If that is correct, do you maybe have a table of relations between incoming voltage and the chord type? I means that you can say from 0 to 1v it’s playing triad, from 1 to 2v triad+… and so on.

Correct. Same for all other CV parameters.

May you wanna share what future feautures you wanna add?

All of my planned features are listed here.

Maybe if you want some input, you could add a mode where you could stop the arp and use both cv out’s as pure quantizers, with then options to set an quantized offset to the cv out 2, so that you get two notes out simultaneously and can controll the offset via cv input, maybe choose between the nodes off the selected chord. So you could have one cv input to controll the chord type and then for this spexial mode it gets rid of the cv input for inversion and let’s you instead choose the offset or the node in the chord for the second output. That coppled with a second time division for the second cv out you could basicly create two sequemces at once, but yeah you would loose the arp in that mode.

That’s a great idea. I’ll look into this and see how hard it would be to implement. The only possible thing stopping this would be the fact that I’m running out of room for source code. However, if I can fix this, I’d love to add some alternate modes of operation like this one

But again thanks awesome app for the daisy patch!!!

You’re welcome :slight_smile:

1 Like

Update: I’ve published version 1.3.0, which has fixed all major bugs I’m currently aware of.

1 Like

Thanks for your contribution :pray::+1:!
This seems awesome !
Exactly the kind of features I want for the patch !
Gonna check that when i will have some time ( which can took months unfortunately :joy:) but you really made my day !

1 Like

Awesome, I’m glad to hear it :slight_smile:

Update: I’ve published version 1.4.0, some settings now persist on a restart. There’s also a quantizer only mode.

The binary now takes up 99.88% of the allotted 128kb flash space, so I probably won’t be adding much else unless this changes.

1 Like

You can add OPT = -Os to your Makefile anywhere above the include $(SYSTEM_FILES_DIR)/Makefile line to compile with optimization targeted to reduce code size. Sometimes that may break things, but looks like your patch builds and runs fine and you get ~15kb free.

Previously (with -O2):

Memory region         Used Size  Region Size  %age Used
           FLASH:      130520 B       128 KB     99.58%

with -Os:

Memory region         Used Size  Region Size  %age Used
           FLASH:      118776 B       128 KB     90.62%
3 Likes

Thank you so much! This worked like a charm. Binary size in the latest build is down from 99.88% to 90.39%.

1 Like

Thanks for sharing. Somehow the Gate Out doesn’t trigger for me (tried the game on various modules). Used Math as clock in, but still no luck. Wonder what this could be?

Thanks for sharing. Somehow the Gate Out doesn’t trigger for me (tried the game on various modules). Used Math as clock in, but still no luck. Wonder what this could be?

Hmm which version are you running, 1.4.0? (It will tell you when you power on the module.) If so, could you let me know what your op mode and clock settings are?

Just recompiled it again, it shows version 1.4.1
The “Gate Out 1” just doesn’t trigger my Plinky (and if I don’t connect Gate and just have ‘continuous’ sound, the pitch changes as expected, so that works fine (and the display shows the notes changing).
“op mode” can be ARP or Quant", doesn’t matter. Clock mode either BPM or PerTrig.

Gotcha. I’m out of town right now but give me a few days and I’ll test things out on my own system; It’s entirely possible that you’ve uncovered a bug. In the meantime, there are older builds of Jellybeans in the “old_builds” folder, you could use one of those in the interim. I’d recommend 1.3.0

Thanks for your patience!

I tried the ‘official’ DaisyExamples patch_sm Gate Output example, and it doesn’t trigger either. Perhaps it is a hardware issue on my Patch.

When using the CV Output example, it works fine. Is there a reason to use Gate Output instead of CV Output? Are those outputs any different?

Ah, yeah, sounds like it could potentially be a hardware issue. On Jellybeans the gate output is needed because in BPM detection mode the note output can have different clock division than the clock in signal.

As a workaround, you could change the clock mode to PerTrig (which uses an external
trigger signal), mult that trigger signal, and use it to trigger your sound source as well.

FYI I tested things out on my own hardware this morning and gate output does work with version 1.4.1, so looks like you unfortunately have a hardware malfunction.