Mixed type in aray
-
gentleclockdivider gentleclockdivider https://www.kvraudio.com/forum/memberlist.php?mode=viewprofile&u=203660
- KVRAF
- Topic Starter
- 6173 posts since 22 Mar, 2009 from gent
I get a mixed type in array , I use three variables (range 0-15) to adres/scroll throught the wavetables
Eyeball exchanging
Soul calibrating ..frequencies
Soul calibrating ..frequencies
-
gentleclockdivider gentleclockdivider https://www.kvraudio.com/forum/memberlist.php?mode=viewprofile&u=203660
- KVRAF
- Topic Starter
- 6173 posts since 22 Mar, 2009 from gent
Simplified , same issue
What's wrong , I have done this numerous times in the past.
What's wrong , I have done this numerous times in the past.
Eyeball exchanging
Soul calibrating ..frequencies
Soul calibrating ..frequencies
-
gentleclockdivider gentleclockdivider https://www.kvraudio.com/forum/memberlist.php?mode=viewprofile&u=203660
- KVRAF
- Topic Starter
- 6173 posts since 22 Mar, 2009 from gent
P.s.
The sysex messages are still send ( first example ) but the error message stays there
The sysex messages are still send ( first example ) but the error message stays there
Eyeball exchanging
Soul calibrating ..frequencies
Soul calibrating ..frequencies
-
- KVRAF
- 2694 posts since 25 Aug, 2003 from Bournemouth, UK
It's because the default values for template parameters are `undefined`. So when the left rotary sends it's first message (let's say it is the value 23), the template is building the array `[ 23, undefined, undefined ]`, which is mixed and hence invalid. Once the third rotary has initialised, then the array is populated by numbers and everything is fine.
I've since added default values to [template], and better error messages for this situation.
I guess until you've sent all three values, you don't want the message to be sent anyway, as it would be an incomplete SYSEX message. The way I usually deal with this type of routing is to have a [branch] that between the rotary and the [template] call inlet. When the final rotary has initialised, it toggles the branch to allow messages to be sent to the `call` inlet. I can post a screenshot if that'll help explain what I mean?
I've since added default values to [template], and better error messages for this situation.
I guess until you've sent all three values, you don't want the message to be sent anyway, as it would be an incomplete SYSEX message. The way I usually deal with this type of routing is to have a [branch] that between the rotary and the [template] call inlet. When the final rotary has initialised, it toggles the branch to allow messages to be sent to the `call` inlet. I can post a screenshot if that'll help explain what I mean?
Architect, the modular MIDI toolkit, beta now available for macOS, Windows, and Linux.
-
- KVRAF
- 2694 posts since 25 Aug, 2003 from Bournemouth, UK
Effectively, this:
So messages to the `call` inlet are surpressed until after the third rotary has initialised.
(Which does admittedly seem like too many modules for a common idiom. Let me think about whether there is a better, cleaner, way of doing this...)
So messages to the `call` inlet are surpressed until after the third rotary has initialised.
(Which does admittedly seem like too many modules for a common idiom. Let me think about whether there is a better, cleaner, way of doing this...)
Architect, the modular MIDI toolkit, beta now available for macOS, Windows, and Linux.
-
gentleclockdivider gentleclockdivider https://www.kvraudio.com/forum/memberlist.php?mode=viewprofile&u=203660
- KVRAF
- Topic Starter
- 6173 posts since 22 Mar, 2009 from gent
The issue is that the values need to be send at all times .
There are 450 wave numbers and these are send out in hex , so each rotary range 0-15
For example 0,3,8 = wave number 56
1,4,4,=324 etc
I guess I will be better of with just one rotary ( value 0-450 )and use floor division + modulo to split it up into chunks of 16
There are 450 wave numbers and these are send out in hex , so each rotary range 0-15
For example 0,3,8 = wave number 56
1,4,4,=324 etc
I guess I will be better of with just one rotary ( value 0-450 )and use floor division + modulo to split it up into chunks of 16
Eyeball exchanging
Soul calibrating ..frequencies
Soul calibrating ..frequencies
-
gentleclockdivider gentleclockdivider https://www.kvraudio.com/forum/memberlist.php?mode=viewprofile&u=203660
- KVRAF
- Topic Starter
- 6173 posts since 22 Mar, 2009 from gent
Phew that's a lot of wiring for a simple task
Can't this be improved in the future ?
Can't this be improved in the future ?
Eyeball exchanging
Soul calibrating ..frequencies
Soul calibrating ..frequencies
-
- KVRAF
- 2694 posts since 25 Aug, 2003 from Bournemouth, UK
That example I posted should do what you need then. Once all three rotaries have initialised, changing the value of any of the three will send the SYSEX. It's only during setup that calling the template is supressed.
(I'm forming an idea of how to make this better, though, so watch this space...)
(I'm forming an idea of how to make this better, though, so watch this space...)
Architect, the modular MIDI toolkit, beta now available for macOS, Windows, and Linux.
-
- KVRAF
- 2694 posts since 25 Aug, 2003 from Bournemouth, UK
Although, in this specific case, where basically you take one value that you need to split into sysex bits, I think that modulo and floor division is perhaps the better solution. It would certainly be more intuitive to choose a value from one rotary than split across three.
Architect, the modular MIDI toolkit, beta now available for macOS, Windows, and Linux.
-
gentleclockdivider gentleclockdivider https://www.kvraudio.com/forum/memberlist.php?mode=viewprofile&u=203660
- KVRAF
- Topic Starter
- 6173 posts since 22 Mar, 2009 from gent
Yep , that's what I am working on now
thanks for the help
thanks for the help
Eyeball exchanging
Soul calibrating ..frequencies
Soul calibrating ..frequencies
-
- KVRAF
- 2694 posts since 25 Aug, 2003 from Bournemouth, UK
No problem. If you do get this working with a single rotary, I'd be interested in seeing your solution, if you wouldn't mind sharing. Thanks.
Architect, the modular MIDI toolkit, beta now available for macOS, Windows, and Linux.
-
gentleclockdivider gentleclockdivider https://www.kvraudio.com/forum/memberlist.php?mode=viewprofile&u=203660
- KVRAF
- Topic Starter
- 6173 posts since 22 Mar, 2009 from gent
Much easier this way
Here's the solution , works perfectly with just one knob range 0-450 , with use of modulo and floor division
Here's the solution , works perfectly with just one knob range 0-450 , with use of modulo and floor division
Eyeball exchanging
Soul calibrating ..frequencies
Soul calibrating ..frequencies
-
- KVRAF
- 2694 posts since 25 Aug, 2003 from Bournemouth, UK
Great work! Thanks for sharing.
Architect, the modular MIDI toolkit, beta now available for macOS, Windows, and Linux.