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 » Clavia Nord Modular » Nord Modular G2 Discussion
Set controls in your patch using javascript
Post new topic   Reply to topic Moderators: Nord Modular Editors
Page 1 of 1 [8 Posts]
View unread posts
View new posts in the last week
Mark the topic unread :: View previous topic :: View next topic
Author Message
ian-s



Joined: Apr 01, 2004
Posts: 2669
Location: Auckland, New Zealand
Audio files: 42
G2 patch files: 626

PostPosted: Sat Feb 15, 2014 9:20 pm    Post subject: Set controls in your patch using javascript
Subject description: Another function for the online app.
Reply with quote  Mark this post and the followings unread

Another part of the "Multi-file to pch2 patch file utility" has been published.

You can now use javascript to set control values in your patch.

Open your textpad in the G2 editor and type (or paste) some javascript code, the code needs to start with //yo to be accepted.

I have attached an example to get you started. If you 'choose' this file, the system will prompt if you want the code executed. If you click ok, the code is executed against the pch2 object and a link is presented to the new pch2.

The sample shows how to set 4 sequencers to 2 cycles of a sine wave.

I don't know how useful this is going to be to non-javascript programmers.


SelfDemo.pch2
 Description:
Demo of self setting part of new online utility.

Download
 Filename:  SelfDemo.pch2
 Filesize:  2.43 KB
 Downloaded:  4177 Time(s)

Back to top
View user's profile Send private message
Antimon



Joined: Jan 18, 2005
Posts: 4145
Location: Sweden
Audio files: 371
G2 patch files: 100

PostPosted: Sun Feb 16, 2014 9:38 am    Post subject: Reply with quote  Mark this post and the followings unread

Shocked Not sure I understand this but it sounds awesome! Will try it out when I get the time for sure!
_________________
Antimon's Window
@soundcloud @Flattr home - you can't explain music
Back to top
View user's profile Send private message Visit poster's website
ian-s



Joined: Apr 01, 2004
Posts: 2669
Location: Auckland, New Zealand
Audio files: 42
G2 patch files: 626

PostPosted: Mon Feb 17, 2014 3:27 am    Post subject: Reply with quote  Mark this post and the followings unread

Antimon wrote:
Shocked Not sure I understand this but it sounds awesome! Will try it out when I get the time for sure!


It's a little difficult to explain in the limited space here so I have started a docs section for the utility. The file types list will get hyperlinks as I get around to documenting them.

Here is a direct link to the provisional documentation.

I should look at adding a snippets section for people to share useful bits of code.
Back to top
View user's profile Send private message
Electromagnetic Wave



Joined: Apr 28, 2013
Posts: 302
Location: Kebek
G2 patch files: 38

PostPosted: Mon Feb 17, 2014 4:23 am    Post subject: Reply with quote  Mark this post and the followings unread

It's the ultimate "patch adjuster" tool!
Back to top
View user's profile Send private message
xav



Joined: Mar 21, 2005
Posts: 164
Location: paris
Audio files: 8
G2 patch files: 7

PostPosted: Tue Feb 18, 2014 3:36 pm    Post subject: Reply with quote  Mark this post and the followings unread

I wish I could understand... that seems amazing!
Back to top
View user's profile Send private message
W.T.



Joined: Jul 11, 2004
Posts: 272
Location: The Netherlands
Audio files: 1
G2 patch files: 11

PostPosted: Tue Jan 06, 2015 8:18 am    Post subject: Reply with quote  Mark this post and the followings unread

Thanks for sharing! Let us pray
_________________
Clavia stuff that I use : expanded Nord rack & NM G2 engine.
Back to top
View user's profile Send private message
BobTheDog



Joined: Feb 28, 2005
Posts: 4044
Location: England
Audio files: 32
G2 patch files: 15

PostPosted: Sun Jan 25, 2015 11:57 am    Post subject: Reply with quote  Mark this post and the followings unread

Very clever as usual!

Works fine for me here in chrome, in Safari though it balks when trying to download the file:


screenshot_77.png
 Description:
 Filesize:  40.53 KB
 Viewed:  412 Time(s)
This image has been reduced to fit the page. Click on it to enlarge.

screenshot_77.png


Back to top
View user's profile Send private message
ian-s



Joined: Apr 01, 2004
Posts: 2669
Location: Auckland, New Zealand
Audio files: 42
G2 patch files: 626

PostPosted: Sun Jan 25, 2015 3:42 pm    Post subject: Reply with quote  Mark this post and the followings unread

Thanks Bob

Safari haven't made a PC browser for quite some time so it has fallen off my list of things to check.

Seems synthesizing a file download object using an array buffer is a known problem for Safari and there might be a work around I can try.

It doesn't work on IE, even IE11 for some reason as well. They are doing some major revamp of their browsers this year. Fingers crossed they will just start using webkit. Laughing
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic Moderators: Nord Modular Editors
Page 1 of 1 [8 Posts]
View unread posts
View new posts in the last week
Mark the topic unread :: View previous topic :: View next topic
 Forum index » Clavia Nord Modular » Nord Modular G2 Discussion
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