10-19-2009 08:58 AM
Hi,
I need to make an Serial Number check into my testsoftware.It must write the serialnumber to a binaryfile and then check if the serial is already used.It should also log all passed and not passed serialnumbers.How can this be done easely with Labview?
10-19-2009 09:33 AM
LabVIEW has binary file I/O functions. There are examples that ship with LabVIEW that show you how to read/write binary files. Are you only storing the serial number? If so, perhaps a simple text file would be sufficient? The "easiness" or "hardness" depends not on LabVIEW, but on your skillset and what else your program has to do. Clearly, you must be doing something other than checking serial numbers. However, for just this small part you can read the file at startup and store it into an array. When a serial number is entered you can simply see if the number is in the array. As for the logging part you have to be more specific. Log in what way? To the same file as mentioned above? What else are you logging? Data? Test parameters? Test names? Measurement names?
So you see, you need to first congeal your requirements a bit more. That's really the hard part.
10-19-2009 01:19 PM
I want to use it along with a simpel RS-232 Terminal program.My intension in using binary-file is that user can not edit the bin file and add a serialnumber into it.So what Yopu mean is i can make a POP-UP before my terminal program starts telling user to enter serialnumber and store this information in a binaryfile?.It shall only store the serials that passes test without failures.
10-19-2009 02:49 PM
Here is a discussion on license management
http://forums.ni.com/ni/board/message?board.id=170&message.id=444750&query.id=1054392#M444750
Also you should think about encrypting this information if you are worried about security. You can use Blowfish. It is an encryption VI that is free from LabVIEW.
http://zone.ni.com/devzone/cda/epd/p/id/3473
10-20-2009 02:07 PM
10-21-2009 09:27 AM
11-15-2009 06:05 AM
I have looked at examples shipped with Labview but i have no clue were to start. Only logging details i need is "Serial nbr on device" Date of test and result OK or Failed. Testing software is almost done and when it finish executing it gives a True/False LED at front panel for the test. Is it not any examples out for this purpose?
11-15-2009 09:14 AM - edited 11-15-2009 09:16 AM
Is this what you are looking for?
You said three things to save, a) Serial number b) Test DateTime and c) Passed/NotPassed
So for me that's a cluster of three elements.
You want to save multiple clusters, so just make an array of it and save/recall the complete array.
I also add the file with some fake data but you can start with no file at all.
Hope this helped.
Edit: I had to rename the extension of the binary file since ".bin" is not allowed 🙂
11-15-2009 09:49 AM
11-15-2009 10:10 AM
The example was just how to read and write to a binary file.
What happend with the data is something else.
Since we don't have the complete picture it's almost impossible to give you a final system 🙂
For comparing a SN I would suggest the following steps (states)
This is best implemented with a state machine architecture.
Do you use one or not?