First time on the vb.net post so I hope you can help.

I have never used vb.net, but I am undertaking a project using RFID tags and have just purchased a demo kit with a reader and tags to play with.

I have chosen to use vb.net to experiment with as I have some understanding of asp.net as it seems a lot alike.

I have order visual studio on the way so have not played with vb.net yet but would like some advice before I start

Fist of all, how to I get my vb.net program to communicate with the reader? This is my main question. I don’t truly understand yet how to do this. It uses a com port and works at the moment with a vb program that come with it. But I want to design my own, so I need to know where to begin or any sample code anyone know which will help me understand and be able to get the reader to commutate with my program ie. Read a tag ID.

In layman’s terms would be good lol.

Anyone’s help on this matter would be much grateful, thanks.
LVL 12
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Ignacio Soler GarciaSolution Architech & Technical LeadCommented:
Now I am very busy, latter I will give you more information. From now I must tell you that there is no serial comunication built in Framework (in 2.0 will be) and now you have to use third party solutions. I have worked a lot with this one and it works great:


Stay tunned, to be continued... :)

pigmentartsAuthor Commented:
Sounds difficult, well I wait in anticipation for your response.
Glad to see you come on board!
To Start your new adventure here is where I found good examples for getting started in VB.Net


Link for ASP programs...


Cloud Class® Course: Python 3 Fundamentals

This course will teach participants about installing and configuring Python, syntax, importing, statements, types, strings, booleans, files, lists, tuples, comprehensions, functions, and classes.

It is not that difficult if the reader has a command language API.  Look though the documentation.  If they got a VB6 program to work with it, most likely there is either a command language of some sort.  If not, look closely at the VB6 program.  It is probably installing some sort of API dll that it is making calls to.  Look for doucmentation on that dll.  

If both of those routes fail, contact the manuafacturer.

Once you have the API or command language, it is pretty straight-forward writing a VB.NET program that communicates with the reader.

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
pigmentartsAuthor Commented:
Thanks for you help, still waiting for  SoMoS to get back waiting very interesting to what he has to say.

Read the links looks straight forward, having difficulty understanding why I would need to know the command language, I assumed .net got around this barrier of working with different technologies (COM, WIN32 API).

That’s why I have chosen .Net and not the old VB as with the old VB you have to work directly with the components, but in .net you use a object which simply knows how to do this with out having to touch the ins and outs of WIN32 etc. Please someone correct me if I am wrong or have it misunderstood, like I said I am very new to this, in fact not even touched vb.net code yet.
pigmentartsAuthor Commented:
PS Need more info, have a com to USA cable, it is easyer to use this and not the COM ports?
pigmentartsAuthor Commented:
don't know if its API but i found the program that come with it using these setting (see below) if that means anything and anyone can help, still need to know the answer to my question about how to read a RFID tags which connects to the computer using a COM port, i only need to read them and manipulate the data obtained in a database.

Port 1
settings 9600,n.8,1]
key suffix [enter]
discard 0
reader RFID

don't know if the above tells anyone anything about how the program is reading the tag, but i really need to do the same in mine.

ps thanks for the warm welcome, i know that i will have many, many, question very soon once i start vb.net so thanks in advance for putting up with me.

The reason you would need the command language is so you could send commands to the device.

Like FindTHisIDTag or DetonateRFIDDevice

If the device is worth its salt, it comes with an API .dll that you can include in your .NET project and make calls to.  If it's really good, the .dll will be .NET and not COM.

Some day you will be able to sit in your easy chair while your computer determines that it needs a component, orders it by itself, walks out and signs for it when FEDEX arrives, unpacks it, hooks it up, writes the code to interface with it, makes the cold calls to sell the software, and distributes and supports it.

That day is not today.  Do the work.  It's why you get a paycheck :)
Ignacio Soler GarciaSolution Architech & Technical LeadCommented:
Hey, I'm sorry but I'm in a rush and out of experts-exchange for a while ... But keep in mind that if the library is a COM component (we can talk about COM technology and serial COMM ok?) is better to work with VB6. VB.net don't support very well COM components (it supports some of them and it don't others ...
pigmentartsAuthor Commented:
i understand why i VB6 would be better, but the problem is laster on .net is going to be a lot more powerful in my project so i really want to stick to my guns and try it in .net it only has to read the device.

PS i contacted the business who sold me the RFID reader like TRUENEUTRAL stated, but they said:

Our team of developers spend thousands of
pounds creating code that only we use. So sorry about that!
I will send you a data sheet for the ID12 reader, which is in the demo kit
this tells you all the specifications that I can legally notify you of
without breaking company policy.

Those specs they are sending should include the format of the output of the device.  If you just need to capture it, it should not be very difficult in .NET.

Typically these devices send some info to the COMM port.  You just need to set up a listener on the COMM port in .NET and catch what comes out.

The specs should tell you what the output means.

If they only spent thousands, and not hundreds of thousands, this is likely a low end device.  Do not expect much from it.  Sort of like buying a KIA :)

pigmentartsAuthor Commented:
right o this may be a bit long but i hope TRUENEUTRAL can help, here is the details they sent, so now how do i capture it.

PS i only need to read the TAG ID.


The ID-2, ID-12 and ID-20 are hybrid RFID reader
modules that provide simple, consistent and
flexible implementation of this technology into
existing swipe card based ID equipment.

The ID-2, ID-12 and ID-20 are readers for the
popular EM4001 format 125KHz tags. Read
ranges of 1-15 cm are possible with ISO cards
(25cm with a well tuned matched antenna on the
ID-2). With CMOS/TTL Serial, Wiegand26 and
NEW with this series, Magnetic ABA Track 2
format, swipe cards can be emulated. Furthermore,
the readers are encapsulated for environmental
protection and potential damage or changes during
manufacture or handling.

All three readers
support ASCII, Wiegand26 and Magnetic ABA
Track2 data formats.

Parameters ID-2 ID-12 ID-20
Read Range N/A (no internal antenna) 12+ cm 15+ cm
Dimensions 21 mm x 19 mm x 6 mm 26 mm x 25 mm x 7 mm 40 mm x 40 mm x 9 mm
Frequency 125 kHz 125 kHz 125 kHz
Card Format EM 4001 or compatible EM 4001 or compatible EM 4001 or compatible
Encoding Manchester 64-bit, modulus 64 Manchester 64-bit, modulus 64 Manchester 64-bit, modulus 64
Power Requirement 5 VDC @ 13mA nominal 5 VDC @ 30mA nominal 5 VDC @ 55mA nominal
I/O Output Current +/-200mA PK - -
Voltage Supply Range +4.6V through +5.4V +4.6V through +5.4V +4.6V through +5.4V

Pin Description & Output Data Formats

No. Description ASCII Magnet Emulation Wiegand26
Pin 1
Zero Volts and Tuning Capacitor
Pin 2 Strap to +5V Reset Bar Reset Bar Reset Bar
Pin 3
To External Antenna and Tuning
Antenna Antenna Antenna
Pin 4 To External Antenna Antenna Antenna Antenna
Pin 5 Card Present No function Card Present No function
Pin 6 Future Future Future Future
Pin 7 Format Selector (+/-) Strap to GND Strap to Pin 10 Strap to +5V
Pin 8 Data 1 CMOS Data One Output
Pin 9 Data 0 TTL Data (inverted) Clock Zero Output
Pin 10 2.7 kHz Logic Beeper / LED Beeper / LED Beeper / LED
Pin 11 DC Voltage Supply +5V +5V +5V

Pin Description & Output Data Formats
Pin No. Description ASCII Wiegand26
Pin 1 Zero Volts and Tuning Capacitor Ground GND 0V GND 0V
Pin 2 Strap to +5V Reset Bar Reset Bar
Pin 3 To External Antenna and Tuning Capacitor Antenna Antenna
Pin 4 To External Antenna Antenna Antenna
Pin 5 Format Selector (+/-) Strap to GND Strap to +5V
Pin 6 Data 1 CMOS One Output
Pin 7 Data 0 TTL Data (inverted) Zero Output
Pin 8 2.7 kHz Logic Beeper / LED Beeper / LED
Pin 9 DC Voltage Supply +5V +5V

hope someone and make sense of this for me, thanks
Looks like they gave you the hardware specs.

Is this device hooked to the COMM port while in use?  Or is it one of those things you walk around with and scan stuff and then hook to a COMM port to download the stored data?

They gave you pin numbers as if you were going to program some sort of chip to interface with it.  Fun stuff!  But not the documentation you need.

If the device is hooked to the COMM port while in use, you should just be able to listen on the COMM port and catch whatever it sends.  Then it will just be a matter of interpreting the data.

If the device is portable, it should have a setting to push the data to the COMM port once hooked up, and again, you are just listening for bytes.

What good it the @#$% thing if it can't interface with a computer?  If the interface is proprietary, they you should not be doing this anyway.  However, I suspect that you spoke with the resident hardware geek on the phone when you really needs to speak to the software interface guy.
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Visual Basic.NET

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.