Thanks! Since there is no editor for the script (outside of regular json editors), I knew TimeSeq would be impossible to use without a decent manual. So I tried to make it as clear and detailed as I could. Good to hear that I didn’t mess it up
Can’t you make VSC do a schema validation on json? btw, possibly of interest - a few VCV sequencer support this JSON:
I actually started out with json schema since the idea was to use it in the module itself to validate scripts while loading. But the resulting error messages (though technically correct) were to cryptic to use towards end users (I doubt many non-developer VCV Rack users would know what to do if they got an error about a oneOf
or an anyOf
), so I started adding detailed validation with dedicated error messages as part of the loading of the internal data modal. And I didn’t maintain the schema as the script changed. I do plan to return to it, probably making a more high-level version that validates the object hierarchy and possible object properties without validating every little detail. And I have a couple of ideas that I want to look into that could provide additional validation on top of that. It’s one of the many things on the to-do list.
But even with such a json schema, I would still consider the current reference documentation as a must-have to provide details about what everything does.
Oh, I think what you did make a ton of sense. I also tried to document the JSON well for my relatively simple keyboard re-mapper inthe Seq++ manual.
I think I was reflexively reacting to your “there are no good JSON editors” with “yes, there are”. But obviously you meant the more useful “there are no JSON editor that is really appropriate for most VCV users”,
when I try to load your example scripts to TimeSeq I get an error:
I’m on win 11 and using vcv 2.6.3, do I need top update to 2.6.4?
Or what could be the problem?
I’m betting that you copied from text off of a web page. What you copied is something that has been reformatted for presentation in a web browser, and not the original plain text. All those spaces have been replaced with non-breaking space (U+000A) to make web rendering look right. It will work if you replace all the U+000A’s with regular space characters.
Or find a copy of the original json file.
Like Paul said, it does indeed look like you ended up with invalid formatting when downloading/copying over the script, resulting in invalid JSON. Which script did you try to load, and what steps did you take to get the script itself and load it into TimeSeq? I tried reproducing with either copying directly from the json file in GitHub, doing a “Copy raw file” or downloading the file from GitHub, but that gave me a valid JSON file for each of those tries.
The VCV Rack version shouldn’t have an impact on the JSON parsing.
Ahhh… , ok, I got it,
I did the download with a right mouseclick
and “save target as…” on the link in the manual.
After I tried it again, with the raw download,
it loads as expected.
The script links in the documentation do indeed point to the regular GitHub urls for the json files, so “save target as…” will give the GitHub HTML rendered version. Good that you pointed this out, I’m going to update the documentation links to point to the raw versions instead so that the right-click-save also works.
Release v2.0.5 of the not-things modules is now available in the VCV Rack library
New features in TimeSeq
- Created a JSON Schema to allow easier editing in JSON editors that are schema-aware (e.g. Visual Studio Code). See this section in the documentation about how to add the schema reference to a script
- Allow additional calculation operations by adding
max
,min
,remain
,trunc
,frac
,round
,sign
andvtof
options tocalc
- Added quantization to scales through
tunings
, which can be used in aquantize
operation of acalc
, allowing values to be quantized to a scale - Added support for variable length
segments
by allowing the usage ofvalues
in a segmentduration
instead of only allowing a fixed length for a segment - Some minor bugfixes
- Extended the Note Sequence sample to include the generation of a random melody that gets quantized to a scale
- Extended the Oscillator sample to use variable duration segments, which allows the frequency of the generated signal to be changed using a 1V/Oct input
Note: To be able to use the new features, the JSON script version must be set to 1.1.0
. Scripts with version 1.0.0
can still be used, but they can’t include the new features.
Global changes
- Moved the documentation to GitHub Pages instead of direct links to raw Markdown files in GitHub (resolves issue where right-clicking a link to download sample scripts would not work)
Documentation
- The full documentation for the not-things modules can now be found at https://not-things-modular.github.io/not-things-vcv/
- With the TimeSeq at https://not-things-modular.github.io/not-things-vcv/doc/TIMESEQ.html
- And the TimeSeq samples at https://not-things-modular.github.io/not-things-vcv/doc/timeseq/TIMESEQ-SCRIPT-SAMPLES.html
@not-things I’m trying Pi-Po but noticing some weird behavior. Is the following expected?
In the attached screenshot, I’d except slot 5 in Po to output four cv, because I have set slot 5 in Po to 4 outputs, but I’m not getting any voltages from 1-3 at that output. The input at slot 5 in Pi is receiving 16 lfos from Surge Quad LFO.
I have similarly split slot 1 into 4 equivalent groups which output correctly up from slot 1 through slot 4. But strangely, slot 5 is not outputting correctly. 6-8 out slots also appear ok.
Yes, if I understood your setup correctly then this is expected behavior: input ports on P-I aren’t directly linked to the output ports on P-O with the same number. Instead, all incoming channels on P-I are added to one big list, and can then be re-distributed over the output ports. And input channels that don’t have a cable connected to them are treated as single-channel inputs with 0V (hence the ‘1’ on the LED display next to inputs 2, 3 and 4).
So the 16 channels coming in on input 1 are distributed over outputs 1, 2, 3 and 4. The three non-connected inputs 2, 3 and 4 result in 3 0V channels which are those first 0V channels that you see on output 5. The first of the 16 channels from input 5 is then sent as the 4th channel on output 5 and the rest of the channels on input port 5 is distributed over the remaining outputs. If you want the first 4 channels of that second LFO signal to be sent to output 5, you should instead connect the cable to the second input port on P-I.
The fact that non-connected input connections are handled as single-channel inputs with 0V was implemented as convenience shortcut: sometimes it’s needed to create a polyphonic output where one or more channels always contain 0V. This shortcut removes the need to add an additional module in the patch that’s just used to output an explicit fixed 0V output signal. But it does mean that you can’t skip over input ports if you don’t want those additional 0V channels to be there.
Cool, that makes sense. Will try adjusting the setup as described.