electro-music.com   Dedicated to experimental electro-acoustic
and electronic music
 
    Front Page  |  Radio
 |  Media  |  Forum  |  Wiki  |  Links
Forum with support of Syndicator RSS
 FAQFAQ   CalendarCalendar   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   LinksLinks
 RegisterRegister   ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in  Chat RoomChat Room 
 Forum index » Instruments and Equipment » WREN
Midi CC Problem
Post new topic   Reply to topic
Page 1 of 2 [31 Posts]
View unread posts
View new posts in the last week
Mark the topic unread :: View previous topic :: View next topic
Goto page: 1, 2 Next
Author Message
lamptablecomputer



Joined: Jun 02, 2016
Posts: 12
Location: USA

PostPosted: Thu Jun 02, 2016 8:28 pm    Post subject: Midi CC Problem Reply with quote  Mark this post and the followings unread

Hello,
been using WREN a bunch in the last few months, been a Nord Modular user for a while. Been exciting to see someone take that framework farther.

For some reason I cant get assigning Midi CC's to work correctly. I have a nanoKontrol, when I start turning knobs weird stuff starts to happen. It seems like the Midi value is only being tracked but not held.

Once I assign a midi cc to a parameter the virtual knob moves just like the knob on the NanoKontrol, but the actual value being fed into the DSP is only coming from the NanoKontrol as long as im physically turning the knob, as soon as I pause or let go the value jumps back to whatever it was before I assigned it to a midi cc. If I use the Midi CC Input module this does not happen.
Back to top
View user's profile Send private message
blue hell
Site Admin


Joined: Apr 03, 2004
Posts: 24079
Location: The Netherlands, Enschede
Audio files: 278
G2 patch files: 320

PostPosted: Fri Jun 03, 2016 3:36 am    Post subject: Reply with quote  Mark this post and the followings unread

Interesting Laughing

I will have a look at it, but it may be only next week that I have time - will report back here.

Thanks for reporting, oh and welcome to the forum!

_________________
Jan
also .. could someone please turn down the thermostat a bit.
Posted Image, might have been reduced in size. Click Image to view fullscreen.
Back to top
View user's profile Send private message Visit poster's website
MusicMan11712



Joined: Aug 08, 2009
Posts: 1082
Location: Out scouting . . .

PostPosted: Fri Jun 03, 2016 10:57 am    Post subject: Reply with quote  Mark this post and the followings unread

[This post was quoted in it's entirety in the one below.]
Last edited by MusicMan11712 on Mon Nov 21, 2016 10:11 am; edited 1 time in total
Back to top
View user's profile Send private message
lamptablecomputer



Joined: Jun 02, 2016
Posts: 12
Location: USA

PostPosted: Fri Jun 03, 2016 11:19 am    Post subject: Reply with quote  Mark this post and the followings unread

MusicMan11712 wrote:
I have one of the blue and white NanoKontrols and could test this to see if I get the same results (if it might be helpful). What version of wren are you using and can you either upload or PM the patch you created that seems to cause the problem? Of course, I will defer to anything Jan says or does.

A while ago I used the sliders on an evolution keyboard to control wren. I think I had like 3 or 4 CCs set up and I don't recall having the issue you described. However, from your description, it sounds like wren's midi CC module is very different from the one I test drove.

Steve


Im using the most recent (may 2016) version of Wren, I've had this problem since I started using Wren (jan 2016). Its literally any all midi cc that I assign for takeover of a virtual knob, any patch and any parameter so I dont think uploading a patch is needed. I also have changed the midi cc numbers on my nano kontrol so it wouldn't translate.

to be clear this only happens when I assign takeover of a virtual knob, I can use the midi cc in module just fine.

Im curious to see what happens with your NanoKontrol, please let me know if you test it out.

EDIT: Thanks Jan, no rush. I appreciate you taking the time.
Back to top
View user's profile Send private message
MusicMan11712



Joined: Aug 08, 2009
Posts: 1082
Location: Out scouting . . .

PostPosted: Fri Jun 03, 2016 1:25 pm    Post subject: Reply with quote  Mark this post and the followings unread

I have been looking for an excuse to download and try the newest wren, so maybe this is it. From what you say, though, it sounds like it might be an issue with virtual knobs. As I recall, I didn't use them; I think I just had the sliders from the evolution going right into some wren modules directly.
Back to top
View user's profile Send private message
blue hell
Site Admin


Joined: Apr 03, 2004
Posts: 24079
Location: The Netherlands, Enschede
Audio files: 278
G2 patch files: 320

PostPosted: Fri Jun 03, 2016 3:15 pm    Post subject: Reply with quote  Mark this post and the followings unread

lamptablecomputer,

I can not reproduce the issue it seems, let me explain what I tried to do:

I used a new server in my NetMidi program that I assigned a free TCP/IP port for (31416), I made both the MIDI in port and the MIDI outport connect to MIDI Yoke 1. This allows me to MIDI connect one Wren instance to another.

I started one Wren with a MidiCCOut module in it sending on ch 1 CC 2 with an LFO on the value input and another LFO to the clock input, and I made that Wren instance use port 31416. So this one sends the LFO output value as a MIDI CC2 message.

Then I started another Wren instance in which I assigned CC2 to to the rate control knob of an LFO. That wren was used port 31416 as well.

I could see the knob move in the 2nd Wren with what the LFOs were doing in the 1st instance. and when I stopped execution for the first instance [hit stop] the knob movement in the 2nd would stop where it was and not jump back - also the LFO in that 2nd instance seems to have the correct rate then.

This to me seems to basically be the same setup as you used - but maybe I did not understand it completely? or maybe it is specific to a particular knob?

_________________
Jan
also .. could someone please turn down the thermostat a bit.
Posted Image, might have been reduced in size. Click Image to view fullscreen.
Back to top
View user's profile Send private message Visit poster's website
blue hell
Site Admin


Joined: Apr 03, 2004
Posts: 24079
Location: The Netherlands, Enschede
Audio files: 278
G2 patch files: 320

PostPosted: Fri Jun 03, 2016 3:27 pm    Post subject: Reply with quote  Mark this post and the followings unread

A thing maybe to try is .. in the Wren debug screen [F5] you can turn on MIDI logging and MIDI msg logging - maybe this would reveal something.
_________________
Jan
also .. could someone please turn down the thermostat a bit.
Posted Image, might have been reduced in size. Click Image to view fullscreen.
Back to top
View user's profile Send private message Visit poster's website
lamptablecomputer



Joined: Jun 02, 2016
Posts: 12
Location: USA

PostPosted: Fri Jun 03, 2016 4:11 pm    Post subject: Reply with quote  Mark this post and the followings unread

Blue Hell wrote:
lamptablecomputer,

I can not reproduce the issue it seems, let me explain what I tried to do:

I used a new server in my NetMidi program that I assigned a free TCP/IP port for (31416), I made both the MIDI in port and the MIDI outport connect to MIDI Yoke 1. This allows me to MIDI connect one Wren instance to another.

I started one Wren with a MidiCCOut module in it sending on ch 1 CC 2 with an LFO on the value input and another LFO to the clock input, and I made that Wren instance use port 31416. So this one sends the LFO output value as a MIDI CC2 message.

Then I started another Wren instance in which I assigned CC2 to to the rate control knob of an LFO. That wren was used port 31416 as well.

I could see the knob move in the 2nd Wren with what the LFOs were doing in the 1st instance. and when I stopped execution for the first instance [hit stop] the knob movement in the 2nd would stop where it was and not jump back - also the LFO in that 2nd instance seems to have the correct rate then.

This to me seems to basically be the same setup as you used - but maybe I did not understand it completely? or maybe it is specific to a particular knob?


Jan, the LFO is sending continuous data, a midi CC knob is not? The problem im having is the virtual value tracks fine, but the real output value (what you actually hear) jumps to the tracked virtual value and then jumps back to the initial value after I stop turning the knob. an LFO is continuous data stream so it would react as if you never let your finger off of the knob.

Im home all day maybe I can record a quick video or something
Back to top
View user's profile Send private message
blue hell
Site Admin


Joined: Apr 03, 2004
Posts: 24079
Location: The Netherlands, Enschede
Audio files: 278
G2 patch files: 320

PostPosted: Fri Jun 03, 2016 4:20 pm    Post subject: Reply with quote  Mark this post and the followings unread

not continues .. yeah well it is .. but I stopped it.
_________________
Jan
also .. could someone please turn down the thermostat a bit.
Posted Image, might have been reduced in size. Click Image to view fullscreen.
Back to top
View user's profile Send private message Visit poster's website
lamptablecomputer



Joined: Jun 02, 2016
Posts: 12
Location: USA

PostPosted: Fri Jun 03, 2016 5:44 pm    Post subject: Reply with quote  Mark this post and the followings unread

is the Slaved LFO controlling anything or are you just looking at the virtual value of the Slaved Rate LFO knob? The problem Im having isnt with the displayed value its with the real value coming from the module.
Back to top
View user's profile Send private message
blue hell
Site Admin


Joined: Apr 03, 2004
Posts: 24079
Location: The Netherlands, Enschede
Audio files: 278
G2 patch files: 320

PostPosted: Sat Jun 04, 2016 12:41 am    Post subject: Reply with quote  Mark this post and the followings unread

ok, I looked at that with half an eye only ... it looked fine in my experiment, but will check again soon .. and just in case .. what module and what knob did you test with?
_________________
Jan
also .. could someone please turn down the thermostat a bit.
Posted Image, might have been reduced in size. Click Image to view fullscreen.
Back to top
View user's profile Send private message Visit poster's website
MusicMan11712



Joined: Aug 08, 2009
Posts: 1082
Location: Out scouting . . .

PostPosted: Sat Jun 04, 2016 5:27 am    Post subject: Reply with quote  Mark this post and the followings unread

So far I have done a basic test sending a nanokontrol knob sending out CC1 on Channel 1 to the freq of a basic sine osc. I doubled it to go to the DataGraph. (I am using miditangle.)

The NK knob changes the frequency in steps and I see a vertical line on the graph that corresponds with the midi data/freq.

I am using the MidiCCIn module, not the newer things wren has with CCs. I could test more if I knew what how the newer modules worked. But so far as I can tell I have confirmed that the nanokontrol data (midi value) works as described above.

Hope this helps.

Steve

Addendum 1:
Cool: I just discovered that setting the value module to Note gives the midi value (0 to 127). Is there a way to set that to display hex (00 to 7F)?

Last edited by MusicMan11712 on Sat Jun 04, 2016 5:59 am; edited 1 time in total
Back to top
View user's profile Send private message
MusicMan11712



Joined: Aug 08, 2009
Posts: 1082
Location: Out scouting . . .

PostPosted: Sat Jun 04, 2016 5:42 am    Post subject: Reply with quote  Mark this post and the followings unread

lamptablecomputer wrote:
to be clear this only happens when I assign takeover of a virtual knob, I can use the midi cc in module just fine.

So, my next step is to try a "takeover of a virtual knob." I have never attempted any thing like this. It seems you are trying to get a knob in wren to change position based on midi in data.
Steve

Update 1a: I recreated the problem successfully (after figuring out that by right-clicking I can assign a CC to a knob). I disconnected the MidiCCIn (the NK going to the freq control of the sine osc) and assigned the CC value to the freq knob. I made some videos to demonstrate, but unfortunately, I haven't figured out how OBS will record the audio. I will try later.

Update 1b: I don't know if its something I did wrong or if it's part of the problem, but it seems to me that with midi learn [CC assignment of knobs] the CC is not channelized like the MidiCCIn module is. When I used midi learn/assign, CC10 on all channels did the same thing. So far, I haven't found a way to have a knob only respond to one channel.

Update 1c: I have tried assigning CCs to a number of knobs and so far as I can tell, you cannot assign a specific midi channel as you can with the MidiCCIn module. Also, I tried several methods to create a work around, but no solutions yet. Maybe I am missing something here, or maybe the midi learn/midi assignment function cannot be channelized.
Back to top
View user's profile Send private message
lamptablecomputer



Joined: Jun 02, 2016
Posts: 12
Location: USA

PostPosted: Sat Jun 04, 2016 9:43 am    Post subject: Reply with quote  Mark this post and the followings unread

MusicMan11712 wrote:


Update 1b: I don't know if its something I did wrong or if it's part of the problem, but it seems to me that with midi learn [CC assignment of knobs] the CC is not channelized like the MidiCCIn module is. When I used midi learn/assign, CC10 on all channels did the same thing. So far, I haven't found a way to have a knob only respond to one channel.


Settings/netmidi/ then change where it says "omni" to a specific channel. This isn't a glitch, the setting is just in a different place.

Glad you were able to recreate my glitch though!
Back to top
View user's profile Send private message
MusicMan11712



Joined: Aug 08, 2009
Posts: 1082
Location: Out scouting . . .

PostPosted: Sat Jun 04, 2016 10:02 am    Post subject: Reply with quote  Mark this post and the followings unread

lamptablecomputer wrote:
Settings/netmidi/ then change where it says "omni" to a specific channel. This isn't a glitch, the setting is just in a different place.

Glad you were able to recreate my glitch though!

Thanks for this tip, but (1) that doesn't solve the original problem and (2) with netmidi/miditangle on ch 1 instead of omni, the MididCCIn module still seems to work just fine on individual channels.

I don't use netmidi; miditangle lets all channels through. Unless I am mistaken wren can respond to each channel individually with a single connection from the nanokontrol. Also, changing the setting from omni to ch1 doesn't force all incoming data to channel 1 so far as I can tell.

With netmidi, what does the change do? Just a guess, but maybe if someone has a keyboard that can only send data on one midi channel, perhaps that setting is an easy way to switch global CCs to a single channel?

In any case, I'd still say that you uncovered a glitch--CC assignments to knobs don't do what might be expected. I was hypothesizing a possible cause. Maybe when Jan has some free time, all this exploration will be useful.

Steve
Back to top
View user's profile Send private message
lamptablecomputer



Joined: Jun 02, 2016
Posts: 12
Location: USA

PostPosted: Sat Jun 04, 2016 10:20 am    Post subject: Reply with quote  Mark this post and the followings unread

MusicMan11712 wrote:

With netmidi, what does the change do? Just a guess, but maybe if someone has a keyboard that can only send data on one midi channel, perhaps that setting is an easy way to switch global CCs to a single channel?


I think the settings/omni/midi channel is just a way for virtually assigned midi cc's with the same number to not overlap, not global midi restrictions for the entire program. Thats why the midi module is unaffected
Back to top
View user's profile Send private message
MusicMan11712



Joined: Aug 08, 2009
Posts: 1082
Location: Out scouting . . .

PostPosted: Sat Jun 04, 2016 11:48 am    Post subject: Reply with quote  Mark this post and the followings unread

lamptablecomputer wrote:
MusicMan11712 wrote:

With netmidi, what does the change do? Just a guess, but maybe if someone has a keyboard that can only send data on one midi channel, perhaps that setting is an easy way to switch global CCs to a single channel?


I think the settings/omni/midi channel is just a way for virtually assigned midi cc's with the same number to not overlap, not global midi restrictions for the entire program. Thats why the midi module is unaffected


That makes sense. Have your ever gotten anything in the right-hand column of the global midi assignment tables in wren? I have not been able to enter in anything and haven't seen anything entered automatically.

Also, the more I played with the glitch effect, the more I decided that you are onto something with the thought that it is returning to some stored parameter--either the default/initial value--or a value changed via a non-midi CC control change.
Back to top
View user's profile Send private message
blue hell
Site Admin


Joined: Apr 03, 2004
Posts: 24079
Location: The Netherlands, Enschede
Audio files: 278
G2 patch files: 320

PostPosted: Sun Jun 05, 2016 12:41 pm    Post subject: Reply with quote  Mark this post and the followings unread

Ok, I'm back home.

I can confirm the issue now, the knob moves but the underlying value jumps back and does not properly reflect the knob position then anymore.

Will try to find out why that is.

_________________
Jan
also .. could someone please turn down the thermostat a bit.
Posted Image, might have been reduced in size. Click Image to view fullscreen.
Back to top
View user's profile Send private message Visit poster's website
blue hell
Site Admin


Joined: Apr 03, 2004
Posts: 24079
Location: The Netherlands, Enschede
Audio files: 278
G2 patch files: 320

PostPosted: Sun Jun 05, 2016 1:22 pm    Post subject: Reply with quote  Mark this post and the followings unread

There seem to be a couple of problems - fixed two sofar, the 3rd one is not clear to me yet - it seems to be related to sending MIDI very fast and logging MIDI at the same time.
_________________
Jan
also .. could someone please turn down the thermostat a bit.
Posted Image, might have been reduced in size. Click Image to view fullscreen.
Back to top
View user's profile Send private message Visit poster's website
blue hell
Site Admin


Joined: Apr 03, 2004
Posts: 24079
Location: The Netherlands, Enschede
Audio files: 278
G2 patch files: 320

PostPosted: Sun Jun 05, 2016 2:19 pm    Post subject: Reply with quote  Mark this post and the followings unread

The 3rd issue actually was related to sending MIDI, made a fix for that too. There still is an issue with logging MIDI sends, not going to fix that one for now ... better to have logging off for very fast MIDI.

Will make a new release with the fixes very soon.

Thanks for bringing this to my attention, and sorry for the mess Confused

Shocked there was yet another issue .. starting Wren in auto run mode with a patch sending MIDI could crash it on startup .. or it could crash on exit .. also fixed now.

_________________
Jan
also .. could someone please turn down the thermostat a bit.
Posted Image, might have been reduced in size. Click Image to view fullscreen.
Back to top
View user's profile Send private message Visit poster's website
blue hell
Site Admin


Joined: Apr 03, 2004
Posts: 24079
Location: The Netherlands, Enschede
Audio files: 278
G2 patch files: 320

PostPosted: Sun Jun 05, 2016 2:42 pm    Post subject: Reply with quote  Mark this post and the followings unread

Ok, version 2016.6.5.0 available now from http://bluehell.electro-music.com/modules/forums.html#top

This fixes a couple of other small issues too with some of the new modules from the previous release.

_________________
Jan
also .. could someone please turn down the thermostat a bit.
Posted Image, might have been reduced in size. Click Image to view fullscreen.
Back to top
View user's profile Send private message Visit poster's website
MusicMan11712



Joined: Aug 08, 2009
Posts: 1082
Location: Out scouting . . .

PostPosted: Sun Jun 05, 2016 2:44 pm    Post subject: Reply with quote  Mark this post and the followings unread

Welcome back, Jan; and thanks for your attention to this issue.*
Steve
*and for the new update that got posted while I was typing the above! Now, that's quick!!!
Back to top
View user's profile Send private message
blue hell
Site Admin


Joined: Apr 03, 2004
Posts: 24079
Location: The Netherlands, Enschede
Audio files: 278
G2 patch files: 320

PostPosted: Sun Jun 05, 2016 2:55 pm    Post subject: Reply with quote  Mark this post and the followings unread

You're welcome Steve & thanks,

making a new release can be done pretty quick ... just drop the new exe in a new zip, change some version numbers in a script file, couple of small edits on the page html .. five minutes or so.

A new source code release is some more work, but didnt do that now .. want to fix some other issues too .. like the clicks on the looper are still not completely gone.

_________________
Jan
also .. could someone please turn down the thermostat a bit.
Posted Image, might have been reduced in size. Click Image to view fullscreen.
Back to top
View user's profile Send private message Visit poster's website
blue hell
Site Admin


Joined: Apr 03, 2004
Posts: 24079
Location: The Netherlands, Enschede
Audio files: 278
G2 patch files: 320

PostPosted: Sun Jun 05, 2016 3:27 pm    Post subject: Reply with quote  Mark this post and the followings unread

Then regarding how MIDI reception works. I spotted some questions about that in the posts above, let me try to explain.

Any incoming MIDI is assembled into proper messages, taking running status into account.

Then the message is sent into the patch where any special MIDI modules get a chance to pick it up according to the message content and the settings for that module.

Then when the message is a MIDI CC message and the receive channel for Wren matches the message's channel (or when Wren is set to receive in OMNI mode, meaning it processes all channels) a possibly matching CC to knob assignment is being processed. For this the whole CC range of 0 to 127 is mapped onto the actual number of knob positions available.

Regarding the bugs:

There are two internal values being used, the actual knob position and a 'dezippered' version of that. The dezippered version is used to avoid zipper noises when moving knobs in the patch editor. It is a low pass filtered version of the actual knob position.

When a midi message gets translated into a knob movement this dezippering should not took place however, as you'd want an immediate synth response on that .. this was implemented OK, but what I forgot was that the filtering process needs a shortcut too .. so the dezipper algorithm would set the internal value back to what it was - almost. Fixed that by setting both the value and the filtered value to the MIDI value.

Then some knobs need special processing, like for instance the range / mode selector for an LFO or a constant module. The special processing changes some controls on the module to reflect the range or mode changes. This should also happen when that range or mode control is automated - I had forgotten that.

The other two issues were related to MIDI sending. MIDI sends are initiated from the audio thread, and one thing you can not do from the audio thread is to make dynamic memory allocations .. yet the code I had did that .. resulting in 'occasional' crashes .. occasional of course being more often on fast send rates. And also it would try to send MIDI when there was no TCP port for it to send it on, which would crash Wren.

Anyways .. I think that the changes I've made solve all issues, please let me know if such was the case .. or not.

_________________
Jan
also .. could someone please turn down the thermostat a bit.
Posted Image, might have been reduced in size. Click Image to view fullscreen.
Back to top
View user's profile Send private message Visit poster's website
MusicMan11712



Joined: Aug 08, 2009
Posts: 1082
Location: Out scouting . . .

PostPosted: Sun Jun 05, 2016 3:39 pm    Post subject: Reply with quote  Mark this post and the followings unread

Thanks for the explanation--glad you understand what's going on there! Maybe when I find my brain I will try re-reading it and I am sure it will make sense.

Anyhow, I tested my quickie nanokontrol->miditangle->wren-> Osc: freq patch and it seems that is fixed. As well, the knob shows up in the global CC assignment table. Also, in Settings, setting the netmidi/miditangle to a specific channel makes the virtual knob/display respond to the desired CC on the specific channel only.

So I am guessing that for building patches, the global CC/knob assignments can be used and once the patch is near completion and the displayed value is no longer important, the MidiCCIn modules can be used.

Steve

Last edited by MusicMan11712 on Sun Jun 05, 2016 5:49 pm; edited 1 time in total
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic
Page 1 of 2 [31 Posts]
View unread posts
View new posts in the last week
Goto page: 1, 2 Next
Mark the topic unread :: View previous topic :: View next topic
 Forum index » Instruments and Equipment » WREN
Jump to:  

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Forum with support of Syndicator RSS
Powered by phpBB © 2001, 2005 phpBB Group
Copyright © 2003 through 2009 by electro-music.com - Conditions Of Use