-
Hello again! I am working on my OB-8 Tauntek Panel and have run into some problems testing. The panel itself is working fine and the functionalities of the controls are as they should be, but when automating parameters I fear the messages get to dense and overload the modest Z-80 processor. I am also running into this issue on the much more complicated Jupiter 8 panel I have been working on, but since the OB-8 panel is all CC controls I figured this would not be an issue. Unfortunately, when automating some parameters and then sending note information, several stuck notes result. Also Tauntek did not seem to implement the basic midi panic control on CC 123 or any other so it requires an annoying hard reset. Is there a way to slow down or thin out modulators simply before sending them from controller? Could the issue be that the DAW is sending midi notes and the panel is sending CC data and they are getting mushed up somehow? Midi snapshot seems to be working well but I must fix this issue before I move on to patch saving with json. Here's an image of the interface in its current state |
Beta Was this translation helpful? Give feedback.
Replies: 9 comments 40 replies
-
This was discussed in this thread. Some sample code is there, but you'll likely need to adapt it. |
Beta Was this translation helpful? Give feedback.
-
I have the same issue with a Panel for Ensoniq that I am working on. Every message needs at least 200ms so going from 0 to 25 with a slider sends all the sysex lines from 0 to 25. You could go the route that Godlike-Productions suggests. For me that is not even what I want. I don't want people scrolling through the values simply because 'the less sysex this machine needs to process, the better'. The way I have set it up now is that you set a value, either with the slider or value input and a double click (on slider) or enter (on value input) confirms and sends the code. My panel will not be of any use if people want to automate parameters. The hardware unit was not build to handle that anyway. |
Beta Was this translation helpful? Give feedback.
-
the global midi delay works but is useless because it only delays the messages and the delays add up and the whole thing is a very unmusical solution. So before adding the timer, I am starting with just writing out the method to send a midi CC in LUA and am having trouble retrieving the CC number from the modulator. Also is there a way to generalize this method so that I put it in the "call when modulator value changes" without having to write a method for each modulator? How can I call the CC value correctly? ccValue = panel:getModulatorByName("LFOfrq-4"):getProperty("midiMessageCtrlrNumber") is not working right and there is nowhere I can find syntax or reference to help me figure this out. Is there a document or link I am missing that would help me make sense of some of these calls? ` ccValue = panel:getModulatorByName("LFOfrq-4"):getProperty("midiMessageCtrlrNumber") CC = "B0" panel:sendMidiMessageNow(CtrlrMidiMessage(CC..midiMsg..midiValue..midiChannel)) end after I get this method working I can create timerCallback section a global midi resolution variable would be a super useful global for these older synths (as was stated in the other thread) |
Beta Was this translation helpful? Give feedback.
-
I dont understand what a timer callback is I suppose. I thought I would figure out this CC method and then build the timer section after. Is this not the right approach? So each modulator will need a method called when its value changes? Ugh thats a lot of work. Yes I do need the delay so I need the code to send a CC and a timer to sample it. Is there some example I can look at? Trying to learn this scripting syntax by only looking at examples makes it really hard. |
Beta Was this translation helpful? Give feedback.
-
That's amazing work and it works well @damiensellier. I added the necessary code for @puffer3 to run this function globally on different controls. You only need this one function: The lua CC code is: local channelOut = panel:getProperty("panelMidiOutputChannelDevice") local statusByte = 0xb0 + (channelOut - 1) -- use this code for dynamic channel changes local myNumber = _G[activatedCtrl]:getMidiMessage():getPropertyInt("midiMessageCtrlrNumber") local mess = CtrlrMidiMessage({statusByte, myNumber, modValue}) panel:sendMidiMessageNow(mess)
CcValueSend = function(--[[ CtrlrModulator --]] mod, --[[ number --]] value, --[[ number --]] source) --console("sent modValue = "..(value)) modValue = value activatedCtrl=L(mod:getName()) end Note that in the init (when panel loads constructor) function, we set global lua variables to lfo=panel:getModulatorByName("lfo") resonance=panel:getModulatorByName("resonance") So when a control named resonance or lfo is activated, they assign their names to the global variable activatedCtrl which the Timer uses to build the cc message. I tested it with graphics and it still seems to work. I think this code could work well with the Jupiter 8 Encore panel too! |
Beta Was this translation helpful? Give feedback.
-
I think the code from @damiensellier works fine without the onMouseDown event. Here I have moved the timer trigger into the cCvalueSend = function(--[[ CtrlrModulator --]] mod --[[ number --]], value --[[ number --]], source) --console("sent modValue = "..(value)) modValue = value activatedCtrl = L(mod:getName()) sendCcMessageAllow = true timer:setCallback(1, timerCallback) timer:startTimer(1, 1000) -- will send modValue every 1000ms on click until modValue stalls end |
Beta Was this translation helpful? Give feedback.
-
My panel is for an OB8 with tauntek MIDI installed not an Ensonic just fyi. The CC's are causing stuck notes when sequencing a note pattern with added automation to parameters. I am going to try a few short (5 and 20ms) global panel delay tests and see if that alleviates the problem on the OB8. I also emailed the Tauntek man himself who made this MIDI kit and asked about a ceiling that the Z80 can handle. Working on a table of modulator values rn. One suspicion I had was that the DAW was sending midi notes and the panel CC information and maybe they are getting jumbled up? Is this possible? Should I be routing midi messages from the daw into the Ctrlr panel and then out? I was there late at night but I do think i tried both ways. |
Beta Was this translation helpful? Give feedback.
-
ok here is a method that creates a table that collects all modulators in the order they appear in the above document, and prints them at the end. I renamed the modulators to be closer to the document so things would be easier. Next I have to make a timer that hopefully wont crash the computer. ` function collectModulators() PatchDataTable = {} portSpeed = panel:getModulatorByName("portSpeed"):getModulatorValue() --create string concatenated from tabel --print Patch Data end ` |
Beta Was this translation helpful? Give feedback.
-
This is the complete example saving as json and loading back to json: (1) SAVEpatchDataTable={ "portSpeed", "progVolume" } myMethod = function(--[[ CtrlrModulator --]] mod --[[ number --]], value --[[ number --]], source) local t = {} for _, v in ipairs(patchDataTable) do t[v] = panel:getModulatorByName(v):getModulatorValue() end json_str = json.encode(t) console(json_str) --{"portSpeed":48,"progVolume":99} -- for example end
(2) LOADOnce you've loaded the json string panel:setPropertyInt("panelMidiPauseOut",0) -- !PAUSE SENDING MIDI for k, v in pairs(obj) do panel:getModulatorByName(k):setModulatorValue(v,false,true,false) end panel:setPropertyInt("panelMidiPauseOut",1) -- !ALLOW SENDING MIDI |
Beta Was this translation helpful? Give feedback.
This is the complete example saving as json and loading back to json:
EDIT 3/26/2022 v 4-- changed bug in code
EDIT 3/26/2022 v 5-- updated patchTableData to indexed table
(1) SAVE
fileToWrite:replaceWithText(json_str, true, true)
(2) LOAD
Once you've loaded the json string
{"portSpeed":48,"progVolum…