04-02-2009 07:41 PM
hi there...
i am working on my master project and I am stuck. My professor is not able to help me because he doesnt know how to program labview.
i got the webcam to work.
i need to be able to save the image (the barcode) and give back on display the barcode number.
can someone please help me.
I have to show him that i have done this by this Saturday.
I have a camera with high resolution. i dont need the full resolution.
can LAbview just take portion of the image and save it? How would I do that?
are there any examples?
i need to do this ....
04-02-2009 09:45 PM
Hi krispiekream
Looking at the picture you are already using the Vision Assistant and determined your ROI (Region Of Interest) for the bar Code
Into Vision Assistant you can use the Barcode Reader function from the menu: Identification/Barcode Reader or simply click Barcode Reader in the Identification tab of the Processing Functions palette (down left corner);
If your image is not 8 bit binary you have to select the Color tab from the Processing Functions palette and add any of the color plane to covert into grayscale before your read the code.
You can also use the Pattern Matching functions to locate your code and orient in a manner to have the lines from the bar code showing vertically.
In the Bar Code Reader Tab select the <<1D Barcode reader>> and draw the region window using the mouse cursor that will contains all of the bars to read from the image of the camera.
You can select only the lines not all the code for that part (see picture);
Then select the Barcode Type (UPCA gave me good results with you barcode sample) and the check box to add a check sum.
The Barcode read string should appear under the region profile graph: 8473670228
When you find the right type select OK and go to the Tools/Create Labview VI.. to generate your program via a 4 steps process.
In the last step4 select the check box to add the string from your barcode into LabView in order to get the value that you want to display.
I think with this you can create the LabView code that you need for the Barcode picture as well.
Hope this assist you into getting a solution to show tomorrow.
04-03-2009 09:12 AM
i installed NI-IMAQ for USB Cameras
and i also installed NI.Vision.v8.5.Acquisition.Software but I do not have
Vision Assistant.
I didn't choose the ROI yet, I used PAINT AND crop out the other images that is not my region of interest..
where can i find trial version for vision assistant 8.5?
04-03-2009 02:27 PM
Hi krispiekream!
You can request a trial version of VDM, which includes Vision Assistant, here: http://www.ni.com/vision/vdm.htm
Kristen H.
04-03-2009 02:36 PM - edited 04-03-2009 02:36 PM
If you have IMAQ for USB, you should have Vision Development Module (VDM) which includes Vision Assistant.
Vision assistant is not going to be found in LabVIEW, it is a prototyping environment, where you create something, then generate LabVIEW code from that. You can use the VDM examples for a barcode reader though, and you should be fine. You'll find them in the NI example finder, just search for barcode.
You can then save your image with more of our VIs (IMAQ Write File in particular) to JPEG, PNG, etc.
Hope this helps!
04-09-2009 10:40 AM
Thank you guys for all your help..
but I am still having problems..
I think NI has a IMAQ Select Rectangle for ROI.
But I am not sucessful of selecting the ROI from the an image,
I want to do this...
Select ROI, save image and plug it into the BARCODE example to decode it?
Can you please show me how to do that?
Thanks in advance..
04-10-2009 02:12 PM
Hi krispiekream,
How is the example giving you problems? Is it throwing an error? Are you wanting to take the image from the camera instead of a file?
Kristen H.
04-10-2009 02:21 PM
well, the example does discriple what ROI means.
what are the constants in the ROI array.
I had to download the Vision Developemnt module and found how that you can have use alot of ROI functions in Vision to select the region you want the bar code to work.
I finally got it to work yesterday. Thank you so much Kristen for all the help you giving me.
My project is 50% finish. the other 50% is to use a microcontroller and display my barcode on an LCD module using USB Visa.
I think it shouldn't be hard.
02-12-2014 09:17 AM
Hello people.
I really need your help.:(
actually i did my coding for barcode but i have to get TP022216
bUT instead i am gettting TP02221
Why the last number 6 is not appearing
pLease help