This forum is for Tips and Tricks. Please do not post any questions in this forum. It is only for information.
54 postsPage 3 of 3
1, 2, 3
Is it possible through JS or macro to insert Program Change events into tracks somehow?

5,1 MacPro 3.46ghzx12 128gb ram, OSX 10.14, S1, LogicPro, Cubase10, DP9, Reaper, VEP7, VSL, too many plugins to list
User avatar
by Lawrence on Sat Jun 08, 2019 4:39 am
Yes, look at those functions I posted. That works for any selected Instrument Track assigned to an External Instrument.

Code: Select all
setProgram (bank [integer], program [integer])
P.S. Look in my signature below, there's an External Instruments package download link there. It runs from the main Studio One menu.
User avatar
by roblof on Sat Jun 08, 2019 5:22 am
Is it possible to control other hardware like controllers and audio interfaces this way? Given there already is some way to talk to a device through midi or other means.

Can you subscribe to events?

Behringer Wing, iMac late 2015, Behringer X-Touch, X-Touch ONE, M-Air mr18, X-Air xr18, x32 with Dante/aes67, x32-rack with Dante/aes67, s16 and sd16 stageboxes, p16 monitor system, TurboSound iQ-speakers, Waves x-wsg with SoundGrid server, Motör 61, BCR-2000, StudioLive 24, FirePod 10, Apogee Ensemble, Alesis HD24, Studio One Pro v4, Notion 6, NI Komplete 11 Ultimate, Halion 6, Nuendo 10, Ableton Live 8 Suite, Reaper 4, misc Line6 gear/software, True Temperament Frets on basses and guitars, Korg Kronos, Roland vk-7, Behringer Deepmind 12, Behringer Neutron, Yamaha 02r.....
User avatar
by Lawrence on Sat Jun 08, 2019 5:39 am
I'm sure it is as some External Devices like MCU and simiar have JS code files behind them. Actually doing it is another different conversation. :(

It's probably not a good idea to be too ambitious with scripts. It's better to fill smaller personal gaps, not jump into the deep end trying to do some really complex things.
User avatar
by roblof on Sat Jun 08, 2019 6:28 am
I’m too old to stay in the shallow end of the pool 8-)

I was thinking of controlling things like 3’rd party preamp gain, as already possible with presonus hardware integration.

Lawrence wroteI'm sure it is as some External Devices like MCU and simiar have JS code files behind them. Actually doing it is another different conversation. :(

It's probably not a good idea to be too ambitious with scripts. It's better to fill smaller personal gaps, not jump into the deep end trying to do some really complex things.

Behringer Wing, iMac late 2015, Behringer X-Touch, X-Touch ONE, M-Air mr18, X-Air xr18, x32 with Dante/aes67, x32-rack with Dante/aes67, s16 and sd16 stageboxes, p16 monitor system, TurboSound iQ-speakers, Waves x-wsg with SoundGrid server, Motör 61, BCR-2000, StudioLive 24, FirePod 10, Apogee Ensemble, Alesis HD24, Studio One Pro v4, Notion 6, NI Komplete 11 Ultimate, Halion 6, Nuendo 10, Ableton Live 8 Suite, Reaper 4, misc Line6 gear/software, True Temperament Frets on basses and guitars, Korg Kronos, Roland vk-7, Behringer Deepmind 12, Behringer Neutron, Yamaha 02r.....
User avatar
by Lawrence on Sat Jun 08, 2019 6:32 am
I hear you. :) That end of the pool is probably pretty deep and also most likely unreachable without an API doc outlining those things.

Nothing wrong with thinking big but you also have to be realistic. That's not gonna happen without a hardware controller API from them and maybe also documentation from the specific hardware manufacturer.

Study any JS files you find in the \Studio One 4\devices folder, maybe that will give some pointers.

You might wanna also brew a BIG pot of coffee. :mrgreen:
User avatar
by Dewdman42 on Sun Jun 09, 2019 1:18 pm
Lawrence wroteYes, look at those functions I posted. That works for any selected Instrument Track assigned to an External Instrument.

Code: Select all
setProgram (bank [integer], program [integer])
P.S. Look in my signature below, there's an External Instruments package download link there. It runs from the main Studio One menu.


What does that external instrument package do and how do i go about installing it to check it out?

So regarding the program change, thanks for pointing that out. Any way to save ProgramChanges to another track other then the currently selected one?

Well a more important question is, can we create noteOn/NoteOff Events on tracks using JS somehow?

Is there any way to see PC messages by patch "name" rather then number in S1?

5,1 MacPro 3.46ghzx12 128gb ram, OSX 10.14, S1, LogicPro, Cubase10, DP9, Reaper, VEP7, VSL, too many plugins to list
User avatar
by Lawrence on Mon Jun 10, 2019 5:46 am
Put the package file in the application \scripts folder and restart Studio One. It will list from the Studio One menu as External Instruments. Use the Instruments menu > Edit Instruments to go into the directory where the Cubase patch scripts are and copy anything you want to use to the root directory and it will list in it. There's about 200 Cubase patch script files that install with it. Some of them may be badly formatted as I didn't test them all.

I also added a new function to functions.js... loadCubasePatchFile() … which reads those files and pushes the relevant data into an array, in case someone wants to do something different.
User avatar
by Dewdman42 on Mon Jun 10, 2019 10:40 am
Thanks will check that out.

Is that a "no its not possible" on the question about adding noteOn/noteOff events to a track with JS?

5,1 MacPro 3.46ghzx12 128gb ram, OSX 10.14, S1, LogicPro, Cubase10, DP9, Reaper, VEP7, VSL, too many plugins to list
User avatar
by Lawrence on Mon Jun 10, 2019 3:10 pm
Sure, it's possible. I don't know how since I never actually tried it, but it's possible as "Events" like MIDI notes in code are just objects, so sure, there's certainly a way to create any MIDI object like that from scratch if you know how.

Not sure Studio One uses on/off events directly, but a note event would trigger both.
User avatar
by Dewdman42 on Mon Jun 10, 2019 4:02 pm
Any idea how we might be able to figure that out?

5,1 MacPro 3.46ghzx12 128gb ram, OSX 10.14, S1, LogicPro, Cubase10, DP9, Reaper, VEP7, VSL, too many plugins to list
User avatar
by Lawrence on Mon Jun 10, 2019 4:09 pm
Nope, sorry.
User avatar
by Dewdman42 on Wed Jun 12, 2019 3:22 pm
bummer.

Riddle me this. Do you think there is a way with JS to detect program change events on the program change lane to determine their value and maybe display the "current" program on the macrobar somehow by name? In other words you have your external instrument package for specifying a PC by name, which can insert those onto the program change lane...but I'd like to be able to view the names somehow of what is on the track. Any idea if we know how to accomplish that now? As near as I can see, the program change lane will a line/curve with nodes, but the only way to see the value is to hover the mouse over the nodes...and the value is most likely shown as a number if I recall. Plus I discovered the other day its based on a scale up to 100, rather then 128, so has to be converted somewhere?

5,1 MacPro 3.46ghzx12 128gb ram, OSX 10.14, S1, LogicPro, Cubase10, DP9, Reaper, VEP7, VSL, too many plugins to list
User avatar
by johnnythunder on Mon Sep 07, 2020 8:54 am
Lawrence wrotehttps://github.com/ExpressMix/studioone_functions


This thread has been amazing :reading: . I'm a new comer to studio one (5), but this topic of reverse engineering and creating custom scripts/macros honestly sounds fascinating. I'm a Sr. Software Engineer by trade and do a lot of JS programming. Is there any way I could get some more tips on this? Or even just that studioone_functions.js file I could review? I'd greatly appreciate it and be willing to share any use scripts!

54 postsPage 3 of 3
1, 2, 3

Who is online

Users browsing this forum: No registered users and 2 guests