Quantcast
Channel: Measurement Studio for VB6 topics
Viewing all 323 articles
Browse latest View live

cwas.ocx

$
0
0

Hi there,

can anybody tell me where i can download cwas.ocx? i have an application written in VB6 that uses some of NI activex and when i load the project in VB several pop up messages appear telling that ocx are missing... 

is this part of a downloadable package or available singularly ?:smileysad:

 

Thanks in advance!


niswitch_64.dll not found

$
0
0

Hi All,

 I have just purchased a PXI chasis with a PXI-2530B switch card, and a PXIe-8360 ingterface card. This is connected to a windows 7 64 bit pc running VB6.0

 

I have used NIswitch soft panel and that appears to work and communicate with the PXI systemm ok. However when i run any of the VB6.0 examples it reports a file not found NISwitch_64.dll - the reference exists in the project and the object browser shows all the function and variables available within NISwitch_64.dll but the program will not run. and the file exists where expected. 

Out of desperation i have tried placing the dll in the syswow64 folder and the system32 folder to see if it is a path issue, no joy.

 

Does anyone have any suggestions ?

 

Thanks

 

Justin

 

 

Some problems with 3 counters on PCI 6601

$
0
0

Good afternoon,

 

after a lot of time i'm here yet.

 

The problem with the PCI 6601 aren't finished in sense that i have tried a lot of solution but my sistem crashed after some acquisition.

 

The code that  had write on Visual Basic 6 are :

 

'Inizializzo la scheda PCI-6601
Public Sub init_6601(NumSens As Integer)

Dim edge As DAQmxEdge1
    
On Error GoTo ErrorHandler

    MyChannel(NumSens) = "My Channel" & NumSens            'Definisce il nome per il canale (optional)
    
    'Creo i tre task che servono per il funzionamento del programma
    DAQmxErrChk DAQmxCreateTask("", taskHandle(NumSens))
       
    'Questa funzione serve a creare il canale dalla quale poi viene effettuata la misura
    
    If (NumSens = 0) Then
        DAQmxErrChk DAQmxCreateCIPulseWidthChan(taskHandle(NumSens), "Dev1/ctr1", MyChannel(NumSens), 0.00001, _
        0.0009, DAQmx_Val_TimeUnits3_Seconds, DAQmx_Val_Edge1_Rising, "") ' DAQmx_Val_TimeUnits3_Ticks, DAQmx_Val_Edge1_Rising, "")
    ElseIf (NumSens = 1) Then
        DAQmxErrChk DAQmxCreateCIPulseWidthChan(taskHandle(NumSens), "Dev1/ctr2", MyChannel(NumSens), 0.00001, _
        0.0009, DAQmx_Val_TimeUnits3_Ticks, DAQmx_Val_Edge1_Rising, "") 'DAQmx_Val_TimeUnits3_Seconds, DAQmx_Val_Edge1_Rising, "")
    Else
        DAQmxErrChk DAQmxCreateCIPulseWidthChan(taskHandle(NumSens), "Dev1/ctr3", MyChannel(NumSens), 0.00001, _
        0.0009, DAQmx_Val_TimeUnits3_Seconds, DAQmx_Val_Edge1_Rising, "")
    End If
    
    DAQmxErrChk DAQmxSetReadReadAllAvailSamp(taskHandle(NumSens), False)
    
    'Con questa funzione si sincronizza il timebase della scheda con il segnale da leggere
    DAQmxErrChk DAQmxSetCIPulseWidthDigSyncEnable(taskHandle(NumSens), MyChannel(NumSens), True)
    
    'DAQmxErrChk DAQmxSetReadOverWrite(taskHandle(NumSens), DAQmx_Val_OverwriteMode1_OverwriteUnreadSamps)
    
    'DAQmxErrChk DAQmxCfgSampClkTiming(taskHandle(NumSens), "", 100000, DAQmx_Val_Rising, DAQmx_Val_AcquisitionType_ContSamps, 10000)
    
    'provare queste due funzioni per aspettare che il campione sia realmente disponibile.
    'La seconda èdovrebbe essere quella che da il migliore compromesso tra uso CPU e velocità.
    'DAQmxErrChk DAQmxSetReadWaitMode(taskHandle(NumSens), DAQmx_Val_WaitMode_WaitForInterrupt)
    'DAQmxErrChk DAQmxSetReadWaitMode(taskHandle(NumSens), DAQmx_Val_WaitMode_Yield)
    
    'Setta il numero di campioni da acquisire ogni volta che va in lettura e
    'il modo di lettura. Si è impostato "contsamps" per avere la lettura continua
    'La dimensione del buffer è determinata da quel 10000 che va messo così secondo le specifiche del daqmx
    DAQmxErrChk DAQmxCfgImplicitTiming(taskHandle(NumSens), DAQmx_Val_AcquisitionType_ContSamps, 10000) 'DAQmx_Val_AcquisitionType_ContSamps
    
    'La scheda NI PCI 6601 ha soltanto un canale per il DMA (Direct Memory Access) quindi non riesco a leggere
    'contemporaneamente tre task per volta. Quindi devo attivare un meccanismo diverso per la lettura
    'basato sugli interrupt, ogni volta che ho una lettura automaticamente leggo il dato
    DAQmxErrChk DAQmxSetCIDataXferMech(taskHandle(NumSens), MyChannel(NumSens), DAQmx_Val_DataTransferMechanism_Interrupts)
    
    'La funzione di seguito serve semplicemente per leggere il campione più recente generato
    DAQmxErrChk DAQmxSetReadRelativeTo(taskHandle(NumSens), DAQmx_Val_ReadRelativeTo_MostRecentSamp)
   
    'La seguente funzione è complementare ad una utilizzata nell'inizializzazione e serve per impostare la lettura
    'sull'ultimo campione generato
    DAQmxErrChk DAQmxSetReadOffset(taskHandle(NumSens), -1)
    
    DAQmxStartTask taskHandle(NumSens)
    taskIsRunning(NumSens) = True

Exit Sub

ErrorHandler:
    For i = 0 To 2
        If taskIsRunning(i) = True Then
            DAQmxStopTask taskHandle(i)
            DAQmxClearTask taskHandle(i)
            taskIsRunning(i) = False
        End If
    Next i
    MsgBox "Error: " & Err.number & " " & Err.Description, , "Error"

End Sub

For the reading i use :

 

        DAQmxErrChk DAQmxReadCounterF64(taskHandle(NumSens), -1, 0.5, temp(NumSens, 0), 10000, ReadSamp(NumSens), ByVal &O0)

Well, my problem are very simple, I want an continuos acquisition on three channel and the input signal's frequency that i have to measure is 1 kHz .

 

when i try to keep 2 channel after some cycles appears the error -200141 (buffer overwriting). Why?

 

The read function is called some times every ms and evry time keep out an different value, even if that are impossible because the input signal is at 1 kHz, and why the buffer fill up? What is wrong in my code?

 

Thanks in advance for your help

 

Have a nice day!!

 

Igor Piero Prato

Some problems with 3 counters on PCI 6601

$
0
0

Good afternoon,

 

after a lot of time i'm here yet.

 

The problem with the PCI 6601 aren't finished in sense that i have tried a lot of solution but my sistem crashed after some acquisition.

 

The code that  had write on Visual Basic 6 are :

 

'Inizializzo la scheda PCI-6601
Public Sub init_6601(NumSens As Integer)

Dim edge As DAQmxEdge1
    
On Error GoTo ErrorHandler

    MyChannel(NumSens) = "My Channel" & NumSens            'Definisce il nome per il canale (optional)
    
    'Creo i tre task che servono per il funzionamento del programma
    DAQmxErrChk DAQmxCreateTask("", taskHandle(NumSens))
       
    'Questa funzione serve a creare il canale dalla quale poi viene effettuata la misura
    
    If (NumSens = 0) Then
        DAQmxErrChk DAQmxCreateCIPulseWidthChan(taskHandle(NumSens), "Dev1/ctr1", MyChannel(NumSens), 0.00001, _
        0.0009, DAQmx_Val_TimeUnits3_Seconds, DAQmx_Val_Edge1_Rising, "") ' DAQmx_Val_TimeUnits3_Ticks, DAQmx_Val_Edge1_Rising, "")
    ElseIf (NumSens = 1) Then
        DAQmxErrChk DAQmxCreateCIPulseWidthChan(taskHandle(NumSens), "Dev1/ctr2", MyChannel(NumSens), 0.00001, _
        0.0009, DAQmx_Val_TimeUnits3_Ticks, DAQmx_Val_Edge1_Rising, "") 'DAQmx_Val_TimeUnits3_Seconds, DAQmx_Val_Edge1_Rising, "")
    Else
        DAQmxErrChk DAQmxCreateCIPulseWidthChan(taskHandle(NumSens), "Dev1/ctr3", MyChannel(NumSens), 0.00001, _
        0.0009, DAQmx_Val_TimeUnits3_Seconds, DAQmx_Val_Edge1_Rising, "")
    End If
    
    DAQmxErrChk DAQmxSetReadReadAllAvailSamp(taskHandle(NumSens), False)
    
    'Con questa funzione si sincronizza il timebase della scheda con il segnale da leggere
    DAQmxErrChk DAQmxSetCIPulseWidthDigSyncEnable(taskHandle(NumSens), MyChannel(NumSens), True)
    
    'DAQmxErrChk DAQmxSetReadOverWrite(taskHandle(NumSens), DAQmx_Val_OverwriteMode1_OverwriteUnreadSamps)
    
    'DAQmxErrChk DAQmxCfgSampClkTiming(taskHandle(NumSens), "", 100000, DAQmx_Val_Rising, DAQmx_Val_AcquisitionType_ContSamps, 10000)
    
    'provare queste due funzioni per aspettare che il campione sia realmente disponibile.
    'La seconda èdovrebbe essere quella che da il migliore compromesso tra uso CPU e velocità.
    'DAQmxErrChk DAQmxSetReadWaitMode(taskHandle(NumSens), DAQmx_Val_WaitMode_WaitForInterrupt)
    'DAQmxErrChk DAQmxSetReadWaitMode(taskHandle(NumSens), DAQmx_Val_WaitMode_Yield)
    
    'Setta il numero di campioni da acquisire ogni volta che va in lettura e
    'il modo di lettura. Si è impostato "contsamps" per avere la lettura continua
    'La dimensione del buffer è determinata da quel 10000 che va messo così secondo le specifiche del daqmx
    DAQmxErrChk DAQmxCfgImplicitTiming(taskHandle(NumSens), DAQmx_Val_AcquisitionType_ContSamps, 10000) 'DAQmx_Val_AcquisitionType_ContSamps
    
    'La scheda NI PCI 6601 ha soltanto un canale per il DMA (Direct Memory Access) quindi non riesco a leggere
    'contemporaneamente tre task per volta. Quindi devo attivare un meccanismo diverso per la lettura
    'basato sugli interrupt, ogni volta che ho una lettura automaticamente leggo il dato
    DAQmxErrChk DAQmxSetCIDataXferMech(taskHandle(NumSens), MyChannel(NumSens), DAQmx_Val_DataTransferMechanism_Interrupts)
    
    'La funzione di seguito serve semplicemente per leggere il campione più recente generato
    DAQmxErrChk DAQmxSetReadRelativeTo(taskHandle(NumSens), DAQmx_Val_ReadRelativeTo_MostRecentSamp)
   
    'La seguente funzione è complementare ad una utilizzata nell'inizializzazione e serve per impostare la lettura
    'sull'ultimo campione generato
    DAQmxErrChk DAQmxSetReadOffset(taskHandle(NumSens), -1)
    
    DAQmxStartTask taskHandle(NumSens)
    taskIsRunning(NumSens) = True

Exit Sub

ErrorHandler:
    For i = 0 To 2
        If taskIsRunning(i) = True Then
            DAQmxStopTask taskHandle(i)
            DAQmxClearTask taskHandle(i)
            taskIsRunning(i) = False
        End If
    Next i
    MsgBox "Error: " & Err.number & " " & Err.Description, , "Error"

End Sub

For the reading i use :

 

        DAQmxErrChk DAQmxReadCounterF64(taskHandle(NumSens), -1, 0.5, temp(NumSens, 0), 10000, ReadSamp(NumSens), ByVal &O0)

Well, my problem are very simple, I want an continuos acquisition on three channel and the input signal's frequency that i have to measure is 1 kHz .

 

when i try to keep 2 channel after some cycles appears the error -200141 (buffer overwriting). Why?

 

The read function is called some times every ms and evry time keep out an different value, even if that are impossible because the input signal is at 1 kHz, and why the buffer fill up? What is wrong in my code?

 

Thanks in advance for your help

 

Have a nice day!!

 

Igor Piero Prato

Window 7

$
0
0

I have an excel visual basic program working good using XP.

After I changed to a new computer with window 7, it.s not working properly.

I used stardard library for VBA from NI, NIGLOBAL and VBIB32.

Are there any new libraries files I should update?

regards

Mindy_Gortling

GPS Conversion ETSI LIP

$
0
0

I am writing a program where I am receiving an ETSI LIP string and need to convert it to decimal. I currently don't understand how it is converted.

 

I receive the following in HEX, which coverted to binary for ease, but can't figure out the conversion.

 

LONG:0110011100110110010011000  or in hex: 67 36 4C 00    (25 bits)

LAT:110010100001100101011001 or in hex: CA 19 59      (24 bits)

 

The above converts into this somehow (Taken from a logging program);

 

0110011100110110010011000 Longitude = 0x0CE6C98 (145.142012)

110010100001100101011001 Latitude = 0xCA1959 (-37.899131)

 

 

 

Does anyone have any idea how I go about converting the binary/hex to decimal using ETSI LIP?

How to cwGraph the relative time?

$
0
0

How to cwGraph the Y axis relative time?
Examples hh:mm -> 26:20

thanks to answer

How to get selected channel for LeCroy Waverunner using VBS

$
0
0

Hi All,

I am trying to get which channel (1 or 2 or 3 or 4) is selected in Oscilloscope?
I tried to get the View property of the channels like below:

     app.Acquisition.C1.View // but there can be multiple channels whose view property is also true.

 

 

My problem is there can be more than 1 channels whose view property is also True (depend on if you toggle the channel or not). So I am unable to identify which channel is selected . (Here selected means - light on)

 

Thanks in Advance

Rahul


Issue with FGEN .dll in VB

$
0
0

Hi,

 

I am trying to use a .dll driver I created with LabVIEW in VB.  However, when I try to debug a VB project using functions from the .dll, I get the error shown in the attached image.  The text reads "Could not load file or assembly 'NationalInstruments.LabVIEW.Interop, Version=1.0.0.0, Culture=neutral, PublicKeyToken=daeb5dc76be4e32a' or one of its dependencies. The system cannot find the file specified."

 

I should note that this computer does not actually have LabVIEW on it.  I am suspecting that may be related to the problem.

 

I am using Visual Studio 2008, version 9.0.30729.1 SP.  I am also using .NET version 3.5 SP1.  I am also using NI Measurement Studio 8.6.35.465

 

Let me know if there are any other important details I should provide related to this.

 

Thanks,

Billy

go-live regression test - DISREGARD

$
0
0

go-live regression test - DISREGARD

K2612

$
0
0

Hi.

   I want to set the reading rate of the K2612A but don't know which command to use. Could anyone help me ? Thanks a lot.

FPGA myRIO SENT Read Frame

$
0
0

Hello Community,

 

i have now a myRIO with Labview 2013. I try to read a digital signal of a sensor on port DIO0 (C-Port). It works fine. The problem is that i don't know, how can i find the beginning (the SYNC Nibble) of the SENT- Frame and how does it works with the clock ticks/ clock time of the FPGA System (40Mhz). I don't understand the meaning of the clock time. clock ticks.

The next problem is to measure the time between falling edge to falling edge. Actually i can detect every falling edge of the SENT signal but i can't measure the real time between them. How can i measure the real time depending of the clock time of the FPGA system? The SYNC Nibble have every time 56 ticks. But how much time are the 56 ticks?

 

Best regards,

 

Basti

Failed loading mesa.dll

$
0
0

Hello All,

 

I am distributing a MS for VB6 standalone application.  The application uses a couple of the CWUI graphic controls on one screen.  For a long time the application worked properly on Windows XP and Windows 7 OS's.  However, after a recent recompile of the software, I am getting the "Failed loading mesa.dll" message (from Measurement Studio) pop up when the screen that includes the CW controls loads.  This is new, and wasn't happening until recently.

 

Failed loading mesa.jpg

 

I've tried registering the mesa.dll using the regsvr32 command from the command prompt (as Administrator), but this hasn't changed anything.  

I've tried recompiling the VB6 application several times.

I've tried recompiling the installation file (using Setup Factory 8.0) several times.

The software seems to work properly except the CW controls do not display.

Can anyone suggest something that I could try to resolve the issue?  Would appreciate any ideas.

 

Thanks,

Chris

ViReal64 から Doubleへの変換

$
0
0

 

VB6.0からniScope14.0を使用しています。

 

サンプリングレート等から時間軸をしようとしていますがうまくいきません。

 

根本的なところですが、NIのライブラリー内で使用されていいるViReal64、ViInt32等の型の

取扱が解かっていないため問題が起きているのではないかと考えております。

 

そこで、ViReal64、ViInt32をDouble、Long等のVBの組み込み型に変換したいと考え

cdbl()関数で変換してみましたが、なんとなく動作しているようで、不安定です。

clng()に関しては変換できないようです。

 

ほかに何かViReal64、ViInt32をDouble、Long等のVBの組み込み型に変換する方法は

ありませんか?

 

Problema controllo GPIB su windows 8

$
0
0

Salve a tutti,

cerco di sintetizzare il problema:

con i giusti accorgimenti ho installato, su un nuovo PC con Windows 8, Visual Basic 6.0 + Servicepack  6 ed il Measurement Studio per vb 6.0.

funziona tutto alla perfezione tranne il controllo per la strumentazione GPIB. 

Ho provato ad eseguire un programma che gira normalmente su Windows XP (legge semplicemente delle misure da un multimetro 34401A), ma lo strumento indica due errori -420 e 550. Per capire meglio il problema ho creato un nuovo progetto inserendo solo il componente gpib e scrivendo 4 righe di codice che su Windows XP funzionano alla perfezione:

 

cwgpib1.BoardNumber=0

cwgpib1.PrimaryAddress=22

cwgpib1.SecondaryAddress=0

cwgpib1.configure

cwgpib1.Write ":READ?"

ma niente, il problema è lo stesso.

l'unico modo perchè funzioni e che apra le proprietà del controllo , clicchi su Update e poi su applica. così facendo sullo strumento compare l'indicazione "Rmt" e quando eseguo il programma funziona alla perfezione. 

 

Immagine.png

Se salvo il progetto chiudo e rieseguo il problema si ripresenta.

Qualche suggerimento?

 

 

 


vi conversion from 8.5 to labview 10 regarding.

$
0
0

hello sir,

    The source code was originally built in labview 8.5, but after
that updated to labview 10.The os is windows7.


Problem: the Pc reboot or shut down automatically once in 2 days
,especially night time.

Pls change this application compatible to labview10 drivers,win7.


with regards,
uma maheswari,
Application Engineer.
Elnix Technologies(chennai)Pvt.Ltd.

How use an NI-6008 card with Builder c++ ?

$
0
0

Hi all,

 

I'm a French Student and i have a project with school :

 

I must control an NI-6008 card with Builder c++, but i never make this. I know just make an interface on builder.

 

My first question is : How install a NI-6008 card on PC ? How control it?

 

Sorry for my bad english, good bye,

 

Martin CORNU.

Fast mode acquisition for 9214 with VB6

$
0
0

Hi

 

I have a VB6 app which acquires data from an NI 9214 temperature measurement device. The device has two acquisition modes, high accuracy (default) and high speed. Using MAX I can see that these modes both function in a test panel. However I cannot see how to change the mode to high speed programmatically in VB6. I'm building and running in VB6 in DevStudio 2008 on an XP virtual machine (host is Windows 7) using DAQmx 14.2. Also running the compiled executable directly on Win 7 with no problem. Just want to change the sampling mode to fast (up to 100 Samples/s for a single channel) whereas the default high accuracy mode is only 1 sample/s. Looking at transients of the order of 0.01 s over a 2 minute period.

 

Can anyone help with this?

 

Kind Regards

 

Chris

 

 

 

CWGPIB , .configure , debug Close, can't execute

$
0
0

I'm studing VB6.

someone send me some code using measurement studio ( GPIB connection )

 

when i execute program, i had error in "CWGPIB1.Configure" line.

 

the question is

 

     if i don't connect GPIB cable , error occurred ?

 

    do you have any idea about solving this?

CWSerial/CWGPIB on Win7 :"The subject is not trusted for the specified action"

$
0
0

Hello,

 

I'm currently trying to migrate a VBA software from WinXP + Excel2000 to Win7 + Excel2010 and I'm encountering a big problem. The software is using activeX control such as CWSerial and CWGPIB but when I'm trying to add them I get the following error "The subject is not trusted for the specified action".

 

I'm more or less certain it's a permission problem, I just can't figure out how to solve it. I'm also pretty sure it's not a VBA version problem because I tried to do the same manipulation on a Win7 + Excel2000 machine and got the same error, so it must be related to the OS.

 

What I have already tried:

 

Regsvr32 on cwinstr.ocx.

Downgrading the Microsoft Office version to 2000 again.

Set Excel's Trust Center to enable all controls without restriction.

Fiddle with the registry keys following instructions on internet for similar problems.

Re-install everything on a new machine.

 

Did anybody face the same problem and/or has a solution? I'm working on a Virtual Machine so I can test every idea without fearing data loss.

 

Thank you for your help!

 

 

Viewing all 323 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>