Notifications
Clear all

Updated Alternative Browser using Autohotkey for auditioning sounds or live playing


craigr68
(@craigr68)
Estimable Member Nerds
Joined: 2 years ago
Posts: 145
Topic starter  

This is my updated alternative browser (screenshots below) for auditioning sounds or live performance.  It basically allows me to display any of my Unify patches in a wide format browser which I view on a 48" flat screen.  If I left click on a patch, it quickly loads and becomes playable from my midi keyboard 1 (for right hand playing).  If I right click on a patch, it loads and becomes playable from midi keyboard 2 (for left hand playing).  So I can change patches from any of my 7,502 total patches instantaneously and I can switch to any library from the drop down list.  It works in conjunction with 2 instances of Unify loaded in Cakewalk - one instance for each keyboard.  Cakewalk and Unify can remain in the background as I'm choosing patches or can be in focus.  Screenshot3 shows it sending out a patch change to the DAW.  Screenshots show what it looks like.

It's an autohotkey script which makes use of "Changing patches with Midi" from the Unify manual, sendmidi from Github, 2 virtual midi ports, 2 midi controller keyboards, and 2 instances of Unify in Cakewalk.  The script also scans the library folder and creates all the text files needed in C:\CAKEWALK\Unify\MIDI Bank Files automatically.  Then there's a few other buttons at the top to open various things quickly.

eallan had requested a copy - so here it is.  I've altered it to be as user friendly as I could get it.  The zip file contains the script and an ini file.  The script file, being an .ahk file, is a text file.  One would need to open it in text editor and VERY CAREFULLY FOLLOW THE DIRECTIONS that are in the comment section at the top.  I TAKE NO RESPONSIBILITY FOR IT.  I've put a lot of effort into making it safe.  There are FileDelete commands in there for instance but this is just for the purpose of making it work.  It warns before it deletes and recreates all the files in "MIDI Bank Files".  One has to be careful in setting up folder locations, etc.

 

This topic was modified 6 months ago 4 times by craigr68

JeremyH liked
Quote
eallan
(@eallan)
Eminent Member
Joined: 2 years ago
Posts: 20
 

Hi craigr68 ,

Many thanks for sharing your script.

Where did you get SETBTNTXTCOLOR.AHK mentioned in the comments of UnifyPC-4ALL.AHK ?

Is it

https://github.com/Ixiko/AHK-libs-and-classes-collection/blob/master/libs/o-z/SetBtnTxtColor.ahk


ReplyQuote
craigr68
(@craigr68)
Estimable Member Nerds
Joined: 2 years ago
Posts: 145
Topic starter  

Hi eallan,

You should only need the 2 files - UnifyPC-4ALL.AHK and Flags.ini

The line in the directions should be changed from:

Unzip file into some folder - should have 3 files - UnifyPC-4ALL.AHK, SETBTNTXTCOLOR.AHK, and Flags.ini

To:

Unzip file into some folder - should have 2 files - UnifyPC-4ALL.AHK and Flags.ini

I caught that later.  I stripped out a couple things from the script I'm running because I figured it wouldn't pertain to others.  That for instance, had to do with a button I have that opens my OXY Editor for my M-Audio keyboard.  How's it going?  Getting anywhere with it?


ReplyQuote
craigr68
(@craigr68)
Estimable Member Nerds
Joined: 2 years ago
Posts: 145
Topic starter  

Also, the Edit Scr button is meant to be an easy way to open UnifyPC-4ALL.AHK script for editing or viewing.  What I have there won't work as is.  If you search for buttonEditScr: near bottom of script, you can put in there whatever you want.  It depends where you placed the script and what editor you use.


ReplyQuote
eallan
(@eallan)
Eminent Member
Joined: 2 years ago
Posts: 20
 

Hi craigr68 ,

Thanks for clarifying regards files.

Running a bit behind settings this up , as had to assist in making some xmas

decorations and so just back online now!!

What version of Cakewalk do you use?

(Notice you still use your DX7 - have one too and aftertouch still works ok.

Main Controller Keyboard is an Axiom 61)

 

 


ReplyQuote
craigr68
(@craigr68)
Estimable Member Nerds
Joined: 2 years ago
Posts: 145
Topic starter  

I'm running Cakewalk By Bandlab latest version they just came out with recently.  They refer to it as 2021.12 but CBB help says it's Version 2021.12 (Build 102, 64 bit).  What DAW do you use?  Yes, I've had a DX7IIFD with Grey Matter upgrade since the 80s.  I only use it as a Midi controller.  For what little I use DX type sounds, I'm ok with Dexed.  My aftertouch works and that's one of the great things about it.  Although my 4th octave is about 1/2 working - gotta push down harder.  My 2nd keyboard I just got in May is an M-Audio Oxygen Pro61 and it has aftertouch - great deal for $300 I thought.  How familiar are you with Autohotkey by the way?  Feel free to email me if you want.  


ReplyQuote
eallan
(@eallan)
Eminent Member
Joined: 2 years ago
Posts: 20
 

Hi craigr68 ,

Very much a beginner with Autohotkey!

DAW is mainly Reaper , but have older version of Bandlab Cakewalk.

Using Axiom61 as Controller Keyboard.

Have your AHK running now today and is has all the Unify Libraries listed ok

and the MIDI Bank Files created ok.

Tried in Cakewalk without success with both loopMIDI and then LoopBe.

Then tried directly with Unify Stand Alone with all midi ports enabled , but

no patch changes.

(Tried LoopBe names as 01. Internal MIDI and 1. Internal MIDI as Interfacename1)

Have got Unify with Bank/Program Change , Bank/Prog Error messages both Selected.

(Midi is getting into Unify from Loopbe allright - used MidiTrix to route Axiom61 to 1. Internal MIDI

and Unify plays notes ok.)

Using the latest versions of both Unify v1.7.2 and  SendMidi v1.0.15

Would appreciate your help in figuring out what has to be done to get patch changes to work.

This post was modified 6 months ago by eallan

ReplyQuote
craigr68
(@craigr68)
Estimable Member Nerds
Joined: 2 years ago
Posts: 145
Topic starter  

I've attached a new version where I made some fixes.  Don't forget to go thru the steps like changing folders again, etc.  I took out those numbers 1 thru 5 at top because they're just going to complicate the situation and be of minor use.  

Here's some ideas:

I discovered UP-IND wasn't correct, changed, and tested.  Also, I did away with the interface name InterfaceName1 and InterfaceName2.  It was causing more problems than it was worth.  Instead, search for 05. Internal MIDI and 07. Internal MIDI throughout the script, and replace them with  your first and second virtual port names.   There's only about 4 changes needed.  So presumably just change the 05. Internal MIDI to 01. Internal MIDI, and the 07 Internal MIDI to 02. Internal MIDI.

I can't get Standalone Unify to work with this script for some reason.  But it works fine in Cakewalk.  If I were you, I'd try using your DAW instead, especially since that's the only way to have 2 instances of Unify.  I don't know about the MidiTrix thing - maybe that's doing what's needed??  What I do is in my DAW, I merge controller midi port with the virtual midi port.  In Cakewalk By Bandlab, in the track you have an instance of Unify, you click on I for midi input.  Then you set the merging up with Manage Presets.  But first, in Preferences make sure all applicable midi ports are checked on.  You have to have your controller midi input as well as the virtual ports checked on.  That would be your Axiom, 01. Internal MIDI, and 02. Internal MIDI.  I don't know about your older Cakewalk version or if Reaper does that or not.

In Unify settings, check on Bank/Program Change and Bank/Prog error messages, or it won't respond.

 
This post was modified 6 months ago 7 times by craigr68

ReplyQuote
thsve
(@thsve)
Member
Joined: 2 years ago
Posts: 283
 

@craigr68 

Hi, 
I have studied your script out of sheer curiosity. You are referring to a folder with icons on line 45. I can't find that folder or icon anywhere in my system. It doesn't seem to be part of the AHK standard installation?

Win 10 and 11/Cubase Pro 12/Unify/Wavelab 8/Vienna Pro 7/Spectrasonics all/NI 13 Ultimate/Izotope MPS2/Serum/Cthulhu/Scaler 2.5/MusicLab guitar vsts/BIAB 2022/TouchOSC/Metagrid Pro etc


ReplyQuote
craigr68
(@craigr68)
Estimable Member Nerds
Joined: 2 years ago
Posts: 145
Topic starter  

@thsve 

Hi,

You are so right.  I now have included that file in this new zip.  It could have just been commented out.  When the script is opened, this tray icon will appear.  The biggest problem getting this to work for others is where I have file references that only exist on my computer.  And there's some superfluous code in my own version, such as the 1 thru 5 buttons at the top, which I have deleted from this version.  I've been working on this off and on for a while and never thought about making it universal prior to this.

Starting out, I was assuming anyone into autohotkey would fix whatever was found.  But it might be challenging to understand some of the things that I'm doing.  So then I decided it would be easier for me to fix probably.  I appreciate your feedback.  I actually thought about asking you to try it because you know programming.  The "buttonEditScr" lines need editing to whatever one needs.  I left Search in even though it's not working and requires another script - ignore for now.  I removed the OXYEdit button and associated code.  If you would, let me know anything else you find.  I would like to leave this working for others if they're interested.

This post was modified 6 months ago by craigr68

ReplyQuote
thsve
(@thsve)
Member
Joined: 2 years ago
Posts: 283
 

@craigr68 

Hi,

Thank’s. Your script is not for beginners 😎 . At the moment I’m into getting my TouchOSC script up to par. Shane has incorporated som patch selection commands that I will try to use, but so far I haven’t figured out how. Eventually I will incorporate AHK functionality into it to extend functionality. I will maybe use your script as input for this.

I don’t have Cakewalk, I’m using Cubase, and I don’t have sendmidi installed. Happy Holidays from a snowy and cold Stockholm, Sweden🎄.

Win 10 and 11/Cubase Pro 12/Unify/Wavelab 8/Vienna Pro 7/Spectrasonics all/NI 13 Ultimate/Izotope MPS2/Serum/Cthulhu/Scaler 2.5/MusicLab guitar vsts/BIAB 2022/TouchOSC/Metagrid Pro etc


ReplyQuote
eallan
(@eallan)
Eminent Member
Joined: 2 years ago
Posts: 20
 

Hi craigr68 ,

Thanks for updating your script. Will try it later this evening.

(Meant to mention about the icon - but forgot)

UPDATE: Still seemed not to work , don't know if this is co-incidence but reverted to

previous version of sendMidi and loaded a different Library and Patch Changing is working

with Airwave Melodic Techno , but not Columns 1+2(3+4 ok after pressing UP-IND)

Switched to Unify Standard Library and Columns 1 and 2 do not work but Columns 3 and above

do work and get Green popup message about Bank Changes(No popup on Columns 1+2)

Checked all the other Libraries and Columns 1+2 do not work(or Column 1 if the only one)

Synth1 , Hybrid 3 does not show any Patch names at. Could that be because they have sub-Folders?

Will be great if you can sort these things out

 

 

This post was modified 6 months ago by eallan

ReplyQuote
eallan
(@eallan)
Eminent Member
Joined: 2 years ago
Posts: 20
 

Hi craigr68 ,

Hope you had a nice Holiday break.

A further update for you - the post above refers to Window 7.

Tried on windows 10 today and discovered sendmidi was not working - it needed

msvcp140.dll and vcruntime140.dll which were copied from the Win7 PC.

Now everything is working(Unify Stand Alone used) including the first 2 Columns.


ReplyQuote
craigr68
(@craigr68)
Estimable Member Nerds
Joined: 2 years ago
Posts: 145
Topic starter  

@eallan 

Are all your libraries showing up now after UP-ALL?  Let me know if there are remaining issues.  It should work with standalone.  But it also should be able to work with 2 instances of Unify loaded in a DAW as indicated in the comments at top of script.  Perhaps you just wanted it with standalone though.  Interesting - I never run into any issues with dlls missing.


ReplyQuote
craigr68
(@craigr68)
Estimable Member Nerds
Joined: 2 years ago
Posts: 145
Topic starter  

@thsve 

I was reading the OSC section of the manual and the 1.7 enhancements.  Would like to know more about its capability with patch changing.  Although it says OSC can only work with Unify standalone.  Still, that might be interesting.  If I can be any help from an autohotkey standpoint, let me know.


ReplyQuote
thsve
(@thsve)
Member
Joined: 2 years ago
Posts: 283
 

@craigr68 

I'm still in the experimental stage, but have now got the patch load to work with OSC messages. I do not yet know if it is a practical way to use it, there are a lot of limitations as far as I can see. For example, it only works in the main window. Now I will try to integrate TouchOSC, AHK and Unify to see what is possible. The scripting capabilities (LUA) in TouchOSC are unfortunately quite limited. Thank you for the offer helping out with AHK, but for now I think I manage it myself.

Are you familiar with TouchOSC?

Win 10 and 11/Cubase Pro 12/Unify/Wavelab 8/Vienna Pro 7/Spectrasonics all/NI 13 Ultimate/Izotope MPS2/Serum/Cthulhu/Scaler 2.5/MusicLab guitar vsts/BIAB 2022/TouchOSC/Metagrid Pro etc


ReplyQuote
eallan
(@eallan)
Eminent Member
Joined: 2 years ago
Posts: 20
 

Hi @craigr68 ,

Can see sub folder patches ok on Windows 10 PC.

However , there is a problem with some 'User Library' patches , All 'Unify_Bonus+LivePatches' ,

and All 'Hybrid3' patches and All 'PlugInGuru ZEBRA2 Toxic Zebra' patches - All give the same Unify Error e.g.

"Library/patch Name error

Unable to match library/patch name "PlugInGuru ZEBRA2 Toxic Zebra" / "BPM Synth - Stalker.unify"

(Have done UP-ALL and UP-IND and Quick DB Build and Full DB build a few times and manually deleted

the txt files in MIDI Bank Files folder)

 


ReplyQuote
craigr68
(@craigr68)
Estimable Member Nerds
Joined: 2 years ago
Posts: 145
Topic starter  

@eallan

As you probably already know, the script reads the library file and creates the MIDI Bank text files with UP-ALL.  I would suspect something might be off there, either with the script or else something in a library messing it up.  I would look at the library folder in explorer and compare those patch file names with what the names are in the MIDI Bank text files.  There should be a one-to-one correlation.  The easiest way to figure out which MIDI Bank file to compare to a particular library, is to send a patch from that library.  The popup shows the bank number at the bottom for about 2 seconds.  Add one to that number and that should be the MIDI Bank text file for that library.  If a library has less than 128 patches, there will only be one text file for that library.  For every additional 128 patches in a library, you should have an additional text file.  For instance, my Unified Standard Library has 610 patches and the script creates 5 Midi Bank Files which are 63_1.txt thru 67_1.txt.  Once you make that correlation, examine the patches you're having problems with and check how they compare.  Look for a one-to-one correlation in the file names.  Maybe there's both a .upf and a .unify version of the same patch name.  Maybe there's another file in there that shouldn't be or perhaps even with some other file extension.  The script on purposely skips over .png (graphic) files for this reason.  Maybe somehow there's some other file in there that the script isn't expecting. Or maybe there's some special characters in the patch name causing a problem. 

In MIDI Bank text files, what's your highest bank number text file?  Mine goes up to 77_1.txt.  I could easily imagine someone having larger libraries and more of them, which I have not tested.  I would think that would not be an issue though.

This post was modified 6 months ago by craigr68

ReplyQuote
craigr68
(@craigr68)
Estimable Member Nerds
Joined: 2 years ago
Posts: 145
Topic starter  

@thsve 

Not very familiar with TouchOSC.  I've watched some YouTube videos about it and really don't see how it would benefit me.  But I'm interested in what folks are doing with tech in general.  I used your Patch Editor again recently, and it sure is a great time saving tool.  Thanks again.


ReplyQuote
craigr68
(@craigr68)
Estimable Member Nerds
Joined: 2 years ago
Posts: 145
Topic starter  

By the way, I modified the search script called UnifyPCSearch.ahk (attached below).  Similar to before, UnifyFolder, SendMidiFolder and virtual ports 05. Internal MIDI and 07. Internal MIDI need changing to whatever.  Just add it to your script folder.  It works like normal search.  Type something like violin into the field and select the Search button.  (Not return because return defaults to sending a patch).  It searches all of the libraries and opens a search result output.  Of course Unify itself does a great job searching.  But with this, you can left click to send it to virtual port one and right click for virtual port 2.  It's much simpler than the UnifyPC.ahk script.

This post was modified 6 months ago 2 times by craigr68

ReplyQuote
thsve
(@thsve)
Member
Joined: 2 years ago
Posts: 283
 

@craigr68 

I got a little inspired and started experimenting with an idea for a patch manager for UNIFY. I have long thought that I would try programming with JUCE and C ++, but it has been daunting. Now I make a new attempt with my rudimentary knowledge in C ++ and JUCE. I've only "played" a bit with C# before, JUCE / C ++ is much more difficult. Has posted a video showing a simple first experiment. The app communicates with UNIFY via OSC messages. Now I will dig further and see how far I get.

Short video: https://youtu.be/9QsNa01ealk

Win 10 and 11/Cubase Pro 12/Unify/Wavelab 8/Vienna Pro 7/Spectrasonics all/NI 13 Ultimate/Izotope MPS2/Serum/Cthulhu/Scaler 2.5/MusicLab guitar vsts/BIAB 2022/TouchOSC/Metagrid Pro etc


getdunne liked
ReplyQuote
craigr68
(@craigr68)
Estimable Member Nerds
Joined: 2 years ago
Posts: 145
Topic starter  

@thsve 

Wow, that's pretty cool.  Would be interested to know how you did that.  Have any good links on how OSC can access the Unify database and send Prog changes?  Are you using Microsoft Visual C?  I started refreshing my mostly forgotten knowledge of C++ by going thru CodeBeauty's youtube tutorials. ( https://www.youtube.com/c/CodeBeauty/videos).   And I was hoping to get into the JUCE tutorials someday after that, but I'm sidetracked on other things right now.  And it's probably going to be a steep climb. 

This post was modified 6 months ago 2 times by craigr68

ReplyQuote
getdunne
(@getdunne)
Member Admin
Joined: 3 years ago
Posts: 3502
 

@craigr68

Unify's OSC support does not yet include reading the patch database. However, it's just a Sqlite3 database, and there are C++ code libraries such as sqlite-cpp to read it directly from C++ code.

I hope to post some example code to GitHub myself, once I have something sufficiently cleaned-up to serve as a starting point.

PS: unfortunately, yes: C++/JUCE is a very steep learning-curve to climb, but if you can skip actual audio processing (which requires multi-threading) and concentrate mainly on GUI and OSC coding, it's not as bad.


ReplyQuote
craigr68
(@craigr68)
Estimable Member Nerds
Joined: 2 years ago
Posts: 145
Topic starter  

Hi Shane.  That's some helpful info and I'll look forward to your examples. 


ReplyQuote
thsve
(@thsve)
Member
Joined: 2 years ago
Posts: 283
 

@craigr68
In this early ”proof-of-concept” stage I just exported a portion of the database (see Shanes answer above) to a csv file. The patches in the db has a ”id” (rownumber) that is used when sending the the OSC message.

I populate the two Comboboxes (libraries and patches) from the exported file. My plan is to read the db directly.

When a patch is selected the OSC Message like this is sent: 

if (!sender.send(”/load”, (float)patchMenu.getSelectedId()))

I will probably try to swap the ComboBox controls to TableListboxes later on.

As Shane writes, it is a steep learning curve. I’m really struggling with C++, much more complicated than C#. I still have major problems understanding the structure of the code (where to put things). Nothing seems logical or straight forward 🤗. I’m using the JUCE tutorials and Google and take it step by step.

Win 10 and 11/Cubase Pro 12/Unify/Wavelab 8/Vienna Pro 7/Spectrasonics all/NI 13 Ultimate/Izotope MPS2/Serum/Cthulhu/Scaler 2.5/MusicLab guitar vsts/BIAB 2022/TouchOSC/Metagrid Pro etc


ReplyQuote
getdunne
(@getdunne)
Member Admin
Joined: 3 years ago
Posts: 3502
 
Posted by: @thsve

As Shane writes, it is a steep learning curve. I’m really struggling with C++, much more complicated than C#. I still have major problems understanding the structure of the code (where to put things). Nothing seems logical or straight forward 🤗. I’m using the JUCE tutorials and Google and take it step by step.

Learn C++/JUCE if you want, but the whole point of adding OSC support to Unify was to allow you to avoid this, and use C# or whatever language you want, to build remote-control apps for Unify. Because OSC works across networks, these remote-control apps don't even have to run on the same computer as Unify; they could run on an iPad or a Raspberry Pi.


ReplyQuote
thsve
(@thsve)
Member
Joined: 2 years ago
Posts: 283
 

@getdunne 

I'm aware of that, but I see it as a ”suitable” project to learn C ++ / JUCE 😀 .

Win 10 and 11/Cubase Pro 12/Unify/Wavelab 8/Vienna Pro 7/Spectrasonics all/NI 13 Ultimate/Izotope MPS2/Serum/Cthulhu/Scaler 2.5/MusicLab guitar vsts/BIAB 2022/TouchOSC/Metagrid Pro etc


getdunne liked
ReplyQuote
craigr68
(@craigr68)
Estimable Member Nerds
Joined: 2 years ago
Posts: 145
Topic starter  

@getdunne

The way I'm doing things now requires two instances of Unify.  It seems to me, and as you indicate in the manual, OSC will only work with standalone, which obviously is one instance.  Am I right that OSC could never work with a DAW with 2 instances because a DAW can only work with Midi input and OSC is running with network protocol UDP.  Is that correct?

I should clarify.  I usually use multiple instances of Unify in a DAW, but for patch auditioning I just use 2 (left hand Midi controller kybd and a right hand Midi controller kybd).


ReplyQuote
getdunne
(@getdunne)
Member Admin
Joined: 3 years ago
Posts: 3502
 

@craigr68

There is no fundamental reason why OSC cannot work for plug-in versions of Unify. I have done some experiments with this. It's only necessary to ensure that each Unify instance listens on a different UDP port, and then (the hard part) provide a straightforward way for remote-control or scripting apps or plug-ins to determine which port to send to.

This problem is not insurmountable, but I need to know the use-cases which would justify the amount of effort required.


ReplyQuote
Share: