Hello everyone,
As part of a project I have to do computer vision through the National Instrument Software (NI) "Vision Assistant". The functions of the wizard I want to use will be "circle detection" and number ditection as first step
My problem is that I really want to integrate, the image given live from my camera, the tools (buttons) selections on the image and the results obtained after treatment (that the Assistant gives) to my program already existing (on the UIR of the program)!
I do not understand (I read the tutorial Vision assistant to cvi without success) how to use the code generated by the wizard in CVI to show what I need (the image given by my camera, buttons selections of the assistant and in my already coded program.
Moreover if I compile the code directly that the assistant generates me (alone), there are errors library which I must thus remove generated code to compile correctly!
If one of you has already been there, his help would be very precious to me! Smiley winking
Thank you very much !
generated CVI code and use UIR after precessing image under VISION ASSISTANT
ni PXIe 6555-Multiple sequences with different voltages in the same generation
Hi everyone,
I am currently working on a testbench and I need to be able to produce different level of tensions depending on which part of the sequence I am in with an ni PXIe 6555 using HSDIO.
This goes like this:
seq_A>seq_B>seq_C...
A uses 0-3.3V
B uses 0-5V
C uses a custom level
I already use all my channels so I can't switch channels in order to find a go around solution and they are already set to a dynamic generation since I am using waveforms. At the moment I have all the results with the sequences when I do it one by one but I can't seem to find a way to do it fast.
I already succeeded in doing them one at a time, unload the waveform, reconfigure, upload the new one but the timing in between is way too long, it takes 3ms for all of this to be done so I am looking for a more optimal solution which could run smoothly.
I tried using different vi, one for each sequence, produce them and then generate, wait until it's done, generate... but it is bugging without an error message.
If you have any idea of how to proceed, thanks for the help!
[CVI2015] Haw can I get an old date from the current date ?
Hello,
I'm getting the current system date.
I need to get the last week date. So :
if current date = 22/03/2018 => last week = 15/03/2018
if current date = 02/03/2018 => last week = 23/02/2018
if current date = 02/04/2018 => last week = 26/03/2018
etc....
Any ideas please ?
Thanks !
NIDAQmx Libraries for CVI not included
Hello,
I downloaded NI-DAQmx 17.5 Runtime, I can not find the libraries and support files for CVI.
Regards
Nick
Panel control by several files
Hi everybody !
I am a beginner in labWindows and I have met several problems
I would like to structure my project in order to have:
- a main file
- a file that gathers all the callback functions - Callbacks.c
- a file that handles the importation of configuration files - import.c
- a file that handles the exportation of results and configurations - export.c
- a file with functions that handles the display of parameters/values in the panels, those functions will be called by the Callback functions - Display.c
In parallel, I have a file Panels.h that gathers all the parameters of my panels
For now, I encountered a first problem:
I managed to display parameters in my panels when the code line "SetCtrlVal(panel, PANEL_NAME, project)" is written in the file Callbacks.c. However, if I move this instruction in a function of the Display.c file (function called by an other function of the Callback.c file), the display does not work.. Can I control my panels with several functions from several files or only with CVI CallBacks functions ?
Thank you in advance for your answers !
ExcelRpt_ChartWizard Help
I am trying to create charts for a program I am making. I create an instance of excel, create 4 worksheets(1 for each unit I am testing) within a single workbook. I write data to each sheet based on which unit I am reading. After the program reaches it end I attempt to create graphs. I create an empty chart and use the chartwizard to format and create the graphs. There are instances when I test less than 4 units and for the sheets that have no unit the graph formatting working fine, but for the sheets that actually have data saved the chart is not formatted at all. Below is my code for creating the graphs.
char ChartRange[100000];
sprintf(ChartRange, "A1:L%d", writeline);
/// REGION START Create Graphs
/// REGION START UUT1
ExcelRpt_SetCellRangeAttribute(UUT1, "A:A", ER_CR_ATTR_NUMBER_FORMAT, "m/d/yyyy h:mm:ss");
FmtOut("# ");
Delay(1);
ExcelRpt_ChartAddtoWorksheet(UUT1,650,1,750,500,&UUT1chart);
FmtOut("# ");
Delay(1);
ExcelRpt_SetChartAttribute(UUT1chart, ER_CH_ATTR_LEGEND_POSITION,-4107);
FmtOut("# ");
Delay(1);
ExcelRpt_SetChartAttribute(UUT1chart, ER_CH_ATTR_CHART_SIZE_WITH_WINDOW,1);
FmtOut("# ");
Delay(1);
ExcelRpt_ChartWizard(UUT1chart,UUT1,ChartRange,ExRConst_XYScatterLinesNoMarkers,0,0,1,1,1,SerNo[0],NULL,NULL,NULL);
FmtOut("# ");
/// REGION END
NOTE: the delays were an attempt to give CVI time to format everything properly.
NOTE: if I put a break point on the ChartWizard line the graph is made fine.
How to send binary data through TCP communication.
Hi!
I want to send the binary code from the client.
You want to send data to the partner device side using the ClientTCPWrite command.
There is no problem with ASCII transmission, but it is a problem when transmitting in binary form.
The binary code is as follows.
50h 00h 00h ffh ffh 03h 00h 0ch 00h 10h 00h 01h 04h 00h 00h 64h 00h 00h 90h 02h 00h
When inputting the above data into the data buffer for transmission, we have confirmed that the following characters can not be processed because of 00h (Null) and ClientTCPWrite transmission data can not contain nulls.
I will contact you if possible!
Starting CVI IDE project file with parameters to make project build and application run
Hi all,
Is there a way to the following steps in CVI IDE without user explicit actions:
1. Build
2. Run the application.
I mean, open a CVI project (*.prj file) from a shortcut, and trigger BUILD and then RUN commands. Or, immediately RUN, because it also builds the project.
Thanks for the support
CVIXML character encoding puzzle
I have an app that parses an XML file generated by .NET with the CVIXML library. The contents of that XML file have 2 bytes per character, and under normal situations the contents fit within the plain ASCII set, so every character only needs one byte, and can be represented within char[] in CVI.
I have been pleased to see that the CVIXML library (or underlying MS DLL?) handles the 2-byte to 1-byte transition in parsing, but issues arise when the XML file contains characters that use 2 bytes. Here is a hex view of such a case in the file with a 2-byte character (Greek alpha):
There seems to be a best-effort attempt to find and correct this 2 byte to 1 byte transition for non-ASCII characters, but it is not always possible. Specifically:
- Greek alpha becomes 'a' which seems reasonable.
- Greek delta becomes 'd' which seems reasonable.
- Greek beta shows up as a beta, which can be found elsewhere in the ASCII set (0xDF) - nice!
- Greek gamma becomes '?' - uh-oh!
The most problematic aspect of this is that we will lose uniqueness of the output values with all unsupported characters mapping to '?'.
The CVIXMLGetAttributeValue function returns 0 (success) in all these cases.
So my question is: Is there any way within the library to detect cases where the the XML file contains unsupported 2-byte characters? Or would I need to separately parse that input file and look at it byte-by-byte?
recuperation et enregistrement d'image acquise sous labwindows
Bonjour,
Je voudrais sauvegarder mes image acquise avec une caméra dans un fichise en .png afin de pouvoir les visualiser et modifier.
je travails sous labwindowscvi 2017 utilisant NI IMAQdx
Merci bien.
Output Sample Rate off on NI card
Hello,
I've inherited a waveform generator written in CVI and for the life of me I can't get it to output the proper frequency sine wave. I have an NI USB-6212, and when I tell it to, for example, use an output clock rate of 127168 samples per second and then get it's actual sample rate with DAQmxGetTimingAttribute, it gives me a value of 127388.55.... Does anyone know why this is? The method my boss uses for waveform generation is to produce a fixed size buffer and then vary the sample rate to generate the proper frequency output. This isn't exactly my first choice in technique, but I'm not thrilled about the idea of rewriting a fairly lengthy piece of code. Thank you for your time.
Surge
Lire un fichier entre deux lignes
Bonjour,
j'aimerais savoir s'il existe une fonction qui permet de lire le contenu d'un fichier entre deux lignes, pour le recopier dans un nouveau fichier. Par exemple, j'ai un fichier in.txt qui comporte 10 lignes, et le contenu des lignes 4 à 8, je veux le mettre dans un fichier out.txt.
Merci de votre réponse
Read a file between two lines
Hello,
Can you tell me if, thank's to a function, we can read between two lines ?
For example, I have one file in.txt, it has 10 lines, and, I want to write what we have between lines 4 and 8 in an other file out.txt.
Thank's for your time
Automatization of action on UI
I have a CVI application with a graphical user interface.
In order to interact automatically with this UI, I would like to use something like AutoIT.
AutoIT works fine with Windows Application but not with CVI application.
Is there a solution for that?
Thanks
[CVI2015] Get the day of the year from a given date
Hello,
How can I get the day of the year number from a given date ? (not necessarily the current date).
Thanks in advance
Hi, I need to select the Excel file through file select popup and read the data and convert it.
I should write a program for selecting a excel file through fileselectpopup and read the data present in excel file and convert it to binary file and store it in some location.
I've written program till selecting excel file through file select popup but I'm not able to open excel file and converting it. I read excepreport, excel2000 examples, but I didn't understand it. Please some one help and guide me step by step. Thanks in advance.
-Vinay
Localization (.lwl) file format
Hello!
Is there a document which describes the .lwl file format? To be more precise, I'm interested in the Flags property, because it contains random characters (at least for me it's random). I try to auto generate these .lwl files so this is why I need more information about it. I know there is a tool for this inside the CVI IDE, but to be honest... I don't like it.
Thank you!
PC System minimum demands to run CVI 2017 smoothly
I would like to know if the system I have has the minimum demands to run CVI 2017 without getting unpleseant delays. It is used mainly for debug and tiny project changes.
I meant there is often a hint from the software company for a minmum suggested PC System.
Could not find it yet in the NET.
varible sine wave using fixed lut
in user interface i will enter any any amplitude ,freq . and I am passing this data to 12 bit Dac...i need variable sine analog out.
user can enter any freq from 0-100hz,I am new to programming please help me
Private CVI 2017 distribution
Hey there.
I wrote a wrapper DLL in CVI 2017 a few days ago and it works great on my PC. I wanted to distribute my application by manually adding the CVI runtime engine to my end application (for now, a LabVIEW one, but it could be called by other IDEs) by copying the cvirte.dll and cvirte folder, like I already did in the past with success (with older CVI versions).
https://knowledge.ni.com/KnowledgeArticleDetails?id=kA00Z0000019LJBSA2
However, it turns out it does not work with CVI 2017! In my case, when opening my executable it returns an error (error 12 or 42). I do need to install the CVIRTE.msi installer from the CVI run-time engine but I could not track down which particular component I am missing there...
Installing the CVI RTE is not an option (due to admin privileges needed for anyone who'd like to use the app).
Thanks for your help!
--Eric