Skip to content

Commit

Permalink
update to v2.6.17
Browse files Browse the repository at this point in the history
  • Loading branch information
sickozell committed Jan 25, 2025
1 parent e321b2e commit 01a263d
Show file tree
Hide file tree
Showing 5 changed files with 69 additions and 24 deletions.
12 changes: 9 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -416,10 +416,12 @@ LIM switch enables hard clipping limiter set to ±5v on the output.
Click on the slot number to open dialog.
When the sample is loaded the green led on the panel is turned on (drumPlayer), or the small 7segment display will show the first chars of the filename (drumPlayer+ drumPlayerXtra).


**Set samples root folder**
Once a folder is set, 'Samples browser' option is activated in the quick load menu (right click in the relative led slot area/display) to quickly choose samples from the selected folder.

**Randomize** (drumPlayerXtra only)
This option is displayed only if a root folder is set. It will load random samples from the root folder.

**Interpolation**
There are 3 different interpolation algorithms, that are engaged during playback only when the sample samplerate differs from VCV working samplerate or playback speed differs from 100%.
- 'No interpolation' can be used when sample rates match and speed is 100% constant
Expand Down Expand Up @@ -1037,8 +1039,12 @@ Please note that extreme settings can however alter pitch a little or obtain a b

![simpleseq4](https://github.com/user-attachments/assets/b1ceb7dd-ca60-44f0-9c0d-d3744f86b5d1)

A tiny and simple 4 step sequencer. If a negative voltage is applied to DIR input the sequencer will advance backwards.
Various knob voltage ranges are available in the right-click menu.
A tiny and simple 4 step sequencer. If a positive (greater than +1v) voltage is applied to REV input the sequencer will advance backwards.

**Right-click Menu**
- Various knob voltage ranges are available (default is -10/+10v).
- 'Reverse Input Voltage': if 'Negative' is ticked the sequence will advance backwards only if a negative (less than -1v) gate is applied to REV input


[back to top](#table-of-contents)

Expand Down
2 changes: 1 addition & 1 deletion changelog.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
### 2.6.17 (2025-01-21)
### 2.6.17 (2025-01-25)
- added 'simpleSeq4' module
- added 'Attenuator' option on adder8 module
- 'drumPlayerXtra': added 'Randomize samples' in context menu when setting a root folder
Expand Down
2 changes: 1 addition & 1 deletion extra/crossCompiler.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
git tag v2.6.17-beta12 -m "create v2.6.17-beta12"
git tag v2.6.17-beta13 -m "create v2.6.17-beta13"
git push origin --tags

delete local tag
Expand Down
22 changes: 11 additions & 11 deletions res/SimpleSeq4.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
55 changes: 47 additions & 8 deletions src/SimpleSeq4.cpp
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
#define FORWARD 0
#define REVERSE 1
#define POSITIVE_V 0
#define NEGATIVE_V 1

#include "plugin.hpp"

Expand All @@ -13,7 +15,7 @@ struct SimpleSeq4 : Module {
enum InputId {
TRIG_INPUT,
RST_INPUT,
DIR_INPUT,
REV_INPUT,
INPUTS_LEN
};
enum OutputId {
Expand Down Expand Up @@ -42,6 +44,8 @@ struct SimpleSeq4 : Module {
bool initStart = false;
int recStep = 0;

int revType = POSITIVE_V;

SimpleSeq4() {
config(PARAMS_LEN, INPUTS_LEN, OUTPUTS_LEN, LIGHTS_LEN);
configInput(TRIG_INPUT, "Trig");
Expand All @@ -52,7 +56,7 @@ struct SimpleSeq4 : Module {
configParam(KNOB_PARAM+2, 0, 1.f, 0.5f, "Knob 3");
configParam(KNOB_PARAM+3, 0, 1.f, 0.5f, "Knob 4");

configInput(DIR_INPUT, "Direction");
configInput(REV_INPUT, "Direction");

configOutput(OUT_OUTPUT, "Output");

Expand All @@ -79,6 +83,7 @@ struct SimpleSeq4 : Module {

json_t* rootJ = json_object();
json_object_set_new(rootJ, "range", json_integer(range));
json_object_set_new(rootJ, "revType", json_integer(revType));
json_object_set_new(rootJ, "step", json_integer(recStep));
json_object_set_new(rootJ, "initStart", json_boolean(initStart));

Expand All @@ -94,6 +99,13 @@ struct SimpleSeq4 : Module {
range = 4;
}

json_t* revTypeJ = json_object_get(rootJ, "revType");
if (revTypeJ) {
revType = json_integer_value(revTypeJ);
if (revType < 0 || revType > 1)
revType = 0;
}

json_t* stepJ = json_object_get(rootJ, "step");
if (stepJ) {
step = json_integer_value(stepJ);
Expand All @@ -114,11 +126,6 @@ struct SimpleSeq4 : Module {

void process(const ProcessArgs& args) override {

if (inputs[DIR_INPUT].getVoltage() >= 0)
direction = FORWARD;
else
direction = REVERSE;

rstValue = inputs[RST_INPUT].getVoltage();
if (rstValue >= 1.f && prevRstValue < 1.f) {
lights[KNOB_LIGHT+step].setBrightness(0);
Expand All @@ -128,6 +135,19 @@ struct SimpleSeq4 : Module {

trigValue = inputs[TRIG_INPUT].getVoltage();
if (trigValue >= 1.f && prevTrigValue < 1.f) {

if (revType == POSITIVE_V) {
if (inputs[REV_INPUT].getVoltage() < 1)
direction = FORWARD;
else
direction = REVERSE;
} else {
if (inputs[REV_INPUT].getVoltage() < -1)
direction = REVERSE;
else
direction = FORWARD;
}

lights[KNOB_LIGHT + step].setBrightness(0);
if (direction == FORWARD) {
step++;
Expand Down Expand Up @@ -225,7 +245,7 @@ struct SimpleSeq4Widget : ModuleWidget {
addChild(createLightCentered<MediumLight<GreenLight>>(mm2px(Vec(xLight, yLgStart + (yKnShift * 2))), module, SimpleSeq4::KNOB_LIGHT+2));
addChild(createLightCentered<MediumLight<GreenLight>>(mm2px(Vec(xLight, yLgStart + (yKnShift * 3))), module, SimpleSeq4::KNOB_LIGHT+3));

addInput(createInputCentered<SickoInPort>(mm2px(Vec(xCenter, yDir)), module, SimpleSeq4::DIR_INPUT));
addInput(createInputCentered<SickoInPort>(mm2px(Vec(xCenter, yDir)), module, SimpleSeq4::REV_INPUT));

addOutput(createOutputCentered<SickoOutPort>(mm2px(Vec(xCenter, yOut)), module, SimpleSeq4::OUT_OUTPUT));

Expand Down Expand Up @@ -253,6 +273,25 @@ struct SimpleSeq4Widget : ModuleWidget {
menu->addChild(rangeItem);
}

struct RevTypeItem : MenuItem {
SimpleSeq4* module;
int revType;
void onAction(const event::Action& e) override {
module->revType = revType;
}
};

menu->addChild(new MenuSeparator());
menu->addChild(createMenuLabel("Reverse Input Voltage"));
std::string RevTypeNames[2] = {"Positive", "Negative"};
for (int i = 0; i < 2; i++) {
RevTypeItem* revTypeItem = createMenuItem<RevTypeItem>(RevTypeNames[i]);
revTypeItem->rightText = CHECKMARK(module->revType == i);
revTypeItem->module = module;
revTypeItem->revType = i;
menu->addChild(revTypeItem);
}

menu->addChild(new MenuSeparator());
menu->addChild(createBoolPtrMenuItem("Initialize on Start", "", &module->initStart));
}
Expand Down

0 comments on commit 01a263d

Please sign in to comment.