07-21-2021 10:38 AM - edited 07-21-2021 10:45 AM
Hello all,
If anyone is familiar with using the STG 4008 from Multichannel Systems with LabVIEW: does the output from LabVIEW have to be a digital output and does there need to be a specific calling function for the STG device, as there are for using STG with Matlab and C++?
07-21-2021 11:13 AM
@hame2 wrote:
Hello all,
If anyone is familiar with using the STG 4008 from Multichannel Systems with LabVIEW: does the output from LabVIEW have to be a digital output and does there need to be a specific calling function for the STG device, as there are for using STG with Matlab and C++?
Well on their website they say there's DLL and documentation - For programming custom applications available...
But I could not find either the DLL or anything in their manual about remote programming beyond saving and loading an ASCII "stimulus" file through their supplied software.
I think you need to contact Multichannel Systems directly
07-21-2021 02:15 PM
Thank you for your speedy response! I emailed their support email and am awaiting their response. Since the dlls in the link they provide only have code for Matlab, Python, etc. I just assumed there wasn't one for Labview, but I'll make sure with the email.
07-21-2021 02:30 PM
Well I am no expert but I believe if you have the DLL and the documentation you should be able to use it.
It's been a long time but I have used the "Call Library Function" with a DLL that was not written specifically for LabVEW before.
There's a few hoops you have to jump through and make a "VI Wrapper" for the DLL.
07-22-2021 03:24 PM
Just a little update: I used the DLL, though instead of the "Call Library Function" I used the .NET nodes as the dll was .net based. I have attached an image of how I am calling the device with the .net nodes, the isConnected is connected to a boolean to show if the device is connected.
However, the device is still not properly connecting to the Labview code: the boolean remains false and the stimulation is not triggering with the STG device.
I have emailed Multichannel System support with this but they are based in Germany so their response will probably come in about ten hours.
07-22-2021 03:27 PM - edited 07-22-2021 03:28 PM
I apologize for the quality of the attached picture in the previous post.
07-23-2021 12:28 PM
I am not getting any errors either by the way, which is why I don't see what the problem is in my program's connection to the STG device.
07-28-2021 02:29 PM
Hello all,
I have somewhat solved my problems, and am going to explain what I did in case anyone else has similar issues:
I actually had made a rookie mistake and never installed the MC_Stimulus software that was needed to install the driver for the STG (I had installed it in my own laptop but not in the actual computer I was using lol). The program in LabVIEW should look like the code in the images I had posted, using the DLL to initialize the STG. Other nodes can be invoked as well for anyone's own purposes, personally the NumberofDevices is a good node if there are connection issues. There is also a GetErrorText node under CMcsUsbNet that outputs a string with the error. This is super useful.
As of right now, my LabVIEW does register that the STG is connected, but there is an error in the GetErrorText that reads "Device is Locked". My labview program is also crashing after every run so I am currently working through these problems.