Creating a VL library from a .NET dll

Hi vvvvolks,

I am trying again to get into the VL world. I have a nice use-case, where I want to create a VL library for receiving data form a LSL (LabStreamingLayer) servers. I am using this to fetch EEG LSL streams form a MUSE2016 EEG headband, send by the opensource

Since it is a .NET library ( binding to liblsl c++ I think the best is to have a VL.LSL thingy…oh, dear! :-)

So, are there some tutorials on reactive programming and creating a VL.nuget (library, class)…whatever

It is a very popular EEG headband and the official SDK is deprecated, so there is the BlueMuse project, which is using the industry standard LSL as a protocol for communication.

any help is appreciated,

regards and thanks!
stay safe & sound

also interesting:


you can also learn from existing libraries on github.

let us know what’s missing in the documentation.

Thank you!!!

I am wondering what is the best practice to store data from a mutableArray to a spread in a pad?

best regards

Why I can not create dynamically a spread stored in a pad? What am I doing wrong?

Perhaps I have to create a class?
And put all that in the constructor (Create method) some more basic guidelines for importing a .NET assembly would be amazing ;) when one needs to pull data async ;)


You can do everything on the AsyncTask and hand the end result over to the main thread. you should do as much as possible in the task in order to remove work from the main thread.

to create a spread from a MutableArray you can use the FromSequence [Spread] node.

regarding this:

you somehow managed to assign the node to the Create operation of the loop slice. right-click it and clear the assignment.

then also move all that into the AsyncTask. the HoldLatest node will than store the result for you (same as the cache region) until you trigger the AsyncTask again and it produces a new result.

I am afraid I do not understand it :-(

I started all from scratch and gave up on generic VL lib, so I have created a class(Muse), where in the “Create” I scan for all the available streams (blocking for a few sec…, whatever) and then I set some pads

I plan to use the pads later to pull data async and process it (not there yet, unfortunately )

However…but as I look how it goes as of now for me with VL, perhaps I go for the plain old c# plugin + threads and the good old VVVV…

will give a try to VL again after some time… it is really frustrating

Are “pads” class properties (class variables with getters and setters?) then what are the input/outputs then?

This all is very confusing…

Is the “create” operation a constructor?

What about the update? Is it running based on the Main Loop (which mainloop? Now one can have many)!
It is strange, but I do not get the results from the AsyncTask …


this will create the Muse class in every frame, i’m not sure if that is what you want…

however, you seem to miss a few basics, especially how operations (methods) are used. and you can’t expect to learn a new programming language in 2 hours.

yes, they are class variables. this thread gives an easy example with code comparison:


the Update of the application patch (main patch of the document) gets called by the runtime main loop, if you place things into it, they will be called by the application patch… and so on… like a call hierarchy in most other programming languages.

it is a bang, you seem to have a toggle connected, which restarts the task in every frame.

which documentation did you read/watch so far and what is missing for you?

I watched all the tutorials, after a very helpful plug from motzi, I have now a little bit better understanding…still much to discover.

and yes, I really do not want to create the instance every frame :-) will post soon my next iteration,
will try not to give up

Thank you for the support!


I got it working!!! Thanks to motzi’s insights and your feedback and help!

I think what I am missing is:

  1. very clear description of the basic concepts, such as pads/input/outputs and IO boxes
  2. a quick and easy edit of the settings
  3. a basic tutorial how to import a .net assembly and use asyncTasks / asyncLoop
  4. remove link with the right-mouse button ;)



This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.